Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Improved Fluency and FPS


nickko
 Share

Recommended Posts

This is my Source code tutorial for improved client side FPS and fluency.

First we start by opening the ModGameLogic module.

Find This peice of code in the GameLoop Sub
```
' Lock fps
        Do While GetTickCount < Tick + 31
            DoEvents
            Sleep 1
```
Change the code to
```
' Lock fps
        Do While GetTickCount < Tick + 12
            DoEvents
            Sleep 1
```
This will lock the FPS at a much more acceptable rate, 64 FPS. But if you just leave it this way players will walk and run way to fast so…

In modConstants find your speed movement variables.
```
' Speed moving vars
Public Const WALK_SPEED = 1
Public Const RUN_SPEED = 2
Public Const GM_WALK_SPEED = 1
Public Const GM_RUN_SPEED = 2
Public SS_WALK_SPEED
Public SS_RUN_SPEED
' Set the variable to your desire,
' 32 is a safe and recommended setting
```
Essentially the rule is 32 FPS double it, 64 FPS tripple the numbers so if your not modifying this code in any way the correct numbers are

```
' Speed moving vars
Public Const WALK_SPEED = 2
Public Const RUN_SPEED = 4
Public Const GM_WALK_SPEED = 2
Public Const GM_RUN_SPEED = 4
Public SS_WALK_SPEED
Public SS_RUN_SPEED
' Set the variable to your desire,
' 32 is a safe and recommended setting

```
[Video Example](http://www.youtube.com/watch?v=WLJGEUfhGXY&feature=player_embedded)

Also Special thanks to scorpious2k for his Desynch fix tutorial.

Thank you and communicate your results here.
Link to comment
Share on other sites

@Nikola:

> …Thats the standard eclipse source code, dont ducking blame me.

Then change it. This doesn't 'improve' the FPS, it just hightens the cap. Which, I might add, will often do fuck all because Eclipse is so bloated. When I read the title of this topic, I expected you to remove the BitBlt, or the looped rendering, or some sort of optimisation.

Instead, it's just changing a number.
Link to comment
Share on other sites

@Marsh:

> It still can help people and thats all that matters.

Raising the FPS cap and the movement speed variables will cause more harm than good. It'll only give a slight visual improvement to those who have computers which can run Eclipse at 60fps+, whereas everyone else will have the entire game slow down.

If one player has 60 fps, and one has 30 fps and they're doing some PvP, the player with 60 fps will run twice as fast as the other.

Even though this is a problem with the default source code, this tutorial just makes the problem more pronounced.
Link to comment
Share on other sites

  • 2 weeks later...
@Kanе:

> My suggestion is offer a config file or add into the normal one so users can selection in options 32 or 64 then everyone wins?

Again, walking speed is based on FPS for some stupid reason, so no matter what you do Eclipse will be very insecure till you fix that.

Whoever runs at 64fps will run twice as fast as someone at 32fps.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...