This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
arma2:scripting:addpublicvariableeventhandler [2013-05-20 05:59] snakeman created addpublicvariableeventhandler initial page. |
arma2:scripting:addpublicvariableeventhandler [2015-05-31 23:04] (current) |
||
---|---|---|---|
Line 33: | Line 33: | ||
Easy. | Easy. | ||
+ | |||
+ | |||
+ | ====== ArmA 2 Global Broadcast ====== | ||
+ | |||
+ | <code php> | ||
+ | "PMC_Hint" addPublicVariableEventHandler | ||
+ | { | ||
+ | hint format["%1", (_this select 1)]; | ||
+ | }; | ||
+ | </code> | ||
+ | |||
+ | Then use it like: | ||
+ | <code php> | ||
+ | PMC_Hint = "Hello world!"; | ||
+ | </code> | ||
+ | |||
+ | And hello world is displayed as hint on every client. Very simple way to show hints from server to clients. |