Jump to content
A 2021 backup has been restored. Forums are closed and work in progress. Join our Discord server for more updates! ×
SoaH City Message Board

Sonic Chaos Planet | Demo 1 Released


MrKsoft

Recommended Posts

  • Replies 125
  • Created
  • Last Reply

Top Posters In This Topic

I see that performance is definitely not me. =P

I have no clue how to fix it, though. Deleting all the extra animated lights, all the badniks, and all the rings only gets me back to about 40 fps. And that doesn't make a complete level. Could it be the backdrop objects...? The level's made of a bunch of 128x128 blocks for the most part. Would replacing some of those with quick backdrop versions help, or make it worse?

Link to comment
Share on other sites

I see that performance is definitely not me. =P

I have no clue how to fix it, though. Deleting all the extra animated lights, all the badniks, and all the rings only gets me back to about 40 fps. And that doesn't make a complete level. Could it be the backdrop objects...? The level's made of a bunch of 128x128 blocks for the most part. Would replacing some of those with quick backdrop versions help, or make it worse?

Probably worse. Can't you deactivate fine collision detection on rectangular shapes?

Link to comment
Share on other sites

Probably worse. Can't you deactivate fine collision detection on rectangular shapes?

It makes no difference.

Deleting a bunch (100-200?) of extra tiles that I put there just in case the camera breaks only gains me 2 fps.

Deleting the background paralax doesn't seem to gain anything.

Deactivating decorations, rings, enemies, and more when they're off screen doesn't even help.

I'm completely bewildered.

Link to comment
Share on other sites

I work in GM6, but I'm sure some of my experiences can help in MMF. Until recently, I had huge slowdown problems. By revising the code, streamlining it and altering it to rely on other objects a lot less, etc etc. I have made my game run a hell of a lot more smoothly. My code was convoluted and inefficient; I was unable to see what was wrong until I came to code the game's other characters, and the faults became apparent. It was down to so many factors; switching Sonic to another object (Sonic dying, starting the act, etc. are all handled by a single object now), my water and drowning code, my pseudo-Tension gauge and boost code - everything worked better when I improved many aspects of my code. Look at your code. What could be done better? What could be incorporated into a single variable or object? I'm still not entirely sure what caused certain instances of slowdown to vanish, but I knew my coding was improving dramatically, and vanish the slowdown did. The feeling of improvement is palpable, and perhaps if you take a fresh look at your work, you can make similar improvements.

I liked the demo; you got the animals right after destroying enemies, and the act end visuals were very well done. Frame rate aside, this has potential to be a highly satisfying fan game. Keep going, rework your code, and learn what makes a video game work well in terms of code. I know you can do this.

Link to comment
Share on other sites

Pretty nice, even with the low framerate.

It can be a problem with the fast loops. You may be running a fast loop too many times or something. You should also always stop fast loops when you don't need them anymore.

I think you could are more color to the level foreground. Since it's inside a cave, you could add some cave objects.

Link to comment
Share on other sites

I would really enjoy it... but framerate is TOOOOO low. But your level design is cool. I'll give you a peace of advice. Try to use picture object instead active objects for animated backgrounds. It will probably increase framerate BUT I DON'T PROMICE YOU

Link to comment
Share on other sites

It can be a problem with the fast loops. You may be running a fast loop too many times or something. You should also always stop fast loops when you don't need them anymore.

Yeah. I got like, a 25% speed boost in my Castlevania engine by tweaking the fastloops that controlled enemy gravity so they only ran when there were enemies near the screen.

Link to comment
Share on other sites

I loved this demo, It wasn't too buggy. I did find the lasers were the main problem, for example, you would hear a sound and no laser would be there, and I think they fire some too fast.

However, when I was playing it, it oddly enough gave me the feel of playing Sonic the HEdgehog 2, so good work! ^^

-Amesuki

Link to comment
Share on other sites

Well, it doesn't seem to be loops doing it... but, after a lot of individual group disabling, I found the culprit.

When I disable everything relating to rings, the game jumps up 25 fps. Seriously. However I can't figure out exactly what is specifically causing it, and I'm still only running at around 45 fps. Hm... I might be close to fixing it, and could maybe release an updated demo if I fix it.

EDIT: WTF? I just found that the FPS jump is caused by the bouncing (lost) ring collision code. Only disabling that will also give the same speed boost. This is odd, because it's the exact same collision system used in Damizean's ring loss tutorial...

Link to comment
Share on other sites

Well, it doesn't seem to be loops doing it... but, after a lot of individual group disabling, I found the culprit.

When I disable everything relating to rings, the game jumps up 25 fps. Seriously. However I can't figure out exactly what is specifically causing it, and I'm still only running at around 45 fps. Hm... I might be close to fixing it, and could maybe release an updated demo if I fix it.

EDIT: WTF? I just found that the FPS jump is caused by the bouncing (lost) ring collision code. Only disabling that will also give the same speed boost. This is odd, because it's the exact same collision system used in Damizean's ring loss tutorial...

Just as a record, what's the order of the events? Could it be you're checking for collision in first place before knowing if it should move?

Link to comment
Share on other sites

Well, unsure of what you meant. If you meant just the collision code...

ringcodesnippet.png

If you mean everything... then here are the headings for the sections in order:

-Pick up rings

-Create rings

-Deacceleration, Gravity and Timer

-Collisions

-Flash the Ring

-Destroy the Ring

-Set New X/Y Positions

Now as far as I see, this is set up identical to the tutorial (except for Pick Up Rings which I added)

Link to comment
Share on other sites

Too many active objects could be causing it, too. There's a handful of levels in Shadow of Chaos that run like ass because there's like 300+ rings in them. If I remove the rings, the framerate jumps back up to a solid 60 again.

Perhaps your level is just too big? If you have any big active objects, or numerous small active objects, it might be worth it to find a way to reduce them somehow.

If it's indeed rings, one creative way you can help fix it is by making an object that creates a string of three rings. I did this with Kingdom Valley 2D. When the "string of three rings" object comes on screen, it creates the rings. This cuts down the amount of rings in a frame by roughly one third and greatly helps improve performance.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...