SendLuaUIMsg Question
Posted: 08 Dec 2008, 18:30
When I send the following string (9 bytes) via SendLuaUIMsg I end up getting 10 bytes back in the recvFunction. Is it a bug or am I doing anything wrong?
I tried to figure out why AllyCursors-Widgets isnt working anymore (I think since 0.77b5) and noticed this (IMO strange) behavior.
Output:
Output:
I tried to figure out why AllyCursors-Widgets isnt working anymore (I think since 0.77b5) and noticed this (IMO strange) behavior.
Code: Select all
local msg = "123456789"
Spring.Echo( "Sending: " .. msg:len() )
SendLuaUIMsg( msg,"allies")
Code: Select all
Sending: 9
Code: Select all
function widget:RecvLuaMsg(msg, playerID)
Spring.Echo( "Receiving: " .. msg:len() )
end
Code: Select all
Receiving: 10