diff options
author | zxcPandora <81985226+zxcPandora@users.noreply.github.com> | 2023-01-02 21:40:22 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-02 14:40:22 +0100 |
commit | 560c96d223711ac4f8a1eab7eb2a94531761ef0a (patch) | |
tree | 27f614d3be523f4dd7b2620204d8c6672c3b3f10 /Northstar.CustomServers | |
parent | fb44295254028d9396dd5bb84dc1bdc40bd57179 (diff) | |
download | NorthstarMods-560c96d223711ac4f8a1eab7eb2a94531761ef0a.tar.gz NorthstarMods-560c96d223711ac4f8a1eab7eb2a94531761ef0a.zip |
[FD]Bug fix and new feature (#556)
* Correction of variable type
Correction of variable type
* weapon type check
idk why Respawn use weapon.GetWeaponType(),it doesn't work for actually anti-titan weapon.(Because they didn't have this key value)
* fix wrong reaper icon
fix wrong reaper icon
* Show store in the minimap during buy time
Show store in the minimap during buy time
* ping store test
ping store test
Diffstat (limited to 'Northstar.CustomServers')
-rw-r--r-- | Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd.nut | 13 | ||||
-rw-r--r-- | Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd_events.nut | 4 |
2 files changed, 10 insertions, 7 deletions
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd.nut b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd.nut index b032d257..77275b9f 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd.nut +++ b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd.nut @@ -230,7 +230,7 @@ void function FD_GivePlayerInfiniteAntiTitanAmmo( entity player ) array<entity> weapons = player.GetMainWeapons() foreach ( entity weaponEnt in weapons ) { - if ( weaponEnt.GetWeaponType() != WT_ANTITITAN ) + if ( weaponEnt.GetWeaponInfoFileKeyField( "menu_category" ) != "at" ) continue if( !weaponEnt.HasMod( "at_unlimited_ammo" ) ) @@ -652,6 +652,9 @@ bool function runWave( int waveIndex, bool shouldDoBuyTime ) { SetGlobalNetInt( "FD_waveState", WAVE_STATE_BREAK ) OpenBoostStores() + entity parentCrate = GetBoostStores()[0].GetParent() + parentCrate.Minimap_AlwaysShow( TEAM_MILITIA, null ) + Minimap_PingForTeam( TEAM_MILITIA, shopPosition, 150, 5, TEAM_COLOR_YOU / 255.0, 5 ) foreach( entity player in GetPlayerArray() ) Remote_CallFunction_NonReplay( player, "ServerCallback_FD_NotifyStoreOpen" ) while( Time() < GetGlobalNetTime( "FD_nextWaveStartTime" ) ) @@ -660,7 +663,7 @@ bool function runWave( int waveIndex, bool shouldDoBuyTime ) SetGlobalNetTime( "FD_nextWaveStartTime", Time() ) WaitFrame() } - + parentCrate.Minimap_Hide( TEAM_MILITIA, null ) CloseBoostStores() MessageToTeam( TEAM_MILITIA, eEventNotifications.FD_StoreClosing ) } @@ -892,7 +895,7 @@ void function SetWaveStateReady() void function FD_StunLaserHealTeammate( entity player, entity target, int shieldRestoreAmount ) { if( IsValid( player ) && player in file.players ){ - file.playerAwardStats[player]["heals"] += float(shieldRestoreAmount) + file.playerAwardStats[player]["heals"] += float( shieldRestoreAmount ) player.AddToPlayerGameStat( PGS_DEFENSE_SCORE, shieldRestoreAmount / 100 ) file.players[ player ].scoreThisRound += shieldRestoreAmount / 100 } @@ -901,7 +904,7 @@ void function FD_StunLaserHealTeammate( entity player, entity target, int shield void function FD_SmokeHealTeammate( entity player, entity target, int shieldRestoreAmount ) { if( IsValid( player ) && player in file.players ){ - file.playerAwardStats[player]["heals"] += float(shieldRestoreAmount) + file.playerAwardStats[player]["heals"] += float( shieldRestoreAmount ) player.AddToPlayerGameStat( PGS_DEFENSE_SCORE, shieldRestoreAmount / 100 ) file.players[ player ].scoreThisRound += shieldRestoreAmount / 100 } @@ -927,7 +930,7 @@ void function FD_BatteryHealTeammate( entity battery, entity titan, int shieldRe if( IsValid( BatteryParent ) && BatteryParent in file.players ){ currentHeal = shieldRestoreAmount + healthRestoreAmount currentHealScore = currentHeal / 100 - file.playerAwardStats[BatteryParent]["heals"] += float(currentHeal) + file.playerAwardStats[BatteryParent]["heals"] += float( currentHeal ) BatteryParent.AddToPlayerGameStat( PGS_DEFENSE_SCORE, currentHealScore ) file.players[ BatteryParent ].scoreThisRound += currentHealScore } diff --git a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd_events.nut b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd_events.nut index bf887ba8..16260fd5 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd_events.nut +++ b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_fd_events.nut @@ -729,13 +729,13 @@ void function waitUntilLessThanAmountAliveEventWeighted( SmokeEvent smokeEvent, void function spawnSuperSpectre( SmokeEvent smokeEvent, SpawnEvent spawnEvent, FlowControlEvent flowControlEvent, SoundEvent soundEvent ) { PingMinimap( spawnEvent.origin.x, spawnEvent.origin.y, 4, 600, 150, 0 ) + wait 4.7 entity npc = CreateSuperSpectre( TEAM_IMC, spawnEvent.origin, spawnEvent.angles ) SetSpawnOption_AISettings( npc, "npc_super_spectre_fd" ) spawnedNPCs.append( npc ) if( spawnEvent.entityGlobalKey != "" ) GlobalEventEntitys[spawnEvent.entityGlobalKey] <- npc - wait 4.7 DispatchSpawn( npc ) SetTargetName( npc, GetTargetNameForID( spawnEvent.spawnType ) ) AddMinimapForHumans( npc ) @@ -747,13 +747,13 @@ void function spawnSuperSpectre( SmokeEvent smokeEvent, SpawnEvent spawnEvent, F void function spawnSuperSpectreWithMinion( SmokeEvent smokeEvent, SpawnEvent spawnEvent, FlowControlEvent flowControlEvent, SoundEvent soundEvent ) { PingMinimap( spawnEvent.origin.x, spawnEvent.origin.y, 4, 600, 150, 0 ) + wait 4.7 entity npc = CreateSuperSpectre( TEAM_IMC, spawnEvent.origin,spawnEvent.angles ) SetSpawnOption_AISettings( npc, "npc_super_spectre_fd" ) spawnedNPCs.append( npc ) if( spawnEvent.entityGlobalKey != "" ) GlobalEventEntitys[spawnEvent.entityGlobalKey] <- npc - wait 4.7 DispatchSpawn( npc ) SetTargetName( npc, GetTargetNameForID( spawnEvent.spawnType ) ) AddMinimapForHumans( npc ) |