Zed fixes #16
@ -62,7 +62,6 @@ var NiceGameType NiceGT;
|
|||||||
var NicePack Mut;
|
var NicePack Mut;
|
||||||
var NiceRules GameRules;
|
var NiceRules GameRules;
|
||||||
var NiceStorageServer serverStorage;
|
var NiceStorageServer serverStorage;
|
||||||
var bool bClientLinkEstablished;
|
|
||||||
var bool interactionAdded;
|
var bool interactionAdded;
|
||||||
var bool bIsPreGame;
|
var bool bIsPreGame;
|
||||||
var bool bIsTraderTime;
|
var bool bIsTraderTime;
|
||||||
@ -309,10 +308,10 @@ simulated function Timer(){
|
|||||||
maxPlayersInGame = Max(maxPlayersInGame, currentPlayersMax);
|
maxPlayersInGame = Max(maxPlayersInGame, currentPlayersMax);
|
||||||
}
|
}
|
||||||
|
|
||||||
// add interaction
|
// initial tick, does some job and shuts down
|
||||||
auto state loadInteractionnSpawnRate
|
auto state loadInteractionnSpawnRate
|
||||||
{
|
{
|
||||||
// state timer, overrides global
|
// state tick, overrides global
|
||||||
simulated function Tick(float Delta)
|
simulated function Tick(float Delta)
|
||||||
{
|
{
|
||||||
local NiceInteraction niceInt;
|
local NiceInteraction niceInt;
|
||||||
@ -332,14 +331,23 @@ auto state loadInteractionnSpawnRate
|
|||||||
if (localPlayer == none)
|
if (localPlayer == none)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// spawn some magic
|
||||||
|
if (localPlayer.storageClient != none && localPlayer.remoteRI != none)
|
||||||
|
{
|
||||||
|
localPlayer.storageClient.remoteRI = localPlayer.remoteRI;
|
||||||
|
localPlayer.storageClient.events.static.CallLinkEstablished();
|
||||||
|
}
|
||||||
|
|
||||||
// Actually add the interaction
|
// Actually add the interaction
|
||||||
niceInt = NiceInteraction(localPlayer.Player.InteractionMaster.AddInteraction(string(class'NiceInteraction'), localPlayer.Player));
|
niceInt = NiceInteraction(localPlayer.Player.InteractionMaster.AddInteraction(string(class'NiceInteraction'), localPlayer.Player));
|
||||||
niceInt.RegisterMutator(Self);
|
niceInt.RegisterMutator(Self);
|
||||||
// break this and go to global state
|
|
||||||
|
// break this state and go to global
|
||||||
GoToState('');
|
GoToState('');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// global tick
|
||||||
simulated function Tick(float Delta)
|
simulated function Tick(float Delta)
|
||||||
{
|
{
|
||||||
local int i;
|
local int i;
|
||||||
@ -351,13 +359,7 @@ simulated function Tick(float Delta)
|
|||||||
// Check if the local PlayerController is available yet
|
// Check if the local PlayerController is available yet
|
||||||
if (localPlayer == none)
|
if (localPlayer == none)
|
||||||
return;
|
return;
|
||||||
if (Role < Role_AUTHORITY && !bClientLinkEstablished
|
|
||||||
&& localPlayer.storageClient != none && localPlayer.remoteRI != none)
|
|
||||||
{
|
|
||||||
bClientLinkEstablished = true;
|
|
||||||
localPlayer.storageClient.remoteRI = localPlayer.remoteRI;
|
|
||||||
localPlayer.storageClient.events.static.CallLinkEstablished();
|
|
||||||
}
|
|
||||||
if (localPlayer.bFlagDisplayCounters)
|
if (localPlayer.bFlagDisplayCounters)
|
||||||
{
|
{
|
||||||
for (i = 0; i < niceCounterSet.Length; i++)
|
for (i = 0; i < niceCounterSet.Length; i++)
|
||||||
|
Loading…
Reference in New Issue
Block a user