User Tag List

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 13

Thread: Sprite Engine

  1. #1


    Join Date
    Sep 2009
    Location
    Poland
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Sprite Engine

    Sprite engine for you!
    Attached files Attached files

  2. #2
    Clicker Fusion 2.5 Developer

    Join Date
    Jan 2007
    Location
    USA
    Posts
    691
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    Could you elaborate on what it is before we download?

    (P.S. Not everyone has a RAR extractor. I do, but just a friendly hint: make it a zip)

  3. #3


    Join Date
    Sep 2009
    Location
    Poland
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    It is the draw animations engine using a PNG file. Games based on this engine do not need use active objects, and the same method is borrowed from programming in C + +

    I publish a new version of the file, which you can change the speed of movement by pressing a key twice

    Attached files Attached files

  4. #4
    No Products Registered

    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    1,141
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    Why not use the Animated Picture object instead? It's kind of made for this purpose... Adding tons of backdrops every frame doesn't seem like an efficient solution to me.

  5. #5


    Join Date
    Sep 2009
    Location
    Poland
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    The answer is simple,if I would have drawing a large number of objects I would be forced to dynamically create new objects of "animated picture object" Currently in my game on the screen very quickly draws the map with layers and objects, including approximately 700 objects only through the use of one of the "Active picture object"

  6. #6
    No Products Registered

    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    1,141
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    I don't think ~20 fps for a single unit is regarded as "very quickly"... It would probably be a lot faster if you didn't paste the background every frame and used the "Remove Created Backdrops" action to remove the unit instead. Not loading the image every time it's used will probably speed it up as well.

    I agree that the Animated Picture object isn't very fast for many objects at the moment, but once it gets proper HWA support that won't be a problem.

  7. #7


    Join Date
    Sep 2009
    Location
    Poland
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    Test on Intel core 2 duo CPU E4600 @ 2.40GHz 2.40GHz, 2,00 GB RAM

    Game debugger show 41-47 FPS
    Event->Always->Set global Value A to FrameRate show 41-47 FPS
    Loop "Buffer" Draw 14784 object per second
    Loop "Buffer" Draw game screen 42 times per second

  8. #8
    No Products Registered

    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    1,141
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    My computer has: AMD Turion 64 X2 Mobile Technology TL-60 ~2.0GHz, 2GB Ram.
    I got 25 fps on the demo you posted. I made some changes in your demo:

    I moved the background into it's own layer and only paste it once at start of frame.
    I removed the player paste code from it's pretty unnecessary location inside a 22x16 loop and fixed it so that it uses the player position directly.
    I remove the last pasted player before pasting the new one.

    With these changes I now have 500+ fps. (Note that MMF cannot run any faster)
    I would like to test my changes with more objects, but unfortunately I feel that you have overcomplicated the movement code and I don't want to go through all of it.

  9. #9


    Join Date
    Sep 2009
    Location
    Poland
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    nice can u upload this?

    "I moved the background into it's own layer and only paste it once at start of frame."
    I always draw backgroundI did it to draw maps based on the array

  10. #10
    No Products Registered

    Join Date
    Mar 2007
    Location
    Sydney, Australia
    Posts
    1,369
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sprite Engine

    For scrolling backgrounds use the background images object.

Page 1 of 2 1 2 LastLast

Similar Threads

  1. Sprite Help
    By mr_mercury06uk in forum Multimedia Fusion 2 - Technical Support
    Replies: 11
    Last Post: 12th April 2013, 04:34 AM
  2. The Arcane Engine (RTS / RPG Engine)
    By Ryan in forum File Archive
    Replies: 36
    Last Post: 4th October 2009, 04:46 AM
  3. Sprite engine bug
    By Red21a in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 11th September 2009, 07:10 AM

Posting Permissions

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