This addon has been deprecated

This means the addon is no longer supported. You can still use it, but be aware no support or updates can be expected.


implementation of ROT.JS (Roguelike Toolkit) for C3Runtime

Example Files

rotjs.c3p (161.37 KB)

basic usage of the rot.js plugin

rotjs-fov-test.c3p (159.24 KB)

test fov functions

rotjs-islandtest.c3p (157.24 KB)

detect and iterate islands of tiles

Version History

Version Size Downloads Released
1.3 (Current)
81.54 KB 489 Download
64.83 KB 143 Download
78 KB 92 Download



1.3 Stable (81.54 KB)



  • Download count724 total downloads
  • Latest download count 489 downloads of latest version
  • Average download count1 downloads per day average



  • Order by
Want to leave a comment? Login or Register an account!
    • [-] [+]
    • 2
    • Fib's avatar
    • Fib
    • 2 points
    • (0 children)

    This.... is.... amazing! Thank you so much!

  • Very useful update. Thank you for this :)

  • Would it be possible to assign a room index number when generating a Cellular Automata. I'd like to figure out each little group of cells, are together and ideally how many are in that group.

    • I don't think that's supported by rot.js, but I'll do a bit of research and figure it out should not be 2 hard to implement, you pretty much just want groups of floor cells that are not connected and then you want to assign a room id to them and iterate their cells by roomid and stuff. I'll look into it

      • Thank you piranha! When using the cellular automata it creats nice little patches like spots on a cheetah. I'd like to be able to group those together into a room index or something so that i can manipulate all of them at once. eg: if player is overlapping roomindex = 1.

        Load more comments (1 replies)
  • It's "rogue". "Rouge" means "red" :)

  • help it does not let it load

  • Hello piranha305,

    In my project, I loop in every cell to check if the ones next to it are corridors, rooms, etc... so I can set the appropriate sprites.

    But it wasnt working at all, until I saw errors in the console. The conditions "is in Room" and "is in Corridor" throw an error if the cell isnt in the grid (trying to access to the property of undefined object).

    So I fixed it by changing the code (in the example, CellIsRoom) from

    return[x + "," + y].type === "room";


    return[x + "," + y] &&[x + "," + y].type === "room" ? true : false;

    and then pretty much the same thing for others conditons.

    If you're still active, make sure to update it ;)

  • When using the load / save in the example file, i get the following error in the console and it won't load

    Uncaught (in promise) TypeError: Cannot set property 'wallCleared' of undefined

  • You dont use variadic parameters do you?

    • No i created separate actions, to account for the multiple overloads that rot.js has, That's why you should see some generation actions with Simple or Advanced, the advance action is the same just with extra params. if there is a particular signature your need let me know and i can add it pretty quickly.

  • Nice work! How do I save the generated mazes for use in loading a game later? I hope to see this grow, as it will help me in my current project, for sure!

    • I haven't looked at the plugin, but generally, with randomly-generated maps, you can remember the seed that the map was generated from. If you use the same seed later, you get the same map.

    • That's on the road map, I will work on this this week. When I have a chance. Would you like to save it the maps as json?

  • Great! Thank you!