question about some callins[SOLVED]

question about some callins[SOLVED]

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

Moderator: Moderators

Post Reply
res
Posts: 15
Joined: 19 Aug 2017, 21:27

question about some callins[SOLVED]

Post by res »

Hey, i tried to make some widget that makes watery sounds when units are moving in water or entering water. For this to work i first used a widget were enemy sounds were excluded. To also include these i used a gadget.(not sure if this is right way to go). This all worked fine since some of the callins were allready in the gadgetHandler (UnitEnteredWater, UnitLeftWater) but i am not sure if they should be there. (because on lua scripting documentation they are not). This all does what i want but i am not sure if i understand the scope of the problem since i do get some errors messages which hopefully not influence the game.

To be clear: the main question is is this the way to go to make such a gadget and second question should these callins be used as such?

gadget:
http://paste.springfiles.com/view/94d9bf7c

errors messages:
http://paste.springfiles.com/view/59d56a21

thanks,

greetz,
res
Last edited by res on 03 Sep 2017, 16:42, edited 1 time in total.
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: question about some callins

Post by gajop »

Should work if you use a new gadgethandler and engine https://github.com/spring/spring/commit ... 3bcb77d19d
res
Posts: 15
Joined: 19 Aug 2017, 21:27

Re: question about some callins[SOLVED]

Post by res »

Thanks that seems to make all fine :D
res
Posts: 15
Joined: 19 Aug 2017, 21:27

Re: question about some callins[SOLVED]

Post by res »

i did some changes and the final seems to work fine! It might be too loud for some ppl tho but less bugs!

https://github.com/xta-springrts/xta-sp ... ds_xta.lua

Just put it here for someone who cares!
Post Reply

Return to “Lua Scripts”