mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
get markers to work
This commit is contained in:
parent
1c37c76cc6
commit
e55a85cc26
@ -2,10 +2,10 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
// recieve remote marker data
|
||||
[QGVAR(setMarkerNetwork), FUNC(setMarkerNetwork)] call EFUNC(common,addEventHandler);
|
||||
[QGVAR(setMarkerNetwork), {_this call DFUNC(setMarkerNetwork)}] call EFUNC(common,addEventHandler);
|
||||
|
||||
// recieve marker data for JIP
|
||||
[QGVAR(setMarkerJIP), FUNC(setMarkerJIP)] call EFUNC(common,addEventHandler);
|
||||
[QGVAR(setMarkerJIP), {_this call DFUNC(setMarkerJIP)}] call EFUNC(common,addEventHandler);
|
||||
|
||||
// request marker data for JIP
|
||||
if (isMultiplayer && {!isServer} && {hasInterface}) then {
|
||||
|
@ -4,8 +4,6 @@
|
||||
#define BORDER 0.005
|
||||
|
||||
[{
|
||||
with uinamespace do {
|
||||
|
||||
disableserialization;
|
||||
_display = _this select 0;
|
||||
|
||||
@ -33,8 +31,9 @@
|
||||
ctrlSetFocus _text;
|
||||
|
||||
//Change ok button's text based on current channel
|
||||
if (isNull _buttonOK) exitWith {true};
|
||||
//if (isNull _buttonOK) exitWith {true};
|
||||
|
||||
_channel = "";
|
||||
_textColor = [1,1,1,1];
|
||||
switch (call EFUNC(common,currentChannel)) do {
|
||||
case ("global"): {
|
||||
@ -153,7 +152,7 @@
|
||||
|
||||
_shape ctrlAddEventHandler ["LBSelChanged", {_this call FUNC(onLBSelChangedShape)}];
|
||||
|
||||
_curSelShape = GETMVAR(curSelMarkerShape,0);
|
||||
_curSelShape = GETGVAR(curSelMarkerShape,0);
|
||||
_shape lbSetCurSel _curSelShape;
|
||||
_data = _shape lbValue _curSelShape;
|
||||
_config = (configfile >> "CfgMarkers") select _data;
|
||||
@ -170,7 +169,7 @@
|
||||
|
||||
_color ctrlAddEventHandler ["LBSelChanged", {_this call FUNC(onLBSelChangedColor)}];
|
||||
|
||||
_curSelColor = GETMVAR(curSelMarkerColor,0);
|
||||
_curSelColor = GETGVAR(curSelMarkerColor,0);
|
||||
_color lbSetCurSel _curSelColor;
|
||||
_data = _color lbValue _curSelColor;
|
||||
_config = (configfile >> "CfgMarkerColors") select _data;
|
||||
@ -187,7 +186,7 @@
|
||||
_angle sliderSetRange [-180, 180];
|
||||
_angle ctrlAddEventHandler ["SliderPosChanged", {_this call FUNC(onSliderPosChangedAngle)}];
|
||||
|
||||
_curSelAngle = GETMVAR(curSelMarkerAngle,0);
|
||||
_curSelAngle = GETGVAR(curSelMarkerAngle,0);
|
||||
_angle sliderSetPosition _curSelAngle;
|
||||
|
||||
_curSelAngle = round _curSelAngle;
|
||||
@ -197,5 +196,4 @@
|
||||
|
||||
_angleText ctrlSetText format [localize "STR_ACE_Markers_MarkerDirection", _curSelAngle];
|
||||
|
||||
};
|
||||
}, _this] call EFUNC(common,execNextFrame);
|
||||
|
@ -30,11 +30,13 @@ if (_this select 1 == 1) then {
|
||||
[
|
||||
{
|
||||
|
||||
["setMarkerNetwork", [
|
||||
GETMVAR(currentMarkerShape,0),
|
||||
GETMVAR(currentMarkerColor,0),
|
||||
[QGVAR(setMarkerNetwork), [
|
||||
allMapMarkers select (count allMapMarkers - 1), [
|
||||
GETGVAR(currentMarkerShape,0),
|
||||
GETGVAR(currentMarkerColor,0),
|
||||
_this,
|
||||
GETMVAR(currentMarkerAngle,0)
|
||||
GETGVAR(currentMarkerAngle,0)
|
||||
]
|
||||
]] call EFUNC(common,globalEvent);
|
||||
|
||||
},
|
||||
|
@ -6,8 +6,8 @@ private "_logic";
|
||||
_logic = _this;
|
||||
|
||||
[QGVAR(setMarkerJIP), _logic, [
|
||||
GETMVAR(allMapMarkers,[]),
|
||||
GETMVAR(allMapMarkersProperties,[]),
|
||||
GETGVAR(allMapMarkers,[]),
|
||||
GETGVAR(allMapMarkersProperties,[]),
|
||||
_logic
|
||||
]
|
||||
] call EFUNC(common,targetEvent);
|
||||
|
Loading…
Reference in New Issue
Block a user