mirror of
https://github.com/scp-fs2open/fs2open.github.com.git
synced 2026-11-09 17:52:08 -10:00
Merge pull request #806 from The-E/ship_weapon_flags
Converts the flags of ship_weapon to use the new flag system
This commit is contained in:
commit
31fdcfdfbb
11 files changed
+120
-71
No files matched your search
+2
-6
@@ -7686,14 +7686,10 @@ ADE_VIRTVAR(TurretLocked, l_Subsystem, "boolean", "Whether the turret is locked.
|
||||
|
||||
if(ADE_SETTING_VAR)
|
||||
{
|
||||
if (newVal) {
|
||||
sso->ss->weapons.flags |= SW_FLAG_TURRET_LOCK;
|
||||
} else {
|
||||
sso->ss->weapons.flags &= (~SW_FLAG_TURRET_LOCK);
|
||||
}
|
||||
sso->ss->weapons.flags.set(Ship::Weapon_Flags::Turret_Lock, newVal);
|
||||
}
|
||||
|
||||
return ade_set_args(L, "b", (sso->ss->weapons.flags & SW_FLAG_TURRET_LOCK));
|
||||
return ade_set_args(L, "b", (sso->ss->weapons.flags[Ship::Weapon_Flags::Turret_Lock]));
|
||||
}
|
||||
|
||||
ADE_VIRTVAR(NextFireTimestamp, l_Subsystem, "number", "The next time the turret may attempt to fire", "number", "Mission time (seconds) or -1 on error")
|
||||
|
||||
Reference in new issue
Block a user