User Tag List

Results 1 to 8 of 8

Thread: Level Editor - Problem with Tileset

  1. #1
    Clicker Fusion 2.5 (Steam)Fusion 2.5+ DLC (Steam)

    Join Date
    Aug 2010
    Location
    Sweden
    Posts
    100
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Question Level Editor - Problem with Tileset

    So I have been trying to create my own level editor.

    It works somewhat well. I haven't yet implemented all tiles (only some from Batman and SMB for testing) and functions, so in other words, there are plenty of features missing.


    However, I'm struggling to create a way to show all tiles in the currently selected Tileset.
    As of now, I choose what Game I want to use and then I can select different Tilesets from this game (the Tileset is based on the direction of the Tile Placer). I then have to scroll through the tiles one by one with the mouse scrolling wheel (which feels like a pretty bad design in itself).

    Ideally, I would like the right mouse button to bring up all of the tiles from the currently selected game in a 16x16 grid from which I could then use the left mouse button to select the tile that I want to use. My problem here would be to bring up all the tiles in a grid, I really have no clue how to do this.

    Is there any way to achieve this?


    Bonus question:
    Is there any way to make my Level Editor work without the "1234" object and only use the "Tile Placer" object instead?
    Attached files Attached files

  2. #2
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCHTML5 Export ModuleiOS Export ModuleSWF Export ModuleInstall Creator Pro
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    chrilley's Avatar
    Join Date
    Jul 2006
    Posts
    941
    Mentioned
    16 Post(s)
    Tagged
    1 Thread(s)
    Editors are fun! There are many ways to go about this and I don't know if this is applicable to your project. However, creating and displaying tiles through an Active Picture object is a preference of mine. It's pretty simple to get working too. Attaching an example... I also exported your Batman NES game tileset as the example set.

    Simply click on the tile you want to draw then drag-paint on the "canvas". Holding right button will erase anything you hover over.

    You can make this even more advanced with dragging multiple tiles on the sheet so you don't have to build all elements tile by tile... Even putting together a "prefab library" with different tile combinations should be possible, though I haven't tried that one myself.

    Also if you save the current tile and destination position to an array or ini file as you place/remove them you can build your level data in real-time!
    Attached files Attached files

  3. #3
    Clicker Fusion 2.5 (Steam)Fusion 2.5+ DLC (Steam)

    Join Date
    Aug 2010
    Location
    Sweden
    Posts
    100
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    Thanks! That seems to work really well with backdrops!

    Is it possible to use it in a way to create Active Objects as well? The only thing I could think of was "Launch an Object..." with a speed of 0.

  4. #4
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleMac Export Module
    dsilvers's Avatar
    Join Date
    Jun 2008
    Location
    Boston, MA
    Posts
    573
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    I would create a temporary object where tiles are painting, and then when you let go of the mouse button, run a For Each loop on those temp objects. Call it "placeActive" or whatever. On that loop (Object > Count > For Each object "placeActive") create the active object you want at its X/Y location, and then delete the temp object.

  5. #5
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCHTML5 Export ModuleiOS Export ModuleSWF Export ModuleInstall Creator Pro
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    chrilley's Avatar
    Join Date
    Jul 2006
    Posts
    941
    Mentioned
    16 Post(s)
    Tagged
    1 Thread(s)
    Quote Originally Posted by vSv View Post
    Thanks! That seems to work really well with backdrops!

    Is it possible to use it in a way to create Active Objects as well? The only thing I could think of was "Launch an Object..." with a speed of 0.
    As far as I know you cannot do it with Active Picture object, sadly. And without that, it's a bit more complicated to get to work but it is absolutely possible to use Active Objects as tilesets. I am a bit short on time and I've actually never tried to make a tileset editor using only active objects before so this one is inevitably going to be a bit messier than usually!

    See attached file and some notes below:
    Left mouse click: Select Tile / Paint
    Right mouse click: Remove Tile

    How it works is that I use 1 active object to store all tiles, much like you do already. In order to display them as a library of assets I place them out one by one in a fastloop and freeze their animation to an individual number. This object also works as the tiles you place, I use flags to make sure Fusion scopes the correct object for each specific task.

    I then use an array to store all the level information and update the existing tiles based on it. By the way, if you don't want users to be able to "paint over" existing tiles with new data then you can toss out Event# 7. In retrospect that should've been a toggle-able feature I think.

    Again I am sure there is a cleaner way to go about this but the idea is there, I hope it helps
    Attached files Attached files

  6. #6
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleMac Export Module
    dsilvers's Avatar
    Join Date
    Jun 2008
    Location
    Boston, MA
    Posts
    573
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    What about external tilesets? I know there's the Load Frame function, but it seems like that'd only be good for one image at a time, and it doesn't have a crop function. Could be a pain in terms of loading in an entire animation for a tile.

  7. #7
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCHTML5 Export ModuleiOS Export ModuleSWF Export ModuleInstall Creator Pro
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    chrilley's Avatar
    Join Date
    Jul 2006
    Posts
    941
    Mentioned
    16 Post(s)
    Tagged
    1 Thread(s)
    That's a bit trickier. I don't have an optimal or elegant solution here either but if your project can make use of Surface Object and possibly File Object(for cleanup) then I think I have something that *could* work.

    It consists of three steps:

    1) Load the external image for X fastloops where Surface object will slice it up frame by frame then export it in individual files.

    2) Now that the tiles are in a format Fusion can deal with we load each file into the Active Object, frame by frame.

    3) Build the tileset using the active object like before.


    Though this was literally the first idea that came to mind so hopefully there might be a better solution to this... An "Import frames/animations by Spritesheet" action would be neat to have. Especially for us who like to make mod-friendly games.

    [edit: Note that the Active Object must have frames created before loading new frames from the tileset. This example has 100 but you might need more, so just add as many as you like!]
    Attached files Attached files

  8. #8
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleMac Export Module
    dsilvers's Avatar
    Join Date
    Jun 2008
    Location
    Boston, MA
    Posts
    573
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by chrilley View Post
    An "Import frames/animations by Spritesheet" action would be neat to have. Especially for us who like to make mod-friendly games.
    Aye and I happen to be one of those people. My current plan is to ship with a decent number of tiles and ideally add mod support for tilesets down the line when an elegant and cross-platform solution can be found for getting them imported and stored into an active object. Also would limit animations to very specific lengths, so setting up a specific number of frames wouldn't be a problem.

Similar Threads

  1. How do i use tileset in CF Frame Editor?
    By hoyoyo80 in forum Fusion 2.5
    Replies: 5
    Last Post: 16th August 2018, 08:24 AM
  2. Replies: 0
    Last Post: 14th June 2018, 11:58 PM
  3. real time level editor while ai is actively running through level
    By FalconsoftIndustries in forum Fusion 2.5
    Replies: 2
    Last Post: 2nd September 2017, 06:18 AM
  4. Level editor problem
    By Shawn in forum Multimedia Fusion 2 - Technical Support
    Replies: 4
    Last Post: 2nd November 2009, 11:05 PM
  5. ISO Game Level Editor problem
    By nivram in forum File Archive
    Replies: 2
    Last Post: 9th September 2008, 03:07 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •