Page 4 of 6 FirstFirst ... 23456 LastLast
Results 31 to 40 of 54

Thread: RobotDuel - game for 2 players

  1. #31

    Re: RobotDuel - game for 2 players

    Hi Petr,

    I tryed the 1.6.4 version and I got this error:

    Ciao,
    Roberto
    Attached Images Attached Images
    http://www.thinbasic.com

  2. #32

    Re: RobotDuel - game for 2 players

    Hi Petr,

    I'm sorry, please discard my previous post because I was out-dated, now working fine @103FPS. :-[

    Regards,
    Roberto
    http://www.thinbasic.com

  3. #33
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    57
    Posts
    8,777
    Rep Power
    10

    Re: RobotDuel - game for 2 players

    Quote Originally Posted by Psch
    P.S. Eros, when you'll have time, would it be possible to change "Returns: Number" to "Returns: QUAD" in help file for QueryPerformanceCounter and QueryPerformanceFrequency ?
    Petr,

    almost all internal thinCore calculations are made using EXT numeric data type.
    When thinBasic encounter a generic NUMBER like in DIM MyVar as NUMBER in reality it creates an EXT data type. All functions declared to return a generic NUMBER in reality they return an EXT number. If you assign the return value of QueryPerformanceCounter or QueryPerformanceFrequency to a QUAD number, thinBasic takes care of relevant numeric conversions.

    Ciao
    Eros
    www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
    Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000

  4. #34
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,128
    Rep Power
    732

    Re: RobotDuel - game for 2 players

    Hi,

    Roberto, how could you live without latest fresh versions of tB with Math module? ;D
    Anyway, you jumped from 77 to 104 FPS ? I did not think the correction of AI "IF" statement and Math module optimization will have such a result

    Eros, thanks for the information. I just wanted to express if someone does not use general "AS NUMBER" declaration and tries to use "exact" LONGs, SINGLEs ... instead of it to get the maxximal performance, he could be surprised like me. There could be also little problem for DOS extremists with their love for INTEGERs But now I get it and no other statement does any problems to me. So ... all is ok


    Thanks,
    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

  5. #35

    Re: RobotDuel - game for 2 players

    Hi Petr,

    yes I discovered now why my life was becoming harder ;D
    As you can see Eros is careful and thrifty to distribute upgrade not only with the online guys :

    Also I'm remained been impressed to have earned 26 FPS!
    However tomorrow I'll check better then I'll let you know.

    Ciao,
    Roberto
    http://www.thinbasic.com

  6. #36
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    57
    Posts
    8,777
    Rep Power
    10

    Re: RobotDuel - game for 2 players

    Regarding FPS change, it all depends by the exact moment in which you get the screen picture. FPS can be very unstable in a short time period (let say few milliseconds). If you take the picture in a precise moment, just after few milliseconds FPS can be very different.

    On my box I can go from 50 FPS to 150 FPS in just 1 second. Remember we are executing scripts and not pure machine code, so parsing and script interpretation is the hardest and most CPU consuming part.

    I know thinBasic is very fast and sometime we have the impression to execute an EXE program but never forget we are executing scripts ;D

    Ciao
    Eros
    www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
    Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000

  7. #37

    Re: RobotDuel - game for 2 players

    Hi,

    I changed the ROBOTDUEL script for calculate the FPS average and letf the game running more time for 2+ minutes, so I can confirm the 100 FPS.

    Ciao,
    Roberto
    http://www.thinbasic.com

  8. #38
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,128
    Rep Power
    732

    Re: RobotDuel - game for 2 players

    Hi,

    thanks for the replies.
    Eros, you're right, FPS can vary. On my box the FPS deviation is not as brutal as on yours, its about 3 FPS up and down ( but I never achieve 150 ).

    Roberto, thanks for information on FPS. I'm thinking about "Run Benchmark" mode for testing purposes.

    Thanks,
    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

  9. #39

    Re: RobotDuel - game for 2 players

    Hi Petr,

    I made a simple but efficient average calculation, you can see it in the attached code.

    Ciao,
    Roberto

    Attached Files Attached Files
    http://www.thinbasic.com

  10. #40
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,128
    Rep Power
    732

    Re: RobotDuel - game for 2 players

    Hi Roberto,

    nice code. Can I integrate it to next release of RobotDuel ?

    Thanks,
    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

Page 4 of 6 FirstFirst ... 23456 LastLast

Similar Threads

  1. Game: Game modes
    By Michael Hartlef in forum CM contest 2009
    Replies: 16
    Last Post: 05-10-2008, 04:58

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

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