Toumal Posted August 18, 2022 Posted August 18, 2022 Hi, I'm trying to get information about the damage state of the player's aircraft from within Export.lua, and can't seem to get this to work. In essence, I want to know if the player's aircraft has sustained *any* damage, or if it's undamaged. local playerPlaneId = LoGetPlayerPlaneId() local playerUnit = LoGetObjectById(playerPlaneId) if (playerUnit == false) then return end if (playerUnit:getLife() < playerUnit:getLife0()) then return end This doesn't work because playerUnit doesn't have a function called getLife. This is probably the completely wrong way to try, I'd appreciate any help!
Recommended Posts