• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

[Tutorial] Fix freeze after spawn

Junior Spellweaver
Joined
Jun 22, 2014
Messages
175
Reaction score
87
If you spawn you are freezed at the spawnpoint and thats annoying.

WarZ.sln
Search:
Code:
// IF PLAYER IS FAST LOAD ON PLAYER CANT MOVE 12sec because fastload problem.        // wait 12 secs for fastload load building around player.
   // prevPos2 = GetPosition();
        if (g_FastLoad->GetBool() && r3dGetTime() > gClientLogic().localPlayerConnectedTime + 12 && gClientLogic().localPlayer_ == this)
          controller->Move(vel * TimePassed, 0.5f);
       
    if (!g_FastLoad->GetBool())
      controller->Move(vel * TimePassed, 0.5f);
 
        prevPos = GetPosition();
        controller->prevpos = GetPosition();
        parent::Update(); // manually update position after updating physics. Needed for camera, otherwise it will be lagging one frame behind

and change the red:
Code:
// IF PLAYER IS FAST LOAD ON PLAYER CANT MOVE 12sec because fastload problem.        // wait 12 secs for fastload load building around player.
   // prevPos2 = GetPosition();
[COLOR=#ff0000]       if (g_FastLoad->GetBool() && r3dGetTime() > gClientLogic().localPlayerConnectedTime + 1 && gClientLogic().localPlayer_ == this)[/COLOR]
          controller->Move(vel * TimePassed, 0.5f);
       
    if (!g_FastLoad->GetBool())
      controller->Move(vel * TimePassed, 0.5f);
 
        prevPos = GetPosition();
        controller->prevpos = GetPosition();
        parent::Update(); // manually update position after updating physics. Needed for camera, otherwise it will be lagging one frame behind

Credits: @GigaToni & Me
 
Last edited:
Custom Title Activated
Loyal Member
Joined
May 18, 2006
Messages
1,425
Reaction score
119
for high end pc

gClientLogic().localPlayerConnectedTime + 7

or

gClientLogic().localPlayerConnectedTime + 10
 
Junior Spellweaver
Joined
Jun 22, 2014
Messages
175
Reaction score
87
It´s equal, because it´s just the time where you are freezed. And no PC in this world will load this game in 1 second so it dont cares.
 
Custom Title Activated
Loyal Member
Joined
May 18, 2006
Messages
1,425
Reaction score
119
gClientLogic().localPlayerConnectedTime + 12

for anti-dupe item by double login game
 
Junior Spellweaver
Joined
Jun 22, 2014
Messages
175
Reaction score
87
Double login is blocked in dnc´s source...
 
Elite Diviner
Joined
Jan 11, 2011
Messages
464
Reaction score
216
Boohoo for all of you in space ships..

I don't see how this fixes the issues with 60% of players that are stuck on loading for a lot longer being spawned in game and unable to move due to screen being still on loading screen with 0 fps.
 
Junior Spellweaver
Joined
Jun 22, 2014
Messages
175
Reaction score
87
It's just for DNC New source with Fast load system.
 
Newbie Spellweaver
Joined
Dec 6, 2010
Messages
30
Reaction score
0
How to having this work with OverZ source? I can find the lines with fastload in it but it's quite not the same as the code above.
 
Back
Top