is there a way to send a message to all entities of the scene?
function callFn() requires you to specify a specific target...
if input.keyHit( "q" ) ==1 then sky.callGlobalFn(obj,"fire",1) end
if input.keyHit( "e" ) ==1 then sky.callGlobalFn(obj,"kill",1) end
function globalFn( callingID, message, data)
if callingID == playerID then
if message == "fire" then
--//////
elseif message =="kill" then
--/////
end
end
end
Users browsing this forum: No registered users and 1 guest