HUDs for vehicles

by Godmave

Shows HUDs when driving vehicles

Tweaks
4 years ago
0.17 - 1.1
1.94K

b Crash with Space Exploration Rocket

5 years ago
(updated 5 years ago)

Hey there, I tried your mod and like it! But here's a bug I found:

Space Exploration features Rocket Pods, essentially a modded vehicle you can't drive yourself, but use via a GUI to drop yourself down on another surface of a nearby planet (or, in scripting terms, you enter, click a button, watch the animation, change the surface, and see your avatar standing next to the landed pod, all without touching the keyboard).

Your mod tries to paint a HUD as soon as the avatar enter the pod. Then it misses the avatar being removed from the vehicle and teleported to the surface. Then, when you enter the landed pod again to maybe get rid of the dangling GUI, this happens:

Error MainLoop.cpp:1199: Exception at tick <bla>: The mod HUDs for vehicles caused a non-recoverable error.
Please report this error to the mod author.

Error while running event vehiclehud::on_player_driving_changed_state (ID 26)
Gui element with name vehiclehud already present in the parent element.
stack traceback:
vehiclehud/control.lua:116: in function 'showHud'
vehiclehud/control.lua:292: in function <vehiclehud/control.lua:288>
stack traceback:
[C]: in function 'add'
vehiclehud/control.lua:116: in function 'showHud'
vehiclehud/control.lua:292: in function <vehiclehud/control.lua:288

Apart from catching that error, maybe you should consider blacklisting the SE's rockets completely for HUD drawing purposes, as it is not useful there.

The vehicle is "se-space-capsule-_-vehicle", from what I can see in the code, I'm not sure why the funny underscore is in there. The corresponding item is just "se-space-capsule".

5 years ago

fixed

New response