mirror of
https://github.com/scp-fs2open/fs2open.github.com.git
synced 2026-11-11 04:31:35 -10:00
Merge with master
This commit is contained in:
commit
ed84ac348e
54 files changed
+1347
-845
No files matched your search
+2
-5
@@ -10738,13 +10738,10 @@ ADE_VIRTVAR(DestroyedByWeapon, l_Weapon, "boolean", "Whether weapon was destroye
|
||||
weapon *wp = &Weapons[oh->objp->instance];
|
||||
|
||||
if(ADE_SETTING_VAR && numargs > 1) {
|
||||
if(b)
|
||||
wp->weapon_flags |= WF_DESTROYED_BY_WEAPON;
|
||||
else
|
||||
wp->weapon_flags &= ~WF_DESTROYED_BY_WEAPON;
|
||||
wp->weapon_flags.set(Weapon::Weapon_Flags::Destroyed_by_weapon, b);
|
||||
}
|
||||
|
||||
return ade_set_args(L, "b", (wp->weapon_flags & WF_DESTROYED_BY_WEAPON) > 0);
|
||||
return ade_set_args(L, "b", (wp->weapon_flags[Weapon::Weapon_Flags::Destroyed_by_weapon]) > 0);
|
||||
}
|
||||
|
||||
ADE_VIRTVAR(LifeLeft, l_Weapon, "number", "Weapon life left (in seconds)", "number", "Life left (seconds) or 0 if weapon handle is invalid")
|
||||
|
||||
Reference in new issue
Block a user