Delta Timing Vs Fixed Rate Logic Vs Timer

About Monkey 2 Forums Monkey 2 Programming Help Delta Timing Vs Fixed Rate Logic Vs Timer

This topic contains 4 replies, has 3 voices, and was last updated by  gcmartijn 2 years, 10 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #903

    therevills
    Participant

    What’s the best way to deal with various FPS for MX2?

    I’ve been messing around with the mojo example “space chimps” which uses the Timer class… and with my Monkeyroid I’ve converted a Fixed Rate Logic model…. but can’t decide what is the best way. Any clues?

    FRLTimer, converted from http://www.rightanglegames.com/top-down-shooter-tutorial-with-blitzmax.html

    Init FRL:

    In OnRender:

    So if your object has a default speed of 3.0, and you set your logic framerate to 100 it’ll move at 300 pixels per second…

    #2354

    gcmartijn
    Participant

    I hope that someone create (maybe mark) a good tutorial about

    deltatime / framerate / oprender / update in MX2

    A year ago I was using this for Monkey1 but I don’t know what now the best use is using MX2

    https://github.com/Regal-Internet-Brothers/deltatime

    Some tests using deltatime with huge ‘strange’ things

    http://www.monkey-x.com/Community/posts.php?topic=9918&post=107293&view=all#107293

    #2363

    wiebow
    Participant

    I am using fixed time to great satisfaction.

    #2364

    gcmartijn
    Participant

    Example please, is it slow Device proof ?

    I want to try something new, a fresh start using mx2.

    But as you can see I had some trouble with getting the most important thing oke, fps.

    is the way mx2 handle a render/update setframerate the same ?

    #2555

    gcmartijn
    Participant

    That fixed rate logic seems a good way, but I want to be sure before I’m going to start working with a new test project.

    I also use spacechimps as a start, and deleted the timer and other stuff

    My game is going to use

    • animated images using a atlas which contains the animation frame speed in ms
    • the animated images moving from point A to B in x speed (fixed)
    • has to work on ultra fast and/or slower computers/tablet/phone

    So my problem is , how do I can handle all those things without getting lag or moving to fast images.

    Does the fixed rate logic class solve all those problems for me ?
    So someone with a fast computer don’t see to fast movements or animations and <span style=”text-decoration: underline;”>very</span> slow computers see some frame drops (that is not my real problem, and impossible to fix).

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.