OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: bedges on 17 Jun 2005, 22:03:42

Title: empty strings...
Post by: bedges on 17 Jun 2005, 22:03:42
how does one check for an empty string. specifically, the secondaryweapon (http://www.ofpec.com/editors/comref.php?letter=S#secondaryWeapon) command returns an empty string when the unit hasn't got a secondary weapon, and

Code: [Select]
? secondaryweapon unit_name == "" : goto "marker"
isn't working.
Title: Re:empty strings...
Post by: Pilot on 17 Jun 2005, 22:12:00
I just tried this and it worked for me:
Quote
?secondaryweapon player == "": goto "marker"

-Student Pilot
Title: Re:empty strings...
Post by: bedges on 17 Jun 2005, 22:20:52
thanks. i'm an idiot ;)