Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hacked spectres causing a server crash in Attrition #649

Closed
CTalvio opened this issue Jun 13, 2023 · 7 comments · Fixed by #789
Closed

Hacked spectres causing a server crash in Attrition #649

CTalvio opened this issue Jun 13, 2023 · 7 comments · Fixed by #789
Labels
bug Something isn't working gamemode Issues related to gamemodes, custom or vanilla

Comments

@CTalvio
Copy link
Contributor

CTalvio commented Jun 13, 2023

Hello! There seems to be a crash that occurs when spectres are hacked. Something goes wrong with their teamswitch.

The relevant log snippet would seem to be:


[23:29:00] [SCRIPT SV] [info] SCRIPT ERROR: [SERVER] ERROR: Squad 'player13spectreSquad' has enemies in it! 523 npc_spectre [523] doesn't like 515 npc_spectre [515]
[23:29:00] [SCRIPT SV] [info]  -> guy.SetSquad( squadName )
[23:29:00] [SCRIPT SV] [info]
CALLSTACK
*FUNCTION [SetSquad()] _utility.gnut line [3512]
*FUNCTION [NPCFollowsPlayer()] ai/_ai_utility.gnut line [82]
*FUNCTION [LeechGenericThread()] pilot/_leeching.gnut line [431]

[23:29:00] [SCRIPT SV] [info] LOCALS
[squadName] "player13spectreSquad"
[guy] ENTITY (npc_spectre [523] (NPC "npc_spectre" at <-442.471 -422.705 90.5699>))
[this] TABLE
[squadName] "player13spectreSquad"
[leader] ENTITY (player J4GE [13] (player "J4GE" at <-425.756 -397.111 90.5699>))
[npc] ENTITY (npc_spectre [523] (NPC "npc_spectre" at <-442.471 -422.705 90.5699>))
[this] TABLE
[timerCredit] 9
[leechSound] "diag_spectre_gs_LeechEnd_01_1"
[leecher] ENTITY (player J4GE [13] (player "J4GE" at <-425.756 -397.111 90.5699>))
[self] ENTITY (npc_spectre [523] (NPC "npc_spectre" at <-442.471 -422.705 90.5699>))
[this] TABLE

DIAGPRINTS
@CTalvio CTalvio changed the title Hacked spectre causing a crash Hacked spectres causing a crash Jun 13, 2023
@CTalvio
Copy link
Contributor Author

CTalvio commented Jun 14, 2023

Addition: It does not happen every time, and seems somewhat rare. Though this may be due to how seldom players actually bother hacking spectres in multiplayer.

@GeckoEidechse
Copy link
Member

Crash is on client or server? What gamemode? (I guess Attrition, cause idk if you can hack spectres in other modes)

@CTalvio
Copy link
Contributor Author

CTalvio commented Jun 14, 2023

Attrition, on server.

@CTalvio CTalvio changed the title Hacked spectres causing a crash Hacked spectres causing a server crash in Attrition Jun 14, 2023
@CTalvio
Copy link
Contributor Author

CTalvio commented Jun 15, 2023

[11:33:21] [SCRIPT SV] [info] SCRIPT ERROR: [SERVER] Attempted to call EnableNPCFlag on invalid entity
[11:33:21] [SCRIPT SV] [info]  -> guy.EnableNPCFlag( NPC_ALLOW_PATROL | NPC_ALLOW_INVESTIGATE | NPC_ALLOW_HAND_SIGNALS | NPC_ALLOW_FLEE )
[11:33:21] [SCRIPT SV] [info]
CALLSTACK
*FUNCTION [SquadHandler()] gamemodes/_gamemode_aitdm.nut line [437]

[11:33:21] [SCRIPT SV] [info] LOCALS
[@ITERATOR@] 1
[guy] ENTITY (NULL)
[@INDEX@] 0
[point] <2720.3, -10203.8, 4575.86>
[points] ARRAY
[squadAlive] true
[players] ARRAY
[team] 2
[guys] ARRAY
[this] TABLE

DIAGPRINTS

Seems there might be more than one way spectre hacking can cause issues?

@F1F7Y
Copy link
Member

F1F7Y commented Jun 15, 2023

first one is probably caused by the player switching teams
second one is a probelm in ai spawning code

@ASpoonPlaysGames
Copy link
Contributor

first one is probably caused by the player switching teams

This could be solved by switching all hacked spectres when the player gets switched.

second one is a probelm in ai spawning code

This one is just going to be a simple fix, couple of lines at worst

@GeckoEidechse
Copy link
Member

GeckoEidechse commented Jul 20, 2023

first one is probably caused by the player switching teams

This could be solved by switching all hacked spectres when the player gets switched.

Could probably also just kill them off when the player switches. At least I assume that's less hassle to deal with ^^"
Unless there's a need to keep them around?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working gamemode Issues related to gamemodes, custom or vanilla
Projects
Archived in project
4 participants