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

Alerts exception when uncuffing #2744

Closed
metalgearsloth opened this issue Dec 15, 2020 · 1 comment · Fixed by #2748
Closed

Alerts exception when uncuffing #2744

metalgearsloth opened this issue Dec 15, 2020 · 1 comment · Fixed by #2748
Labels
P2: Raised Priority: Item has a raised priority, indicating it might get increased maintainer attention. T: Bugfix Type: Bugs and/or bugfixes

Comments

@metalgearsloth
Copy link
Contributor

@chairbender

Steps:

  1. Cuff yourself via another client
  2. Click on alert and get an exception on the server.

Stacktrace:

System.NullReferenceException: Object reference not set to an instance of an object.
   at Content.Server.GameObjects.Components.Mobs.ServerAlertsComponent.HandleNetworkMessage(ComponentMessage message, INetChannel netChannel, ICommonSession session) in D:\ProgrammingProjects\space-station-14\Content.Server\GameObjects\Components\Mobs\ServerAlertsComponent.cs:line 76
   at Robust.Shared.GameObjects.EntityManager.DispatchComponentMessage(NetworkComponentMessage netMsg) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Shared\GameObjects\EntityManager.cs:line 393
   at Robust.Shared.GameObjects.EntityManager.<Initialize>b__24_0(Object sender, NetworkComponentMessage compMsg) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Shared\GameObjects\EntityManager.cs:line 67
   at Robust.Server.GameObjects.ServerEntityNetworkManager.DispatchEntityNetworkMessage(MsgEntity message) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\GameObjects\ServerEntityNetworkManager.cs:line 155
   at Robust.Server.GameObjects.ServerEntityNetworkManager.Update() in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\GameObjects\ServerEntityNetworkManager.cs:line 57
   at Robust.Shared.GameObjects.EntityManager.Update(Single frameTime, Histogram histogram) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Shared\GameObjects\EntityManager.cs:line 90
   at Robust.Server.GameObjects.ServerEntityManager.Update(Single frameTime, Histogram histogram) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\GameObjects\ServerEntityManager.cs:line 963
   at Robust.Server.BaseServer.Update(FrameEventArgs frameEventArgs) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\BaseServer.cs:line 554
   at Robust.Server.BaseServer.<MainLoop>b__44_1(Object sender, FrameEventArgs args) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\BaseServer.cs:line 404
   at Robust.Shared.Timing.GameLoop.Run() in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Shared\Timing\GameLoop.cs:line 195
   at Robust.Server.BaseServer.MainLoop() in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\BaseServer.cs:line 410
   at Robust.Server.Program.ParsedMain(CommandLineArgs args, Boolean contentStart) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\Program.cs:line 87
   at Robust.Server.Program.<>c__DisplayClass2_0.<Start>b__0() in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\Program.cs:line 54
   at System.Threading.Tasks.Task.InnerInvoke()
   at System.Threading.Tasks.Task.<>c.<.cctor>b__277_0(Object obj)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
--- End of stack trace from previous location ---
   at Robust.Server.Program.Start(String[] args, Boolean contentStart) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\Program.cs:line 49
   at Robust.Server.Program.Main(String[] args) in D:\ProgrammingProjects\space-station-14\RobustToolbox\Robust.Server\Program.cs:line 28

I forgot to get what was null but should be easy enough to debug...

@metalgearsloth metalgearsloth added T: Bugfix Type: Bugs and/or bugfixes P2: Raised Priority: Item has a raised priority, indicating it might get increased maintainer attention. labels Dec 15, 2020
@chairbender
Copy link
Contributor

looking into it

gradientvera pushed a commit that referenced this issue Dec 16, 2020
* #2744 fix NRE on clicking alerts with no OnClick, and don't send the click
message unless the alert has an onclick

* #2744 fix NRE on clicking alerts with no OnClick, and don't send the click
message unless the alert has an onclick
collinlunn pushed a commit to collinlunn/space-station-14 that referenced this issue Dec 20, 2020
* space-wizards#2744 fix NRE on clicking alerts with no OnClick, and don't send the click
message unless the alert has an onclick

* space-wizards#2744 fix NRE on clicking alerts with no OnClick, and don't send the click
message unless the alert has an onclick
collinlunn pushed a commit to collinlunn/space-station-14 that referenced this issue Jan 6, 2021
* space-wizards#2744 fix NRE on clicking alerts with no OnClick, and don't send the click
message unless the alert has an onclick

* space-wizards#2744 fix NRE on clicking alerts with no OnClick, and don't send the click
message unless the alert has an onclick
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2: Raised Priority: Item has a raised priority, indicating it might get increased maintainer attention. T: Bugfix Type: Bugs and/or bugfixes
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants