#how are you setting the value of the

1 messages · Page 1 of 1 (latest)

chrome vector
#

m_SignalsManager = SignalsManagerComponent.Cast(owner.FindComponent(SignalsManagerComponent));
m_iSignalIndex = m_SignalsManager.FindSignal(m_sSignalName);
m_SignalsManager.SetSignalValue(m_iSignalIndex, 1);

#

I think my error is somehow in the SignalName, either that I am using wrong reference, or if it doesn't register somehow

bold nexus
#

how does the inside of RBS69_LockonSignal.sig look like?

chrome vector
bold nexus
#

okay so m_sSignalName is a string with value SFP_RBS69_Lock?

#

do you see the signal value of 1 when you read the signal value in script?

#

also maybe replace FindSignal with AddOrFindSignal with a value of 0 for the signal to add it if it isn't already present

#

also also you could turn on signals debug with the debug menu and see if it pops up somewhere

chrome vector
#

I get index -1.. with "findsignal" och 1 when i change to addorFindSignal

bold nexus
#

-1 would be an error

dull bluff
#

Not at home right now but there should be a method/function along the lines of "AddOrFindSignal" with which you can simply set the signal name and value. No reason to mess around with indices.
Can imagine that it might be a bit less performant but unless called every frame, it shouldn't really matter too much