User Tag List

Page 2 of 4 FirstFirst 1 2 3 4 LastLast
Results 11 to 20 of 35

Thread: Too many unique active objects = Corruption of Event Editor?

  1. #11
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleMac Export Module
    dsilvers's Avatar
    Join Date
    Jun 2008
    Location
    Boston, MA
    Posts
    630
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    Is there a way you can optimize that? For instance, take static props. Can you put all of those onto a single active object with a 0fps animation, and store an alterable value that'll be used to not only reference their type but also the frame of the animation to skip to when it's created?

  2. #12
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCFirefly 3D Module
    Tek's Avatar
    Join Date
    Jul 2007
    Posts
    40
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by dsilvers View Post
    Is there a way you can optimize that? For instance, take static props. Can you put all of those onto a single active object with a 0fps animation, and store an alterable value that'll be used to not only reference their type but also the frame of the animation to skip to when it's created?
    You make a good point. If I was just starting now I think I would try to do something closer to what you suggest than I currently am. I think I can optimize it a bit, but not as much as you suggest unfortunately. As it stands right now it would be quite a large task to essentially redo the system to have all of the basic static objects be in a single object. In particular the code to generate collision objects would need to be rethought entirely. I actually already do something similar to what you suggest but on a much smaller scale (not just one single object containing everything). For example I try to store all the different variations of a particular kind of static object in a single object by using animations and/or directions. Animations are used for texture variants, and directions are generally used for variations within a single texture variant not large enough to be a completely new texture variant. For example: All right facing 45 degree ramp piece texture variants in one object, all left facing 45 degree ramp piece texture variants in another, etc. The reasons for separating them into multiple objects at all was both because it's easier to navigate the list of animations that way, as it gets very annoying to use the animation list in an object once there are hundreds of animations (and it can't really be sorted), and because I didn't realize there was a second limit separate from the max objects per frame of how many unique active objects the event editor could handle.

    Actually, I do currently already store every background image for use in parallax scrolling layers in a single object.

    Regardless, I think going forwards I'll just have to increase how much I optimize the storage of static objects. What I have so far will stay, but I'll try to be far more cautious as to whether or not I should create a new object when I could just try to fit it into an additional animation of an existing object instead, as you suggest. I think I can probably avoid hitting the limit, if it's increased, by doing this. Of course it's still really good to have the limit increased to something like 10,000 so as to mitigate the problem and not have to worry as much. What really concerns me about staying under the limit is adding objects that require multiple animations to cycle through or objects that require qualifiers. Objects that require multiple, non-variant animations to cycle through aren't very good for storing tons of different variants of multiple objects animations inside. Objects with qualifiers can't be used properly for this type of optimization because the qualifiers can't change during the game.

  3. #13
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleMac Export Module
    dsilvers's Avatar
    Join Date
    Jun 2008
    Location
    Boston, MA
    Posts
    630
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    It sounds like some of these issues could be solved with a simple texture shader and changing the angle of the object instead of prebaking the texture onto a rotated animation frame (I'm guessing you're going for seamless textures, which is why you can't just set the angle via code). Unfortunately I don't have a whole lot of shader experience, but being able to texture a sprite with another image would be a seriously handy feature.

    Regardless, I can't tell you how many times I've thought I was on the right track in my level editor, and then suddenly had to break my game's legs just to get a more optimized system running (as recently as last week, actually). It also sounds like you might want to use the Load Animation Frame function, and keep your textures as external files included with the game. This way you can swap out for individual images on the player's hard drive, rather than needing to bake every single one into the game as a different object.

    For instance, if you have a ramp, and it's supposed to be grass, you could set a groundType string to Grass to on and a textureAngle value to say... 45. When the ramp is made, the game runs a fast loop to load the image file "grass45" from your $AppPath\Textures\Ground folder (via dynamically searching for the string groundType+Str$("textureAngle").png). With a system like this in place, and some naming convention discipline, you'll have an editor in place that's not only infinitely expandable, but reduces 99% of your active object overhead in the game, letting you focus on building worlds, rather than working around engine limits.

    There is no spoon.

  4. #14
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Volnaiskra's Avatar
    Join Date
    Jan 2014
    Location
    www.sprykegame.com
    Posts
    2,417
    Mentioned
    116 Post(s)
    Tagged
    0 Thread(s)
    I haven't hit 2000 yet, though it's possible I will once I eventually finish programming my game and start generating lots of different level and world graphics. 5000 sounds pretty safe for my project, and 10000 especially so.

  5. #15
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCFirefly 3D Module
    Tek's Avatar
    Join Date
    Jul 2007
    Posts
    40
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by dsilvers View Post
    It sounds like some of these issues could be solved with a simple texture shader and changing the angle of the object instead of prebaking the texture onto a rotated animation frame (I'm guessing you're going for seamless textures, which is why you can't just set the angle via code). Unfortunately I don't have a whole lot of shader experience, but being able to texture a sprite with another image would be a seriously handy feature.
    Yes, my textures are usually more or less made to appear seamless. Sometimes the variation in the images are going to be more than just simple changes in color though, so a shader probably wouldn't work in this particular case. Or I might be misunderstanding.

    Quote Originally Posted by dsilvers View Post
    It also sounds like you might want to use the Load Animation Frame function, and keep your textures as external files included with the game. This way you can swap out for individual images on the player's hard drive, rather than needing to bake every single one into the game as a different object.

    For instance, if you have a ramp, and it's supposed to be grass, you could set a groundType string to Grass to on and a textureAngle value to say... 45. When the ramp is made, the game runs a fast loop to load the image file "grass45" from your $AppPath\Textures\Ground folder (via dynamically searching for the string groundType+Str$("textureAngle").png). With a system like this in place, and some naming convention discipline, you'll have an editor in place that's not only infinitely expandable, but reduces 99% of your active object overhead in the game, letting you focus on building worlds, rather than working around engine limits.
    Thanks for the suggestions. I'm going to keep this Load Animation Frame method of yours in mind, along with your previous suggestion for a single static prop object. They both sound good and at a later date when I come back around to plugging more assets into my game, I'll take a deeper look into what needs to be done. Right now I'm in the middle of creating more art and animations and so I don't really have a clear picture of how many assets I'm going to end up with. Perhaps when all is said and done, the total number of assets in my game will fit within the new limit of unique objects anyways and I won't have to worry. Otherwise, I'll try to figure out some kind of new system based on what you've suggested.

  6. #16
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleMac Export Module
    dsilvers's Avatar
    Join Date
    Jun 2008
    Location
    Boston, MA
    Posts
    630
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    I could absolutely hit over 1000 actives generated in my game (yay level editors with a stamp), but I don't have anywhere close to 1000 object types, let alone 2000. Obviously any boost in object limits is welcome, especially when it comes to level editors as you never know what someone is gonna try to build. But smart optimization will always surpass more powerful tech.

  7. #17
    Clicker Fusion 2.5 MacFusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export ModuleInstall Creator Pro
    Christian_Wheel's Avatar
    Join Date
    Mar 2010
    Location
    Los Angeles
    Posts
    359
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Theoretical question - If we had a 64-bit runtime would it help alleviate the memory issues caused by large numbers of objects?

  8. #18
    Clickteam Clickteam

    Join Date
    Jun 2006
    Location
    France
    Posts
    13,697
    Mentioned
    236 Post(s)
    Tagged
    3 Thread(s)
    This thread was about the memory used by the object list in the event editor, not at runtime. A 64-bit runtime wouldn't help for this. And anyway I've double-checked I think I could set the maximum number of unique objects to 30,000 in this editor, that shouldn't be a problem.

    Memory issues at runtime are usually caused by images and sounds, not the number of objects. This is less a problem with the build 292 that supports up to 3.5 Gb of RAM and with the 2.5+ DLC image compression that reduces the size of the images (if you own this DLC).

  9. #19
    Clicker Fusion 2.5 (Steam)Fusion 2.5+ DLC (Steam)
    vSv's Avatar
    Join Date
    Aug 2010
    Location
    Sweden
    Posts
    109
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    30k objects would be really sweet! That would probably be enough for me even though I have so many AO's.

    One of the reasons as to why I have somany unique AO's is that I have larger pattern variants of smaller objects. For example, at certain places, instead of 4 pieces of 16x16 objects I have one large 32x32 object instead, or even larger things like 512x32 if there is a repeating pattern. This way I reduced the amount of AO's in certain frames from ~12k down to ~2,5k, and as such the level runs more smoothly and I don't need to load different parts of the level from arrays at runtime.

  10. #20
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCFirefly 3D Module
    Tek's Avatar
    Join Date
    Jul 2007
    Posts
    40
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That's awesome to hear that a limit of 30,000 could be possible after all, Yves. I'll be eagerly awaiting the update that has this limit increase.

    And build 292 supports up to 3.5 Gb of RAM?? How did I miss that? That's amazing, I had thought Fusion could only go up to around 2 Gb. Is that in an upcoming 292 update, or is it already in the current version?

Page 2 of 4 FirstFirst 1 2 3 4 LastLast

Similar Threads

  1. Replies: 3
    Last Post: 31st January 2017, 09:26 PM
  2. Dragging objects in event editor
    By soopytwist in forum Fusion 2.5
    Replies: 2
    Last Post: 15th November 2016, 09:33 PM
  3. Objects created in Event Editor vs Frame Editor
    By Grafer in forum Fusion 2.5
    Replies: 7
    Last Post: 7th October 2016, 10:46 PM
  4. Too many objects for Event Editor...
    By chrilley in forum Fusion 2.5
    Replies: 18
    Last Post: 31st January 2016, 09:25 PM
  5. Objects won't appear in event editor
    By sumgai in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 29th October 2012, 03:29 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
  •