Cannot get AllowWeaponTarget to work

Cannot get AllowWeaponTarget to work

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Post Reply
Google_Frog
Moderator
Posts: 2464
Joined: 12 Oct 2007, 09:24

Cannot get AllowWeaponTarget to work

Post by Google_Frog »

I am trying to use the relatively new gadget callin AllowWeaponTarget. I copied it from springcontent into the ZK gadget handler which I think I did successfully because I tested with Echo and it partially worked. I wrote a simple gadget to return false to all AllowWeaponTarget calls, this caused some units to not auto target (which is what I expected) but other units appeared unaffected. Has anyone else attempted to use this callin?
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6242
Joined: 29 Apr 2005, 01:14

Re: Cannot get AllowWeaponTarget to work

Post by FLOZi »

Suspect you need Script.SetWatchWeapon on for the weapondef or something?
Google_Frog
Moderator
Posts: 2464
Joined: 12 Oct 2007, 09:24

Re: Cannot get AllowWeaponTarget to work

Post by Google_Frog »

That had no effect.
Post Reply

Return to “Lua Scripts”