mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Added cse_f_modules source
This commit is contained in:
parent
770230a64f
commit
fb4fcd62a4
49
TO_MERGE/cse/f_states/CfgFunctions.h
Normal file
49
TO_MERGE/cse/f_states/CfgFunctions.h
Normal file
@ -0,0 +1,49 @@
|
||||
class CfgFunctions {
|
||||
class CSE {
|
||||
class Carry {
|
||||
file = "cse\cse_f_states\carry\functions";
|
||||
class carryObj { recompile = 1; };
|
||||
class carriedByObj { recompile = 1; };
|
||||
class getCarriedObj { recompile = 1; };
|
||||
class getCarriedBy { recompile = 1; };
|
||||
class beingCarried { recompile = 1; };
|
||||
class setCarriedBy { recompile = 1; }; /* Should not be used by other developers */
|
||||
};
|
||||
class Unconscious {
|
||||
file = "cse\cse_f_states\unconscious\functions";
|
||||
class setUnconsciousState { recompile = 1; };
|
||||
class isUnconscious { recompile = 1; };
|
||||
class getUnconsciousCondition { recompile = 1; };
|
||||
class registerUnconsciousCondition { recompile = 1; };
|
||||
class setCaptiveSwitch { recompile = 1; };
|
||||
class moveToTempGroup { recompile = 1; };
|
||||
class canGoUnconsciousState { recompile = 1; };
|
||||
class setWeaponsCorrectUnconscious { recompile = 1; };
|
||||
};
|
||||
class Visual {
|
||||
file = "cse\cse_f_states\visual\functions";
|
||||
class effectPain { recompile = 1; };
|
||||
class effectBleeding { recompile = 1; };
|
||||
class effectBlackOut { recompile = 1; };
|
||||
};
|
||||
class Movement {
|
||||
file = "cse\cse_f_states\movement\functions";
|
||||
class limitMovementSpeed { recompile = 1; };
|
||||
class limitSpeed { recompile = 1; };
|
||||
};
|
||||
class Arrest {
|
||||
file = "cse\cse_f_states\arrest\functions";
|
||||
class setArrestState { recompile = 1; };
|
||||
class isArrested { recompile = 1; };
|
||||
};
|
||||
class LoadPerson {
|
||||
file = "cse\cse_f_states\LoadPerson\functions";
|
||||
class loadPerson_F { recompile = 1; };
|
||||
class loadPersonLocal_F {recompile = 1; };
|
||||
class makeCopyOfBody_F { recompile = 1; };
|
||||
class makeCopyOfBodyLocal_F { recompile = 1; };
|
||||
class unloadPerson_F { recompile = 1; };
|
||||
class cleanUpCopyOfBody_F { recompile = 1; };
|
||||
};
|
||||
};
|
||||
};
|
26
TO_MERGE/cse/f_states/Combat_Space_Enhancement.h
Normal file
26
TO_MERGE/cse/f_states/Combat_Space_Enhancement.h
Normal file
@ -0,0 +1,26 @@
|
||||
class Combat_Space_Enhancement
|
||||
{
|
||||
class EventHandlers
|
||||
{
|
||||
class PostInit_EventHandlers
|
||||
{
|
||||
class cse_f_states
|
||||
{
|
||||
init = " call compile preprocessFile 'cse\cse_f_states\init.sqf';";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
class CustomEventHandlers {
|
||||
class setUnconsciousState {}; // [unit, bool]
|
||||
class setArrestState {}; // [unit, bool]
|
||||
class carryObject {}; // [_unit, _to, _fallDown],"carryObject"
|
||||
|
||||
class carryObjectDropped {
|
||||
class cleanUpCopiesAfterDrag { // [unit, droppedObject]
|
||||
onCall = "[_this select 1] call cse_fnc_cleanUpCopyOfBody_f;";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
11
TO_MERGE/cse/f_states/arrest/functions/fn_isArrested.sqf
Normal file
11
TO_MERGE/cse/f_states/arrest/functions/fn_isArrested.sqf
Normal file
@ -0,0 +1,11 @@
|
||||
/**
|
||||
* fn_isArrested.sqf
|
||||
* @Descr: Check if unit is in arrested state
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: BOOL Returns true if unit or object is in arrest state
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
((_this select 0) getvariable ["cse_state_arrested",false])
|
43
TO_MERGE/cse/f_states/arrest/functions/fn_setArrestState.sqf
Normal file
43
TO_MERGE/cse/f_states/arrest/functions/fn_setArrestState.sqf
Normal file
@ -0,0 +1,43 @@
|
||||
/**
|
||||
* fn_setArrestState.sqf
|
||||
* @Descr: Set a unit in arrest state
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unitToBeArrested OBJECT, setArrested BOOL]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit","_setArrest"];
|
||||
_unit = [_this, 0, objNull, [objNull]] call BIS_fnc_Param;
|
||||
_setArrest = [_this, 1, false, [false]] call BIS_fnc_Param;
|
||||
|
||||
if (_setArrest) then {
|
||||
[_unit, "cse_state_arrested", true] call cse_fnc_setVariable;
|
||||
|
||||
if ([_unit] call cse_fnc_isAwake) then {
|
||||
if (vehicle _unit == _unit) then {
|
||||
[_unit,"UnaErcPoslechVelitele2",true] call cse_fnc_broadcastAnim;
|
||||
};
|
||||
};
|
||||
if (IsPlayer _unit) then {
|
||||
[["arrested", true],"cse_fnc_disableUserInput_f",_unit,false] call BIS_fnc_MP;
|
||||
};
|
||||
_unit disableAI "Move";
|
||||
_unit disableAI "ANIM";
|
||||
} else {
|
||||
[_unit, "cse_state_arrested", false] call cse_fnc_setVariable;
|
||||
|
||||
if ([_unit] call cse_fnc_isAwake) then {
|
||||
if (vehicle _unit == _unit) then {
|
||||
[_unit,"",true] call cse_fnc_broadcastAnim;
|
||||
};
|
||||
_unit enableAI "Move";
|
||||
_unit enableAI "ANIM";
|
||||
};
|
||||
if (IsPlayer _unit) then {
|
||||
[["arrested", false],"cse_fnc_disableUserInput_f",_unit,false] call BIS_fnc_MP;
|
||||
};
|
||||
};
|
||||
|
||||
[[_unit, _setArrest],"setArrestState"] call cse_fnc_customEventHandler_F;
|
13
TO_MERGE/cse/f_states/carry/functions/fn_beingCarried.sqf
Normal file
13
TO_MERGE/cse/f_states/carry/functions/fn_beingCarried.sqf
Normal file
@ -0,0 +1,13 @@
|
||||
/**
|
||||
* fn_beingCarried.sqf
|
||||
* @Descr: Check if object is being carried
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [object OBJECT]
|
||||
* @Return: BOOL True if object is being carried
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private["_object"];
|
||||
_object = [_this,0,ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
!(isNull ([_object] call cse_fnc_getCarriedObj));
|
15
TO_MERGE/cse/f_states/carry/functions/fn_carriedByObj.sqf
Normal file
15
TO_MERGE/cse/f_states/carry/functions/fn_carriedByObj.sqf
Normal file
@ -0,0 +1,15 @@
|
||||
/**
|
||||
* fn_carriedByObj.sqf
|
||||
* @Descr: Check if object A is being carried by object B.
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [object OBJECT, unit OBJECT]
|
||||
* @Return: BOOL True if B is carrying A.
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit","_to"];
|
||||
_to = _this select 0;
|
||||
_unit = _this select 1;
|
||||
|
||||
([_to] call cse_fnc_getCarriedBy == [_unit] call cse_fnc_getCarriedBy);
|
74
TO_MERGE/cse/f_states/carry/functions/fn_carryObj.sqf
Normal file
74
TO_MERGE/cse/f_states/carry/functions/fn_carryObj.sqf
Normal file
@ -0,0 +1,74 @@
|
||||
/**
|
||||
* fn_carryObj.sqf
|
||||
* @Descr: Have a unit carry an object. Use ObjNull for second parameter if you want the unit to carry nothing
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT, objectToCarry OBJECT, attachToVector ARRAY (Optional)]
|
||||
* @Return: BOOL Returns true if succesful
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit","_to","_return", "_fallDown", "_carriedObj", "_positionUnit"];
|
||||
_unit = [_this, 0,ObjNull, [ObjNull]] call bis_fnc_param;
|
||||
_to = [_this, 1,ObjNull, [ObjNull]] call bis_fnc_param;
|
||||
_fallDown = false;
|
||||
if (count _this > 3) then {
|
||||
_fallDown = _this select 3;
|
||||
};
|
||||
_return = false;
|
||||
|
||||
[format["fnc_carryObj - UNIT: %1 ATTEMPTS TO CARRY %2",_unit,_to],2] call cse_fnc_debug;
|
||||
|
||||
if (((typeName _to) == "OBJECT" && (isNull ([_unit] call cse_fnc_getCarriedObj))) || isNull _to) then {
|
||||
if (vehicle _unit != _unit) exitwith {};
|
||||
if (!isNull _to) then {
|
||||
if ((isNull ([_to] call cse_fnc_getCarriedObj)) && ([_unit] call cse_fnc_canInteract)) then {
|
||||
_return = true;
|
||||
_unit setvariable ["cse_carriedObj",_to,true];
|
||||
if (_fallDown) then {
|
||||
// [_unit,_fallDown] call cse_fnc_limitMovementSpeed;
|
||||
};
|
||||
[_to, _unit] call cse_fnc_setCarriedBy;
|
||||
if (count _this > 2) then {
|
||||
if (count (_this select 2) == 3) then {
|
||||
_to attachTo [_unit,(_this select 2)];
|
||||
[format["fnc_carryObj - UNIT: %1 TO %2 - attachTo offset: %3",_unit,_to,(_this select 2)],2] call cse_fnc_debug;
|
||||
};
|
||||
} else {
|
||||
[format["fnc_carryObj - UNIT: %1 TO %2 - Script expects external handling of attachTo Command. Exiting",_unit,_to],2] call cse_fnc_debug;
|
||||
};
|
||||
|
||||
[[_unit, _to, _fallDown],"carryObject"] call cse_fnc_customEventHandler_F;
|
||||
|
||||
};
|
||||
} else {
|
||||
if (!isNull ([_unit] call cse_fnc_getCarriedObj)) then {
|
||||
[format["fnc_carryObj - UNIT: %1 DROPING CARRIED OBJECT",_unit],2] call cse_fnc_debug;
|
||||
_carriedObj = ([_unit] call cse_fnc_getCarriedObj);
|
||||
|
||||
detach _carriedObj;
|
||||
//_carriedObj setPosATL [(getPosATL _carriedObj) select 0, (getPosATL _carriedObj) select 1,0];
|
||||
if (!surfaceIsWater getPos _unit) then {
|
||||
_positionUnit = getPosATL _carriedObj;
|
||||
_positionUnit set [2, ((getPosATL _unit) select 2) + 0.1];
|
||||
_carriedObj setPosATL _positionUnit;
|
||||
} else {
|
||||
_positionUnit = getPosASL _carriedObj;
|
||||
_positionUnit set [2, ((getPosASL _unit) select 2) + 0.1];
|
||||
_carriedObj setPosASL _positionUnit;
|
||||
};
|
||||
[[_unit, _carriedObj],"carryObjectDropped"] call cse_fnc_customEventHandler_F;
|
||||
|
||||
[[_unit] call cse_fnc_getCarriedObj, objNull] call cse_fnc_setCarriedBy;
|
||||
_unit setvariable ["cse_carriedObj",_to,true];
|
||||
_return = true;
|
||||
|
||||
[[_unit, _to, _fallDown],"carryObject"] call cse_fnc_customEventHandler_F;
|
||||
};
|
||||
};
|
||||
} else {
|
||||
[format["fnc_carryObj - UNIT: %1 FAILED TO CARRY %2 - not an object or already carrying",_unit,_to],2] call cse_fnc_debug;
|
||||
};
|
||||
|
||||
//[format["UNIT: %1 ATTEMPTS TO CARRY %2",_unit,_to],2] call cse_fnc_debug;
|
||||
_return
|
14
TO_MERGE/cse/f_states/carry/functions/fn_getCarriedBy.sqf
Normal file
14
TO_MERGE/cse/f_states/carry/functions/fn_getCarriedBy.sqf
Normal file
@ -0,0 +1,14 @@
|
||||
/**
|
||||
* fn_getCarriedBy.sqf
|
||||
* @Descr: Get the object that is carrying given unit or object
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: OBJECT Returns the object that is carrying the unit. Otherwise returns ObjNull
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit","_return"];
|
||||
_unit = [_this, 0, objNull, [objNull]] call BIS_fnc_param;
|
||||
_return = _unit getvariable ["cse_carriedBy",objNull];
|
||||
_return
|
14
TO_MERGE/cse/f_states/carry/functions/fn_getCarriedObj.sqf
Normal file
14
TO_MERGE/cse/f_states/carry/functions/fn_getCarriedObj.sqf
Normal file
@ -0,0 +1,14 @@
|
||||
/**
|
||||
* fn_getCarriedObj.sqf
|
||||
* @Descr: Grab the registered carried object
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: OBJECT Returns the object that the unit is currently carrying. If not carrying, returns ObjNull
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit","_return"];
|
||||
_unit = _this select 0;
|
||||
_return = _unit getvariable ["cse_carriedObj",objNull];
|
||||
_return
|
20
TO_MERGE/cse/f_states/carry/functions/fn_setCarriedBy.sqf
Normal file
20
TO_MERGE/cse/f_states/carry/functions/fn_setCarriedBy.sqf
Normal file
@ -0,0 +1,20 @@
|
||||
/**
|
||||
* fn_setCarriedBy.sqf
|
||||
* @Descr: Registers an object being carried by another object
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unitToBeCarried OBJECT, objectCarrying OBJECT]
|
||||
* @Return: BOOL True if succesfully registered
|
||||
* @PublicAPI: false
|
||||
*/
|
||||
|
||||
|
||||
private ["_unit","_to","_return"];
|
||||
_unit = [_this, 0, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_to = [_this, 1, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_return = false;
|
||||
if ((isNull ([_unit] call cse_fnc_getCarriedBy)) || isNull _to) then {
|
||||
_return = true;
|
||||
_unit setvariable ["cse_carriedBy",_to,true];
|
||||
};
|
||||
_return
|
26
TO_MERGE/cse/f_states/config.cpp
Normal file
26
TO_MERGE/cse/f_states/config.cpp
Normal file
@ -0,0 +1,26 @@
|
||||
#define _ARMA_
|
||||
class CfgPatches
|
||||
{
|
||||
class cse_f_states
|
||||
{
|
||||
units[] = {};
|
||||
weapons[] = {};
|
||||
requiredVersion = 0.1;
|
||||
requiredAddons[] = {"cse_main"};
|
||||
version = "0.5";
|
||||
author[] = {"Combat Space Enhancement"};
|
||||
authorUrl = "http://csemod.com";
|
||||
};
|
||||
};
|
||||
class CfgAddons {
|
||||
class PreloadAddons {
|
||||
class cse_f_states {
|
||||
list[] = {"cse_f_states"};
|
||||
};
|
||||
};
|
||||
};
|
||||
#include "CfgFunctions.h"
|
||||
#include "Combat_Space_Enhancement.h"
|
||||
#include "define.hpp"
|
||||
#include "visual\empty.hpp"
|
||||
#include "visual\effects.hpp"
|
BIN
TO_MERGE/cse/f_states/data/black_out1.paa
Normal file
BIN
TO_MERGE/cse/f_states/data/black_out1.paa
Normal file
Binary file not shown.
BIN
TO_MERGE/cse/f_states/data/cse_bleedingscreen_v5.paa
Normal file
BIN
TO_MERGE/cse/f_states/data/cse_bleedingscreen_v5.paa
Normal file
Binary file not shown.
BIN
TO_MERGE/cse/f_states/data/cse_blurryScreen.paa
Normal file
BIN
TO_MERGE/cse/f_states/data/cse_blurryScreen.paa
Normal file
Binary file not shown.
BIN
TO_MERGE/cse/f_states/data/cse_fadingblack.paa
Normal file
BIN
TO_MERGE/cse/f_states/data/cse_fadingblack.paa
Normal file
Binary file not shown.
BIN
TO_MERGE/cse/f_states/data/cse_painscreen.paa
Normal file
BIN
TO_MERGE/cse/f_states/data/cse_painscreen.paa
Normal file
Binary file not shown.
BIN
TO_MERGE/cse/f_states/data/hit_screen1.paa
Normal file
BIN
TO_MERGE/cse/f_states/data/hit_screen1.paa
Normal file
Binary file not shown.
BIN
TO_MERGE/cse/f_states/data/pain_screen3.paa
Normal file
BIN
TO_MERGE/cse/f_states/data/pain_screen3.paa
Normal file
Binary file not shown.
797
TO_MERGE/cse/f_states/define.hpp
Normal file
797
TO_MERGE/cse/f_states/define.hpp
Normal file
@ -0,0 +1,797 @@
|
||||
|
||||
#ifndef CSE_DEFINE_H
|
||||
#define CSE_DEFINE_H
|
||||
// define.hpp
|
||||
|
||||
#define true 1
|
||||
#define false 0
|
||||
|
||||
#define CT_STATIC 0
|
||||
#define CT_BUTTON 1
|
||||
#define CT_EDIT 2
|
||||
#define CT_SLIDER 3
|
||||
#define CT_COMBO 4
|
||||
#define CT_LISTBOX 5
|
||||
#define CT_TOOLBOX 6
|
||||
#define CT_CHECKBOXES 7
|
||||
#define CT_PROGRESS 8
|
||||
#define CT_HTML 9
|
||||
#define CT_STATIC_SKEW 10
|
||||
#define CT_ACTIVETEXT 11
|
||||
#define CT_TREE 12
|
||||
#define CT_STRUCTURED_TEXT 13
|
||||
#define CT_CONTEXT_MENU 14
|
||||
#define CT_CONTROLS_GROUP 15
|
||||
#define CT_SHORTCUTBUTTON 16
|
||||
#define CT_XKEYDESC 40
|
||||
#define CT_XBUTTON 41
|
||||
#define CT_XLISTBOX 42
|
||||
#define CT_XSLIDER 43
|
||||
#define CT_XCOMBO 44
|
||||
#define CT_ANIMATED_TEXTURE 45
|
||||
#define CT_OBJECT 80
|
||||
#define CT_OBJECT_ZOOM 81
|
||||
#define CT_OBJECT_CONTAINER 82
|
||||
#define CT_OBJECT_CONT_ANIM 83
|
||||
#define CT_LINEBREAK 98
|
||||
#define CT_ANIMATED_USER 99
|
||||
#define CT_MAP 100
|
||||
#define CT_MAP_MAIN 101
|
||||
#define CT_LISTNBOX 102
|
||||
|
||||
// Static styles
|
||||
#define ST_POS 0x0F
|
||||
#define ST_HPOS 0x03
|
||||
#define ST_VPOS 0x0C
|
||||
#define ST_LEFT 0x00
|
||||
#define ST_RIGHT 0x01
|
||||
#define ST_CENTER 0x02
|
||||
#define ST_DOWN 0x04
|
||||
#define ST_UP 0x08
|
||||
#define ST_VCENTER 0x0c
|
||||
|
||||
#define ST_TYPE 0xF0
|
||||
#define ST_SINGLE 0
|
||||
#define ST_MULTI 16
|
||||
#define ST_TITLE_BAR 32
|
||||
#define ST_PICTURE 48
|
||||
#define ST_FRAME 64
|
||||
#define ST_BACKGROUND 80
|
||||
#define ST_GROUP_BOX 96
|
||||
#define ST_GROUP_BOX2 112
|
||||
#define ST_HUD_BACKGROUND 128
|
||||
#define ST_TILE_PICTURE 144
|
||||
#define ST_WITH_RECT 160
|
||||
#define ST_LINE 176
|
||||
|
||||
#define ST_SHADOW 0x100
|
||||
#define ST_NO_RECT 0x200 // this style works for CT_STATIC in conjunction with ST_MULTI
|
||||
#define ST_KEEP_ASPECT_RATIO 0x800
|
||||
|
||||
#define ST_TITLE ST_TITLE_BAR + ST_CENTER
|
||||
|
||||
// Slider styles
|
||||
#define SL_DIR 0x400
|
||||
#define SL_VERT 0
|
||||
#define SL_HORZ 0x400
|
||||
|
||||
#define SL_TEXTURES 0x10
|
||||
|
||||
// Listbox styles
|
||||
#define LB_TEXTURES 0x10
|
||||
#define LB_MULTI 0x20
|
||||
#define FontCSE "PuristaMedium"
|
||||
|
||||
class cse_gui_backgroundBase {
|
||||
type = CT_STATIC;
|
||||
idc = -1;
|
||||
style = ST_PICTURE;
|
||||
colorBackground[] = {0,0,0,0};
|
||||
colorText[] = {1, 1, 1, 1};
|
||||
font = FontCSE;
|
||||
text = "";
|
||||
sizeEx = 0.032;
|
||||
};
|
||||
class cse_gui_editBase
|
||||
{
|
||||
access = 0;
|
||||
type = 2;
|
||||
x = 0;
|
||||
y = 0;
|
||||
h = 0.04;
|
||||
w = 0.2;
|
||||
colorBackground[] =
|
||||
{
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
1
|
||||
};
|
||||
colorText[] =
|
||||
{
|
||||
0.95,
|
||||
0.95,
|
||||
0.95,
|
||||
1
|
||||
};
|
||||
colorSelection[] =
|
||||
{
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.3843])",
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_G',0.7019])",
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_B',0.8862])",
|
||||
1
|
||||
};
|
||||
autocomplete = "";
|
||||
text = "";
|
||||
size = 0.2;
|
||||
style = "0x00 + 0x40";
|
||||
font = "PuristaMedium";
|
||||
shadow = 2;
|
||||
sizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)";
|
||||
colorDisabled[] =
|
||||
{
|
||||
1,
|
||||
1,
|
||||
1,
|
||||
0.25
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
class cse_gui_buttonBase {
|
||||
idc = -1;
|
||||
type = 16;
|
||||
style = ST_LEFT;
|
||||
text = "";
|
||||
action = "";
|
||||
x = 0.0;
|
||||
y = 0.0;
|
||||
w = 0.25;
|
||||
h = 0.04;
|
||||
size = 0.03921;
|
||||
sizeEx = 0.03921;
|
||||
color[] = {1.0, 1.0, 1.0, 1};
|
||||
color2[] = {1.0, 1.0, 1.0, 1};
|
||||
/*colorBackground[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])", "(profilenamespace getvariable ['GUI_BCG_RGB_A',0.5])"};
|
||||
colorbackground2[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])", 0.4};
|
||||
colorDisabled[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])", 0.25};
|
||||
colorFocused[] = {"(profilenamespace getvariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getvariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_B',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_A',0.8])", 0.8};
|
||||
colorBackgroundFocused[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])", 0.8};
|
||||
*/
|
||||
|
||||
colorBackground[] = {1,1,1,0.95};
|
||||
colorbackground2[] = {1,1,1,0.95};
|
||||
colorDisabled[] = {1,1,1,0.6};
|
||||
colorFocused[] = {1,1,1,1};
|
||||
colorBackgroundFocused[] = {1,1,1,1};
|
||||
periodFocus = 1.2;
|
||||
periodOver = 0.8;
|
||||
default = false;
|
||||
class HitZone {
|
||||
left = 0.00;
|
||||
top = 0.00;
|
||||
right = 0.00;
|
||||
bottom = 0.00;
|
||||
};
|
||||
|
||||
class ShortcutPos {
|
||||
left = 0.00;
|
||||
top = 0.00;
|
||||
w = 0.00;
|
||||
h = 0.00;
|
||||
};
|
||||
|
||||
class TextPos {
|
||||
left = 0.002;
|
||||
top = 0.0004;
|
||||
right = 0.0;
|
||||
bottom = 0.00;
|
||||
};
|
||||
textureNoShortcut = "";
|
||||
animTextureNormal = "cse\cse_gui\data\buttonNormal_gradient_top.paa";
|
||||
animTextureDisabled = "cse\cse_gui\data\buttonDisabled_gradient.paa";
|
||||
animTextureOver = "cse\cse_gui\data\buttonNormal_gradient_top.paa";
|
||||
animTextureFocused = "cse\cse_gui\data\buttonNormal_gradient_top.paa";
|
||||
animTexturePressed = "cse\cse_gui\data\buttonNormal_gradient_top.paa";
|
||||
animTextureDefault = "cse\cse_gui\data\buttonNormal_gradient_top.paa";
|
||||
period = 0.5;
|
||||
font = FontCSE;
|
||||
soundClick[] = {"\A3\ui_f\data\sound\RscButton\soundClick",0.09,1};
|
||||
soundPush[] = {"\A3\ui_f\data\sound\RscButton\soundPush",0.0,0};
|
||||
soundEnter[] = {"\A3\ui_f\data\sound\RscButton\soundEnter",0.07,1};
|
||||
soundEscape[] = {"\A3\ui_f\data\sound\RscButton\soundEscape",0.09,1};
|
||||
class Attributes {
|
||||
font = FontCSE;
|
||||
color = "#E5E5E5";
|
||||
align = "center";
|
||||
shadow = "true";
|
||||
};
|
||||
class AttributesImage {
|
||||
font = FontCSE;
|
||||
color = "#E5E5E5";
|
||||
align = "left";
|
||||
shadow = "true";
|
||||
};
|
||||
};
|
||||
|
||||
class cse_gui_RscProgress {
|
||||
type = 8;
|
||||
style = 0;
|
||||
colorFrame[] = {1,1,1,0.7};
|
||||
colorBar[] = {1,1,1,0.7};
|
||||
texture = "#(argb,8,8,3)color(1,1,1,0.7)";
|
||||
x = "1 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)";
|
||||
y = "10 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)";
|
||||
w = "38 * (((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
h = "0.5 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
};
|
||||
|
||||
|
||||
class cse_gui_staticBase {
|
||||
idc = -1;
|
||||
type = CT_STATIC;
|
||||
x = 0.0;
|
||||
y = 0.0;
|
||||
w = 0.183825;
|
||||
h = 0.104575;
|
||||
style = ST_LEFT;
|
||||
font = FontCSE;
|
||||
sizeEx = 0.03921;
|
||||
colorText[] = {0.95, 0.95, 0.95, 1.0};
|
||||
colorBackground[] = {0, 0, 0, 0};
|
||||
text = "";
|
||||
};
|
||||
|
||||
class RscListBox;
|
||||
class cse_gui_listBoxBase : RscListBox{
|
||||
type = CT_LISTBOX;
|
||||
style = ST_MULTI;
|
||||
font = FontCSE;
|
||||
sizeEx = 0.03921;
|
||||
color[] = {1, 1, 1, 1};
|
||||
colorText[] = {0.543, 0.5742, 0.4102, 1.0};
|
||||
colorScrollbar[] = {0.95, 0.95, 0.95, 1};
|
||||
colorSelect[] = {0.95, 0.95, 0.95, 1};
|
||||
colorSelect2[] = {0.95, 0.95, 0.95, 1};
|
||||
colorSelectBackground[] = {0, 0, 0, 1};
|
||||
colorSelectBackground2[] = {0.543, 0.5742, 0.4102, 1.0};
|
||||
colorDisabled[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])", 0.25};
|
||||
period = 1.2;
|
||||
rowHeight = 0.03;
|
||||
colorBackground[] = {0, 0, 0, 1};
|
||||
maxHistoryDelay = 1.0;
|
||||
autoScrollSpeed = -1;
|
||||
autoScrollDelay = 5;
|
||||
autoScrollRewind = 0;
|
||||
soundSelect[] = {"",0.1,1};
|
||||
soundExpand[] = {"",0.1,1};
|
||||
soundCollapse[] = {"",0.1,1};
|
||||
class ListScrollBar {
|
||||
arrowEmpty = "\A3\ui_f\data\gui\cfg\scrollbar\arrowEmpty_ca.paa";
|
||||
arrowFull = "\A3\ui_f\data\gui\cfg\scrollbar\arrowFull_ca.paa";
|
||||
autoScrollDelay = 5;
|
||||
autoScrollEnabled = 0;
|
||||
autoScrollRewind = 0;
|
||||
autoScrollSpeed = -1;
|
||||
border = "\A3\ui_f\data\gui\cfg\scrollbar\border_ca.paa";
|
||||
color[] = {1,1,1,0.6};
|
||||
colorActive[] = {1,1,1,1};
|
||||
colorDisabled[] = {1,1,1,0.3};
|
||||
height = 0;
|
||||
scrollSpeed = 0.06;
|
||||
shadow = 0;
|
||||
thumb = "\A3\ui_f\data\gui\cfg\scrollbar\thumb_ca.paa";
|
||||
width = 0;
|
||||
};
|
||||
class ScrollBar {
|
||||
color[] = {1, 1, 1, 0.6};
|
||||
colorActive[] = {1, 1, 1, 1};
|
||||
colorDisabled[] = {1, 1, 1, 0.3};
|
||||
thumb = "";
|
||||
arrowFull = "";
|
||||
arrowEmpty = "";
|
||||
border = "";
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
class cse_gui_listNBox {
|
||||
access = 0;
|
||||
type = CT_LISTNBOX;// 102;
|
||||
style =ST_MULTI;
|
||||
w = 0.4;
|
||||
h = 0.4;
|
||||
font = FontCSE;
|
||||
sizeEx = 0.031;
|
||||
|
||||
autoScrollSpeed = -1;
|
||||
autoScrollDelay = 5;
|
||||
autoScrollRewind = 0;
|
||||
arrowEmpty = "#(argb,8,8,3)color(1,1,1,1)";
|
||||
arrowFull = "#(argb,8,8,3)color(1,1,1,1)";
|
||||
columns[] = {0.0};
|
||||
color[] = {1, 1, 1, 1};
|
||||
|
||||
rowHeight = 0.03;
|
||||
colorBackground[] = {0, 0, 0, 0.2};
|
||||
colorText[] = {1,1, 1, 1.0};
|
||||
colorScrollbar[] = {0.95, 0.95, 0.95, 1};
|
||||
colorSelect[] = {0.95, 0.95, 0.95, 1};
|
||||
colorSelect2[] = {0.95, 0.95, 0.95, 1};
|
||||
colorSelectBackground[] = {0, 0, 0, 0.0};
|
||||
colorSelectBackground2[] = {0.0, 0.0, 0.0, 0.5};
|
||||
colorActive[] = {0,0,0,1};
|
||||
colorDisabled[] = {0,0,0,0.3};
|
||||
rows = 1;
|
||||
|
||||
drawSideArrows = 0;
|
||||
idcLeft = -1;
|
||||
idcRight = -1;
|
||||
maxHistoryDelay = 1;
|
||||
soundSelect[] = {"", 0.1, 1};
|
||||
period = 1;
|
||||
shadow = 2;
|
||||
class ScrollBar {
|
||||
arrowEmpty = "#(argb,8,8,3)color(1,1,1,1)";
|
||||
arrowFull = "#(argb,8,8,3)color(1,1,1,1)";
|
||||
border = "#(argb,8,8,3)color(1,1,1,1)";
|
||||
color[] = {1,1,1,0.6};
|
||||
colorActive[] = {1,1,1,1};
|
||||
colorDisabled[] = {1,1,1,0.3};
|
||||
thumb = "#(argb,8,8,3)color(1,1,1,1)";
|
||||
};
|
||||
class ListScrollBar {
|
||||
arrowEmpty = "\A3\ui_f\data\gui\cfg\scrollbar\arrowEmpty_ca.paa";
|
||||
arrowFull = "\A3\ui_f\data\gui\cfg\scrollbar\arrowFull_ca.paa";
|
||||
autoScrollDelay = 5;
|
||||
autoScrollEnabled = 0;
|
||||
autoScrollRewind = 0;
|
||||
autoScrollSpeed = -1;
|
||||
border = "\A3\ui_f\data\gui\cfg\scrollbar\border_ca.paa";
|
||||
color[] = {1,1,1,0.6};
|
||||
colorActive[] = {1,1,1,1};
|
||||
colorDisabled[] = {1,1,1,0.3};
|
||||
height = 0;
|
||||
scrollSpeed = 0.06;
|
||||
shadow = 0;
|
||||
thumb = "\A3\ui_f\data\gui\cfg\scrollbar\thumb_ca.paa";
|
||||
width = 0;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
class RscCombo;
|
||||
class cse_gui_comboBoxBase: RscCombo {
|
||||
idc = -1;
|
||||
type = 4;
|
||||
style = "0x10 + 0x200";
|
||||
x = 0;
|
||||
y = 0;
|
||||
w = 0.3;
|
||||
h = 0.035;
|
||||
color[] = {0,0,0,0.6};
|
||||
colorActive[] = {1,0,0,1};
|
||||
colorBackground[] = {0,0,0,1};
|
||||
colorDisabled[] = {1,1,1,0.25};
|
||||
colorScrollbar[] = {1,0,0,1};
|
||||
colorSelect[] = {0,0,0,1};
|
||||
colorSelectBackground[] = {1,1,1,0.7};
|
||||
colorText[] = {1,1,1,1};
|
||||
|
||||
arrowEmpty = "";
|
||||
arrowFull = "";
|
||||
wholeHeight = 0.45;
|
||||
font = FontCSE;
|
||||
sizeEx = 0.031;
|
||||
soundSelect[] = {"\A3\ui_f\data\sound\RscCombo\soundSelect",0.1,1};
|
||||
soundExpand[] = {"\A3\ui_f\data\sound\RscCombo\soundExpand",0.1,1};
|
||||
soundCollapse[] = {"\A3\ui_f\data\sound\RscCombo\soundCollapse",0.1,1};
|
||||
maxHistoryDelay = 1.0;
|
||||
class ScrollBar
|
||||
{
|
||||
color[] = {0.3,0.3,0.3,0.6};
|
||||
colorActive[] = {0.3,0.3,0.3,1};
|
||||
colorDisabled[] = {0.3,0.3,0.3,0.3};
|
||||
thumb = "\A3\ui_f\data\gui\cfg\scrollbar\thumb_ca.paa";
|
||||
arrowEmpty = "\A3\ui_f\data\gui\cfg\scrollbar\arrowEmpty_ca.paa";
|
||||
arrowFull = "\A3\ui_f\data\gui\cfg\scrollbar\arrowFull_ca.paa";
|
||||
border = "";
|
||||
};
|
||||
class ComboScrollBar {
|
||||
arrowEmpty = "\A3\ui_f\data\gui\cfg\scrollbar\arrowEmpty_ca.paa";
|
||||
arrowFull = "\A3\ui_f\data\gui\cfg\scrollbar\arrowFull_ca.paa";
|
||||
autoScrollDelay = 5;
|
||||
autoScrollEnabled = 0;
|
||||
autoScrollRewind = 0;
|
||||
autoScrollSpeed = -1;
|
||||
border = "\A3\ui_f\data\gui\cfg\scrollbar\border_ca.paa";
|
||||
color[] = {0.3,0.3,0.3,0.6};
|
||||
colorActive[] = {0.3,0.3,0.3,1};
|
||||
colorDisabled[] = {0.3,0.3,0.3,0.3};
|
||||
height = 0;
|
||||
scrollSpeed = 0.06;
|
||||
shadow = 0;
|
||||
thumb = "\A3\ui_f\data\gui\cfg\scrollbar\thumb_ca.paa";
|
||||
width = 0;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
class cse_gui_mapBase {
|
||||
moveOnEdges = 1;
|
||||
x = "SafeZoneXAbs";
|
||||
y = "SafeZoneY + 1.5 * ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
w = "SafeZoneWAbs";
|
||||
h = "SafeZoneH - 1.5 * ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
type = 100; // Use 100 to hide markers
|
||||
style = 48;
|
||||
shadow = 0;
|
||||
|
||||
ptsPerSquareSea = 5;
|
||||
ptsPerSquareTxt = 3;
|
||||
ptsPerSquareCLn = 10;
|
||||
ptsPerSquareExp = 10;
|
||||
ptsPerSquareCost = 10;
|
||||
ptsPerSquareFor = 9;
|
||||
ptsPerSquareForEdge = 9;
|
||||
ptsPerSquareRoad = 6;
|
||||
ptsPerSquareObj = 9;
|
||||
showCountourInterval = 0;
|
||||
scaleMin = 0.001;
|
||||
scaleMax = 1.0;
|
||||
scaleDefault = 0.16;
|
||||
maxSatelliteAlpha = 0.85;
|
||||
alphaFadeStartScale = 0.35;
|
||||
alphaFadeEndScale = 0.4;
|
||||
colorBackground[] = {0.969,0.957,0.949,1.0};
|
||||
colorSea[] = {0.467,0.631,0.851,0.5};
|
||||
colorForest[] = {0.624,0.78,0.388,0.5};
|
||||
colorForestBorder[] = {0.0,0.0,0.0,0.0};
|
||||
colorRocks[] = {0.0,0.0,0.0,0.3};
|
||||
colorRocksBorder[] = {0.0,0.0,0.0,0.0};
|
||||
colorLevels[] = {0.286,0.177,0.094,0.5};
|
||||
colorMainCountlines[] = {0.572,0.354,0.188,0.5};
|
||||
colorCountlines[] = {0.572,0.354,0.188,0.25};
|
||||
colorMainCountlinesWater[] = {0.491,0.577,0.702,0.6};
|
||||
colorCountlinesWater[] = {0.491,0.577,0.702,0.3};
|
||||
colorPowerLines[] = {0.1,0.1,0.1,1.0};
|
||||
colorRailWay[] = {0.8,0.2,0.0,1.0};
|
||||
colorNames[] = {0.1,0.1,0.1,0.9};
|
||||
colorInactive[] = {1.0,1.0,1.0,0.5};
|
||||
colorOutside[] = {0.0,0.0,0.0,1.0};
|
||||
colorTracks[] = {0.84,0.76,0.65,0.15};
|
||||
colorTracksFill[] = {0.84,0.76,0.65,1.0};
|
||||
colorRoads[] = {0.7,0.7,0.7,1.0};
|
||||
colorRoadsFill[] = {1.0,1.0,1.0,1.0};
|
||||
colorMainRoads[] = {0.9,0.5,0.3,1.0};
|
||||
colorMainRoadsFill[] = {1.0,0.6,0.4,1.0};
|
||||
colorGrid[] = {0.1,0.1,0.1,0.6};
|
||||
colorGridMap[] = {0.1,0.1,0.1,0.6};
|
||||
colorText[] = {1, 1, 1, 0.85};
|
||||
font = "PuristaMedium";
|
||||
sizeEx = 0.0270000;
|
||||
stickX[] = {0.20, {"Gamma", 1.00, 1.50} };
|
||||
stickY[] = {0.20, {"Gamma", 1.00, 1.50} };
|
||||
onMouseButtonClick = "";
|
||||
onMouseButtonDblClick = "";
|
||||
|
||||
fontLabel = "PuristaMedium";
|
||||
sizeExLabel = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 0.8)";
|
||||
fontGrid = "TahomaB";
|
||||
sizeExGrid = 0.02;
|
||||
fontUnits = "TahomaB";
|
||||
sizeExUnits = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 0.8)";
|
||||
fontNames = "PuristaMedium";
|
||||
sizeExNames = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 0.8) * 2";
|
||||
fontInfo = "PuristaMedium";
|
||||
sizeExInfo = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 0.8)";
|
||||
fontLevel = "TahomaB";
|
||||
sizeExLevel = 0.02;
|
||||
text = "#(argb,8,8,3)color(1,1,1,1)";
|
||||
class ActiveMarker {
|
||||
color[] = {0.30, 0.10, 0.90, 1.00};
|
||||
size = 50;
|
||||
};
|
||||
class Legend
|
||||
{
|
||||
x = "SafeZoneX + ( ((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
y = "SafeZoneY + safezoneH - 4.5 * ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
w = "10 * ( ((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
h = "3.5 * ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
font = "PuristaMedium";
|
||||
sizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 0.8)";
|
||||
colorBackground[] = {1,1,1,0.5};
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Task
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\taskIcon_CA.paa";
|
||||
iconCreated = "\A3\ui_f\data\map\mapcontrol\taskIconCreated_CA.paa";
|
||||
iconCanceled = "\A3\ui_f\data\map\mapcontrol\taskIconCanceled_CA.paa";
|
||||
iconDone = "\A3\ui_f\data\map\mapcontrol\taskIconDone_CA.paa";
|
||||
iconFailed = "\A3\ui_f\data\map\mapcontrol\taskIconFailed_CA.paa";
|
||||
color[] = {"(profilenamespace getvariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getvariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_B',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_A',0.8])"};
|
||||
colorCreated[] = {1,1,1,1};
|
||||
colorCanceled[] = {0.7,0.7,0.7,1};
|
||||
colorDone[] = {0.7,1,0.3,1};
|
||||
colorFailed[] = {1,0.3,0.2,1};
|
||||
size = 27;
|
||||
importance = 1;
|
||||
coefMin = 1;
|
||||
coefMax = 1;
|
||||
};
|
||||
class Waypoint
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\waypoint_ca.paa";
|
||||
color[] = {0,0,0,1};
|
||||
size = 20;
|
||||
importance = "1.2 * 16 * 0.05";
|
||||
coefMin = 0.900000;
|
||||
coefMax = 4;
|
||||
};
|
||||
class WaypointCompleted
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\waypointCompleted_ca.paa";
|
||||
color[] = {0,0,0,1};
|
||||
size = 20;
|
||||
importance = "1.2 * 16 * 0.05";
|
||||
coefMin = 0.900000;
|
||||
coefMax = 4;
|
||||
};
|
||||
class CustomMark
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\custommark_ca.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 1;
|
||||
coefMax = 1;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Command
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\waypoint_ca.paa";
|
||||
size = 18;
|
||||
importance = 1;
|
||||
coefMin = 1;
|
||||
coefMax = 1;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class Bush
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\bush_ca.paa";
|
||||
color[] = {0.45,0.64,0.33,0.4};
|
||||
size = "14/2";
|
||||
importance = "0.2 * 14 * 0.05 * 0.05";
|
||||
coefMin = 0.25;
|
||||
coefMax = 4;
|
||||
};
|
||||
class Rock
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\rock_ca.paa";
|
||||
color[] = {0.1,0.1,0.1,0.8};
|
||||
size = 12;
|
||||
importance = "0.5 * 12 * 0.05";
|
||||
coefMin = 0.25;
|
||||
coefMax = 4;
|
||||
};
|
||||
class SmallTree
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\bush_ca.paa";
|
||||
color[] = {0.45,0.64,0.33,0.4};
|
||||
size = 12;
|
||||
importance = "0.6 * 12 * 0.05";
|
||||
coefMin = 0.25;
|
||||
coefMax = 4;
|
||||
};
|
||||
class Tree
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\bush_ca.paa";
|
||||
color[] = {0.45,0.64,0.33,0.4};
|
||||
size = 12;
|
||||
importance = "0.9 * 16 * 0.05";
|
||||
coefMin = 0.25;
|
||||
coefMax = 4;
|
||||
};
|
||||
class busstop
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\busstop_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class fuelstation
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\fuelstation_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class hospital
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\hospital_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class church
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\church_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class lighthouse
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\lighthouse_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class power
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\power_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class powersolar
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\powersolar_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class powerwave
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\powerwave_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class powerwind
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\powerwind_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class quay
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\quay_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class shipwreck
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\shipwreck_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class transmitter
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\transmitter_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class watertower
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\watertower_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {1,1,1,1};
|
||||
};
|
||||
class Cross
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\Cross_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Chapel
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\Chapel_CA.paa";
|
||||
size = 24;
|
||||
importance = 1;
|
||||
coefMin = 0.85;
|
||||
coefMax = 1.0;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Bunker
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\bunker_ca.paa";
|
||||
size = 14;
|
||||
importance = "1.5 * 14 * 0.05";
|
||||
coefMin = 0.25;
|
||||
coefMax = 4;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Fortress
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\bunker_ca.paa";
|
||||
size = 16;
|
||||
importance = "2 * 16 * 0.05";
|
||||
coefMin = 0.25;
|
||||
coefMax = 4;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Fountain
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\fountain_ca.paa";
|
||||
size = 11;
|
||||
importance = "1 * 12 * 0.05";
|
||||
coefMin = 0.25;
|
||||
coefMax = 4;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Ruin
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\ruin_ca.paa";
|
||||
size = 16;
|
||||
importance = "1.2 * 16 * 0.05";
|
||||
coefMin = 1;
|
||||
coefMax = 4;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Stack
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\stack_ca.paa";
|
||||
size = 20;
|
||||
importance = "2 * 16 * 0.05";
|
||||
coefMin = 0.9;
|
||||
coefMax = 4;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class Tourism
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\tourism_ca.paa";
|
||||
size = 16;
|
||||
importance = "1 * 16 * 0.05";
|
||||
coefMin = 0.7;
|
||||
coefMax = 4;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
class ViewTower
|
||||
{
|
||||
icon = "\A3\ui_f\data\map\mapcontrol\viewtower_ca.paa";
|
||||
size = 16;
|
||||
importance = "2.5 * 16 * 0.05";
|
||||
coefMin = 0.5;
|
||||
coefMax = 4;
|
||||
color[] = {0,0,0,1};
|
||||
};
|
||||
};
|
||||
|
||||
#endif
|
104
TO_MERGE/cse/f_states/functions.sqf
Normal file
104
TO_MERGE/cse/f_states/functions.sqf
Normal file
@ -0,0 +1,104 @@
|
||||
/*
|
||||
|
||||
*/
|
||||
|
||||
|
||||
cse_fnc_setCanSwitchAnim = {
|
||||
private ["_unit","_to","_return"];
|
||||
_unit = _this select 0;
|
||||
_to = _this select 1;
|
||||
_return = false;
|
||||
if (((typeName _to) == "BOOL")) then {
|
||||
_unit setvariable ["cse_canSwitchAnimation",_to,true];
|
||||
_return = true;
|
||||
};
|
||||
_return
|
||||
};
|
||||
cse_fnc_getCanSwitchAnim = {
|
||||
private ["_unit","_return"];
|
||||
_unit = _this select 0;
|
||||
_return = _unit getvariable "cse_canSwitchAnimation";
|
||||
_return
|
||||
};
|
||||
|
||||
cse_fnc_setCurrentMenu = {
|
||||
_unit = _this select 0;
|
||||
_to = _this select 1;
|
||||
_return = false;
|
||||
if ((typeName _to) == "STRING") then {
|
||||
_unit setvariable ["cse_currentMenu",_to,true];
|
||||
_return = true;
|
||||
};
|
||||
_return
|
||||
};
|
||||
cse_fnc_getCurrentMenu = {
|
||||
_unit = _this select 0;
|
||||
_return = _unit getvariable ["cse_currentMenu",""];
|
||||
_return
|
||||
};
|
||||
|
||||
cse_fnc_changeBlurialVisionState = {
|
||||
private ["_unit","_to"];
|
||||
_unit = _this select 0;
|
||||
_to = _this select 1;
|
||||
_return = false;
|
||||
if (((typeName _to) == "SCALAR")) then {
|
||||
if (_to < -1) then {
|
||||
_to = -1;
|
||||
} else {
|
||||
if (_to > 1) then {
|
||||
_to = 1;
|
||||
};
|
||||
};
|
||||
_unit setvariable ["cse_blurialVisualState", [_unit] call cse_fnc_getBlurialVisionState + _to,false];
|
||||
_return = true;
|
||||
};
|
||||
_return
|
||||
};
|
||||
cse_fnc_getBlurialVisionState = {
|
||||
private ["_unit"];
|
||||
_unit = _this select 0;
|
||||
_return = _unit getvariable ["cse_blurialVisualState",0];
|
||||
_return
|
||||
};
|
||||
|
||||
// EVERYTHING BELOW HERE IS STILL WORK IN PROGRESS
|
||||
|
||||
cse_fnc_setMovementState = {
|
||||
private ["_unit","_to"];
|
||||
_unit = _this select 0;
|
||||
_to = _this select 1;
|
||||
_return = false;
|
||||
if (((typeName _to) == "SCALAR")) then {
|
||||
_unit setvariable ["cse_movementState",_to,false];
|
||||
_return = true;
|
||||
};
|
||||
_return
|
||||
};
|
||||
cse_fnc_getMovementState = {
|
||||
private ["_unit"];
|
||||
_unit = _this select 0;
|
||||
_return = _unit getvariable ["cse_movementState",0];
|
||||
_return
|
||||
};
|
||||
|
||||
cse_fnc_setHearingState = {
|
||||
private ["_unit","_to"];
|
||||
_unit = _this select 0;
|
||||
_to = _this select 1;
|
||||
_return = false;
|
||||
if (((typeName _to) == "SCALAR")) then {
|
||||
_unit setvariable ["cse_hearingState",_to,false];
|
||||
_return = true;
|
||||
};
|
||||
_return
|
||||
};
|
||||
cse_fnc_getHearingState = {
|
||||
private ["_unit"];
|
||||
_unit = _this select 0;
|
||||
_return = _unit getvariable ["cse_hearingState",0];
|
||||
_return
|
||||
};
|
||||
|
||||
|
||||
|
37
TO_MERGE/cse/f_states/init.sqf
Normal file
37
TO_MERGE/cse/f_states/init.sqf
Normal file
@ -0,0 +1,37 @@
|
||||
/*
|
||||
|
||||
*/
|
||||
|
||||
call compileFinal preprocessFile "cse\cse_f_states\functions.sqf";
|
||||
|
||||
if (!isDedicated) then {
|
||||
45 cutRsc ["RscCSEScreenEffectsBlack","PLAIN"];
|
||||
};
|
||||
|
||||
if (isServer) then {
|
||||
CSE_LOGIC_OBJECT = (createGroup sideLogic) createUnit ["logic", [1,1,1], [], 0, "FORM"];
|
||||
publicVariable "CSE_LOGIC_OBJECT";
|
||||
};
|
||||
|
||||
|
||||
["cse_isDead",false,true,"cse"] call cse_fnc_defineVariable;
|
||||
["cse_isDeadPlayer", false, true, "cse"] call cse_fnc_defineVariable;
|
||||
["cse_state_arrested",false,true,"cse"] call cse_fnc_defineVariable;
|
||||
["cse_state_unconscious",false,true,"cse"] call cse_fnc_defineVariable;
|
||||
["CSE_ENABLE_REVIVE_SETDEAD_F",0,false,"cse"] call cse_fnc_defineVariable;
|
||||
["cse_carriedBy",objNull,false,"cse"] call cse_fnc_defineVariable;
|
||||
|
||||
if (isnil "CSE_MARKED_FOR_GABAGE_COLLECTION") then {
|
||||
CSE_MARKED_FOR_GABAGE_COLLECTION = [];
|
||||
};
|
||||
|
||||
[] spawn {
|
||||
waituntil {
|
||||
{
|
||||
deleteVehicle _x;
|
||||
false;
|
||||
}count CSE_MARKED_FOR_GABAGE_COLLECTION;
|
||||
CSE_MARKED_FOR_GABAGE_COLLECTION = CSE_MARKED_FOR_GABAGE_COLLECTION - [objNull];
|
||||
false;
|
||||
};
|
||||
};
|
@ -0,0 +1,24 @@
|
||||
/**
|
||||
* fn_cleanUpCopyOfBody_f.sqf
|
||||
* @Descr: Called from a custom eventhandler to ensure that any copies of bodies are cleaned up.
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: BOOL
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit", "_copy"];
|
||||
_unit = _this select 0;
|
||||
|
||||
_copy = _unit getvariable "cse_copyOfBody_f";
|
||||
if (isnil "_copy") exitwith {false};
|
||||
[format["Cleaning up a copy of Body: %1 %2", _unit, _copy]] call cse_fnc_debug;
|
||||
// lets clean it up
|
||||
_unit setvariable ["cse_originalCopy_f", nil, true];
|
||||
_unit setvariable ["cse_copyOfBody_f", nil, true];
|
||||
if (!isNull _copy) then {
|
||||
deleteVehicle _copy;
|
||||
};
|
||||
|
||||
true;
|
@ -0,0 +1,37 @@
|
||||
/**
|
||||
* fn_loadPersonLocal_f.sqf
|
||||
* @Descr: Load a person, local
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT, vehicle OBJECT, caller OBJECT]
|
||||
* @Return: void
|
||||
* @PublicAPI: false
|
||||
*/
|
||||
|
||||
private ["_unit","_vehicle","_caller","_handle","_loaded"];
|
||||
_unit = [_this, 0, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_vehicle = [_this, 1, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_caller = [_this, 2, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
|
||||
if (!alive _unit) then {
|
||||
_unit = [_unit,_caller] call cse_fnc_makeCopyOfBody_F;
|
||||
};
|
||||
|
||||
_unit moveInCargo _vehicle;
|
||||
_loaded = _vehicle getvariable ["cse_loaded_persons_F",[]];
|
||||
_loaded pushback _unit;
|
||||
_vehicle setvariable ["cse_loaded_persons_F",_loaded,true];
|
||||
if (!([_unit] call cse_fnc_isAwake)) then {
|
||||
_handle = [_unit,_vehicle] spawn {
|
||||
private ["_unit","_vehicle"];
|
||||
_unit = _this select 0;
|
||||
_vehicle = _this select 1;
|
||||
waituntil {vehicle _unit == _vehicle};
|
||||
sleep 0.5;
|
||||
[_unit,([_unit] call cse_fnc_getDeathAnim)] call cse_fnc_broadcastAnim;
|
||||
};
|
||||
} else {
|
||||
if ([_unit] call cse_fnc_isArrested) then {
|
||||
|
||||
};
|
||||
};
|
@ -0,0 +1,40 @@
|
||||
/**
|
||||
* fn_loadPerson_f.sqf
|
||||
* @Descr: Loads a specified unit into any nearby vehicle
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [caller OBJECT, unitToBeLoaded OBJECT]
|
||||
* @Return: OBJECT Returns the vehicle that the unitToBeloaded has been loaded in. Returns ObjNull if function failed
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
#define GROUP_SWITCH_ID "cse_fnc_loadPerson_F"
|
||||
|
||||
private ["_caller", "_unit","_vehicle", "_loadcar", "_loadhelicopter", "_loadtank"];
|
||||
_caller = [_this, 0, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_unit = [_this, 1, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_vehicle = ObjNull;
|
||||
|
||||
if (!([_caller] call cse_fnc_canInteract) || {_caller == _unit}) exitwith {_vehicle};
|
||||
|
||||
_loadcar = nearestObject [_unit, "car"];
|
||||
if (_unit distance _loadcar <= 10) then {
|
||||
_vehicle = _loadcar;
|
||||
} else {
|
||||
_loadhelicopter = nearestObject [_unit, "air"];
|
||||
if (_unit distance _loadhelicopter <= 10) then {
|
||||
_vehicle = _loadhelicopter;
|
||||
} else {
|
||||
_loadtank = nearestObject [_unit, "tank"];
|
||||
if (_unit distance _loadtank <= 10) then {
|
||||
_vehicle = _loadtank;
|
||||
};
|
||||
};
|
||||
};
|
||||
if (!isNull _vehicle) then {
|
||||
[_unit, true, GROUP_SWITCH_ID, side group _caller] call cse_fnc_switchToGroupSide_f;
|
||||
[_caller,objNull] call cse_fnc_carryObj;
|
||||
[_unit,objNull] call cse_fnc_carryObj;
|
||||
[[_unit, _vehicle,_caller], "cse_fnc_loadPersonLocal_F", _unit, false] spawn BIS_fnc_MP;
|
||||
};
|
||||
_vehicle
|
@ -0,0 +1,62 @@
|
||||
/**
|
||||
* fn_makeCopyOfBodyLocal_f.sqf
|
||||
* @Descr: Makes a copy of a dead body. For handling dead bodies for actions such as load and carry.
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [oldBody OBJECT, newUnit OBJECT]
|
||||
* @Return: void
|
||||
* @PublicAPI: false
|
||||
*/
|
||||
|
||||
private ["_oldBody","_newUnit","_class","_group","_position","_side","_allVariables"];
|
||||
_oldBody = _this select 0;
|
||||
_newUnit = _this select 1;
|
||||
|
||||
if (alive _oldBody) exitwith {}; // we only want to do this for dead bodies
|
||||
_name = _oldBody getvariable ["cse_name","unknown"];
|
||||
_allVariables = [_oldBody] call cse_fnc_getAllSetVariables;
|
||||
// [NAME (STRING), TYPENAME (STRING), VALUE (ANY), DEFAULT GLOBAL (BOOLEAN)]
|
||||
{
|
||||
[_newUnit,_x select 0, _x select 2] call cse_fnc_setVariable;
|
||||
}foreach _allVariables;
|
||||
_newUnit setVariable ["cse_name",_name,true];
|
||||
|
||||
_newUnit disableAI "TARGET";
|
||||
_newUnit disableAI "AUTOTARGET";
|
||||
_newUnit disableAI "MOVE";
|
||||
_newUnit disableAI "ANIM";
|
||||
_newUnit disableAI "FSM";
|
||||
_newUnit setvariable ["cse_isDead",true,true];
|
||||
|
||||
removeallweapons _newUnit;
|
||||
removeallassigneditems _newUnit;
|
||||
removeUniform _newUnit;
|
||||
removeHeadgear _newUnit;
|
||||
removeBackpack _newUnit;
|
||||
removeVest _newUnit;
|
||||
|
||||
|
||||
_newUnit addHeadgear (headgear _oldBody);
|
||||
_newUnit addBackpack (backpack _oldBody);
|
||||
clearItemCargoGlobal (backpackContainer _newUnit);
|
||||
clearMagazineCargoGlobal (backpackContainer _newUnit);
|
||||
clearWeaponCargoGlobal (backpackContainer _newUnit);
|
||||
|
||||
_newUnit addVest (vest _oldBody);
|
||||
clearItemCargoGlobal (backpackContainer _newUnit);
|
||||
clearMagazineCargoGlobal (backpackContainer _newUnit);
|
||||
clearWeaponCargoGlobal (backpackContainer _newUnit);
|
||||
|
||||
_newUnit addUniform (uniform _oldBody);
|
||||
clearItemCargoGlobal (backpackContainer _newUnit);
|
||||
clearMagazineCargoGlobal (backpackContainer _newUnit);
|
||||
clearWeaponCargoGlobal (backpackContainer _newUnit);
|
||||
|
||||
{_newUnit addMagazine _x} count (magazines _oldBody);
|
||||
{_newUnit addWeapon _x} count (weapons _oldBody);
|
||||
{_newUnit addItem _x} count (items _oldBody);
|
||||
|
||||
_newUnit selectWeapon (primaryWeapon _newUnit);
|
||||
//[_newUnit,([_newUnit] call cse_fnc_getDeathAnim)] call cse_fnc_broadcastAnim;
|
||||
|
||||
deleteVehicle _oldBody;
|
@ -0,0 +1,88 @@
|
||||
/**
|
||||
* fn_makeCopyOfBody_f.sqf
|
||||
* @Descr: Makes a copy of a dead body. For handling dead bodies for actions such as load and carry.
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [oldBody OBJECT, caller OBJECT]
|
||||
* @Return: newUnit OBJECT Returns the copy of the unit. If no copy could be made, returns the oldBody
|
||||
* @PublicAPI: false
|
||||
*/
|
||||
|
||||
private ["_oldBody","_newUnit","_class","_group","_position","_side","_allVariables"];
|
||||
_oldBody = _this select 0;
|
||||
_caller = _this select 1;
|
||||
|
||||
if (alive _oldBody) exitwith {_oldBody}; // we only want to do this for dead bodies
|
||||
_name = _oldBody getvariable ["cse_name","unknown"];
|
||||
_class = typeof _oldBody;
|
||||
_side = side _caller;
|
||||
_group = createGroup _side;
|
||||
_position = getPos _oldBody;
|
||||
|
||||
_newUnit = _group createUnit [typeof _oldBody, _position, [], 0, "NONE"];
|
||||
|
||||
_allVariables = [_oldBody] call cse_fnc_getAllSetVariables;
|
||||
// [NAME (STRING), TYPENAME (STRING), VALUE (ANY), DEFAULT GLOBAL (BOOLEAN)]
|
||||
{
|
||||
[_newUnit,_x select 0, _x select 2] call cse_fnc_setVariable;
|
||||
}foreach _allVariables;
|
||||
_newUnit setVariable ["cse_name",_name,true];
|
||||
|
||||
_newUnit disableAI "TARGET";
|
||||
_newUnit disableAI "AUTOTARGET";
|
||||
_newUnit disableAI "MOVE";
|
||||
_newUnit disableAI "ANIM";
|
||||
_newUnit disableAI "FSM";
|
||||
_newUnit setvariable ["cse_isDead",true,true];
|
||||
|
||||
removeallweapons _newUnit;
|
||||
removeallassigneditems _newUnit;
|
||||
removeUniform _newUnit;
|
||||
removeHeadgear _newUnit;
|
||||
removeBackpack _newUnit;
|
||||
removeVest _newUnit;
|
||||
|
||||
|
||||
_newUnit addHeadgear (headgear _oldBody);
|
||||
_newUnit addBackpack (backpack _oldBody);
|
||||
clearItemCargoGlobal (backpackContainer _newUnit);
|
||||
clearMagazineCargoGlobal (backpackContainer _newUnit);
|
||||
clearWeaponCargoGlobal (backpackContainer _newUnit);
|
||||
|
||||
_newUnit addVest (vest _oldBody);
|
||||
clearItemCargoGlobal (backpackContainer _newUnit);
|
||||
clearMagazineCargoGlobal (backpackContainer _newUnit);
|
||||
clearWeaponCargoGlobal (backpackContainer _newUnit);
|
||||
|
||||
_newUnit addUniform (uniform _oldBody);
|
||||
clearItemCargoGlobal (backpackContainer _newUnit);
|
||||
clearMagazineCargoGlobal (backpackContainer _newUnit);
|
||||
clearWeaponCargoGlobal (backpackContainer _newUnit);
|
||||
|
||||
{_newUnit addMagazine _x} count (magazines _oldBody);
|
||||
{_newUnit addWeapon _x} count (weapons _oldBody);
|
||||
{_newUnit addItem _x} count (items _oldBody);
|
||||
|
||||
_newUnit selectWeapon (primaryWeapon _newUnit);
|
||||
//_newUnit playMoveNow ([_newUnit] call cse_fnc_getDeathAnim);
|
||||
|
||||
deleteVehicle _oldBody;
|
||||
|
||||
// try and clean it up entirely.
|
||||
if (!isNull _oldBody) then {
|
||||
|
||||
if (isMultiplayer) then {
|
||||
_oldBody hideObjectGlobal true;
|
||||
} else {
|
||||
_oldBody hideObject true;
|
||||
};
|
||||
_oldBody setvariable ["cse_originalCopy_f", true];
|
||||
_newUnit setvariable ["cse_copyOfBody_f", _oldBody];
|
||||
if (isnil "CSE_MARKED_FOR_GABAGE_COLLECTION") then {
|
||||
CSE_MARKED_FOR_GABAGE_COLLECTION = [];
|
||||
};
|
||||
CSE_MARKED_FOR_GABAGE_COLLECTION pushback _oldBody;
|
||||
};
|
||||
|
||||
_newUnit setDamage 0.9;
|
||||
_newUnit
|
@ -0,0 +1,57 @@
|
||||
/**
|
||||
* fn_unloadPerson_f.sqf
|
||||
* @Descr: Unload a person from a vehicle
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [caller OBJECT, unit OBJECT]
|
||||
* @Return: BOOL Returns true if succesfully unloaded person
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
#define GROUP_SWITCH_ID "cse_fnc_loadPerson_F"
|
||||
|
||||
private ["_caller", "_unit","_vehicle", "_loaded"];
|
||||
_caller = [_this, 0, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_unit = [_this, 1, ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_vehicle = vehicle _unit;
|
||||
|
||||
if (_vehicle == _unit) exitwith {false;};
|
||||
if !(speed _vehicle <1 && (((getpos _vehicle) select 2) < 2)) exitwith {false;};
|
||||
if (!([_caller] call cse_fnc_isAwake)) exitwith{false;};
|
||||
|
||||
moveOut _unit;
|
||||
unassignVehicle _unit;
|
||||
if (!alive _unit) then {
|
||||
_unit action ["Eject", vehicle _unit];
|
||||
};
|
||||
|
||||
[_unit, false, GROUP_SWITCH_ID, side group _caller] call cse_fnc_switchToGroupSide_f;
|
||||
|
||||
_loaded = _vehicle getvariable ["cse_loaded_persons_F",[]];
|
||||
_loaded = _loaded - [_unit];
|
||||
_vehicle setvariable ["cse_loaded_persons_F",_loaded,true];
|
||||
|
||||
if (!([_unit] call cse_fnc_isAwake)) then {
|
||||
_handle = [_unit,_vehicle] spawn {
|
||||
private ["_unit","_vehicle"];
|
||||
_unit = _this select 0;
|
||||
_vehicle = _this select 1;
|
||||
waituntil {vehicle _unit != _vehicle};
|
||||
[_unit,([_unit] call cse_fnc_getDeathAnim)] call cse_fnc_broadcastAnim;
|
||||
[format["Unit should move into death anim: %1", _unit]] call cse_fnc_Debug;
|
||||
};
|
||||
} else {
|
||||
if ([_unit] call cse_fnc_isArrested) then {
|
||||
_handle = [_unit,_vehicle] spawn {
|
||||
_unit = _this select 0;
|
||||
_vehicle = _this select 1;
|
||||
waituntil {vehicle _unit != _vehicle};
|
||||
[_unit,"UnaErcPoslechVelitele2",true] call cse_fnc_broadcastAnim;
|
||||
[format["Unit should move into arrested anim: %1", _unit]] call cse_fnc_Debug;
|
||||
};
|
||||
} else {
|
||||
[format["Unit should move into normal anim: %1", _unit]] call cse_fnc_Debug;
|
||||
};
|
||||
};
|
||||
|
||||
true;
|
@ -0,0 +1,34 @@
|
||||
/**
|
||||
* fn_limitMovementSpeed.sqf
|
||||
* @Descr: Limits the movement speed of a unit
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT, fallDown BOOL (Optional)]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
_this spawn {
|
||||
private ["_unit","_carriedObj"];
|
||||
_unit = _this select 0;
|
||||
_fallDown = false;
|
||||
if (count _this > 1) then {
|
||||
_fallDown = _this select 1;
|
||||
};
|
||||
_carriedObj = [_unit] call cse_fnc_getCarriedObj;
|
||||
while {sleep 1;_carriedObj = [_unit] call cse_fnc_getCarriedObj; ((!isNull _carriedObj) && (alive _unit))} do {
|
||||
if (speed _unit > 12 && vehicle _unit == _unit) then {
|
||||
[format["Unit ran to fast (Speed: %1, is now dropping carrying obj",speed _unit],2] call cse_fnc_debug;
|
||||
if (_fallDown) then {
|
||||
_unit playMove "amovppnemstpsraswrfldnon";
|
||||
};
|
||||
|
||||
if (_carriedObj isKindOf "Man") then {
|
||||
hint "You can not move this fast while transporting this person.";
|
||||
} else {
|
||||
hint "You can not move this fast while carrying this object";
|
||||
};
|
||||
[_unit,ObjNull] call cse_fnc_carryObj;
|
||||
};
|
||||
};
|
||||
};
|
38
TO_MERGE/cse/f_states/movement/functions/fn_limitSpeed.sqf
Normal file
38
TO_MERGE/cse/f_states/movement/functions/fn_limitSpeed.sqf
Normal file
@ -0,0 +1,38 @@
|
||||
/**
|
||||
* fn_limitSpeed.sqf
|
||||
* @Descr: Limits the speed of an object
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [vehicle OBJECT, maxSpeed NUMBER]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
_this spawn {
|
||||
private ["_vehicle", "_maxSpeed", "_velocity"];
|
||||
|
||||
_vehicle = _this select 0;
|
||||
_maxSpeed = _this select 1;
|
||||
if ((_vehicle getvariable ["cse_f_limitSpeed",false])) then {
|
||||
_vehicle setvariable ["cse_f_limitSpeed",nil,true];
|
||||
};
|
||||
|
||||
if (_maxSpeed < 0) exitwith {};
|
||||
_vehicle setvariable ["cse_f_limitSpeed",true,true];
|
||||
|
||||
waitUntil {
|
||||
_speed = speed _vehicle;
|
||||
if (_speed > _maxSpeed) then {
|
||||
_velocity = velocity _vehicle;
|
||||
_x = _velocity select 0;
|
||||
_y = _velocity select 1;
|
||||
_z = _velocity select 2;
|
||||
|
||||
_diff = _speed - _maxSpeed;
|
||||
_percentage = (_speed / 100) * _diff;
|
||||
_newVelocity = [_x - (_x * _percentage), _y - (_y * _percentage), _z - (_z * _percentage)];
|
||||
_vehicle setVelocity _newVelocity;
|
||||
};
|
||||
!(_vehicle getvariable ["cse_f_limitSpeed",false])
|
||||
};
|
||||
};
|
7
TO_MERGE/cse/f_states/stringtable.xml
Normal file
7
TO_MERGE/cse/f_states/stringtable.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<Project name="Combat Space Enhancement">
|
||||
<Package name="cse_f_states">
|
||||
<Container ID="States">
|
||||
</Container>
|
||||
</Package>
|
||||
</Project>
|
@ -0,0 +1,14 @@
|
||||
/**
|
||||
* fn_canGoUnconsciousState.sqf
|
||||
* @Descr: Checks if an object can move into unconscious state
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: BOOL true if object can move into unconscious state
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit"];
|
||||
_unit = _this select 0;
|
||||
|
||||
(!(isNull _unit) && {(_unit isKindOf "CaManBase") && ([_unit] call cse_fnc_isAwake)})
|
@ -0,0 +1,32 @@
|
||||
/**
|
||||
* fn_getUnconsciousCondition.sqf
|
||||
* @Descr: get whatever or not a unit should be or stay unconscious
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: BOOL True when the unit should be unconscious
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_unit","_return"];
|
||||
_unit = _this select 0;
|
||||
|
||||
|
||||
if (isnil "CSE_UNCONSCIOUS_CONDITIONS_F") then {
|
||||
CSE_UNCONSCIOUS_CONDITIONS_F = [];
|
||||
};
|
||||
|
||||
_return = false;
|
||||
{
|
||||
|
||||
|
||||
if (typeName _x == typeName {}) then {
|
||||
if (([_unit] call _x)) then {
|
||||
_return = true;
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
if (_return) exitwith{};
|
||||
}foreach CSE_UNCONSCIOUS_CONDITIONS_F;
|
||||
_return
|
@ -0,0 +1,11 @@
|
||||
/**
|
||||
* fn_isUnconscious.sqf
|
||||
* @Descr: Checks whatever given object is in the unconscious state
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: BOOL True when object is in unconscious state
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
((_this select 0) getvariable ["cse_state_unconscious",false]);
|
@ -0,0 +1,30 @@
|
||||
/**
|
||||
* fn_moveToTempGroup_f.sqf
|
||||
* Moves a unit into a temporarly group and stores its original group to allow rejoining.
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT, moveToTempGroup BOOL]
|
||||
* @Return: void
|
||||
* @PublicAPI: false
|
||||
*/
|
||||
|
||||
private ["_unit","_moveTo","_previousGroup","_newGroup", "_currentGroup", "_switchToGroup"];
|
||||
_unit = [_this, 0,ObjNull,[ObjNull]] call BIS_fnc_Param;
|
||||
_moveTo = [_this, 1,false,[false]] call BIS_fnc_Param;
|
||||
|
||||
if (_moveTo) then {
|
||||
_previousGroup = group _unit;
|
||||
_newGroup = createGroup (side _previousGroup);
|
||||
[_unit] joinSilent _newGroup;
|
||||
_unit setvariable ["cse_previous_group_f",_previousGroup];
|
||||
} else {
|
||||
_previousGroup = _unit getvariable "cse_previous_group_f";
|
||||
if (!isnil "_previousGroup") then {
|
||||
_currentGroup = group _unit;
|
||||
_unit setvariable ["cse_previous_group_f",nil];
|
||||
[_unit] joinSilent _previousGroup;
|
||||
if (count units _currentGroup == 0) then {
|
||||
deleteGroup _currentGroup;
|
||||
};
|
||||
};
|
||||
};
|
@ -0,0 +1,22 @@
|
||||
/**
|
||||
* fn_registerUnconsciousCondition.sqf
|
||||
* @Descr: Register new condition for the unconscious state. Conditions are not actively checked for units unless unit is in unconscious state.
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [code CODE]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
|
||||
if (isnil "CSE_UNCONSCIOUS_CONDITIONS_F") then {
|
||||
CSE_UNCONSCIOUS_CONDITIONS_F = [];
|
||||
};
|
||||
if (typeName _this == typeName []) then {
|
||||
{
|
||||
if (typeName _x == typeName {}) then {
|
||||
CSE_UNCONSCIOUS_CONDITIONS_F pushback _x;
|
||||
};
|
||||
}foreach _this;
|
||||
} else {
|
||||
};
|
@ -0,0 +1,38 @@
|
||||
/**
|
||||
* fn_setCaptiveSwitch.sqf
|
||||
* @Descr: Register a unit as captive for the unconscious state
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT, setCaptive BOOL]
|
||||
* @Return: BOOL True if unit is put as set captive, otherwise false
|
||||
* @PublicAPI: false
|
||||
*/
|
||||
|
||||
private ["_unit", "_captiveSwitch", "_setCaptive"];
|
||||
_unit = [_this, 0, objNull, [objNull]] call BIS_fnc_Param;
|
||||
_setCaptive = [_this, 1, false, [false]] call BIS_fnc_Param;
|
||||
|
||||
|
||||
_captiveSwitch = true;
|
||||
if (_setCaptive) then {
|
||||
if (captive _unit) then {
|
||||
_captiveSwitch = false;
|
||||
} else {
|
||||
if (player == _unit) then {
|
||||
missionNamespace setvariable["cse_unconscious_non_captive_f",true];
|
||||
};
|
||||
_unit setCaptive true;
|
||||
[format["USED SETCAPTIVE",_unit]] call cse_fnc_debug;
|
||||
};
|
||||
} else {
|
||||
if (alive _unit) then {
|
||||
_unit setCaptive false;
|
||||
if (!isnil "cse_unconscious_non_captive_f") then {
|
||||
missionNamespace setvariable["cse_unconscious_non_captive_f",nil];
|
||||
};
|
||||
} else {
|
||||
_unit setCaptive false;
|
||||
};
|
||||
};
|
||||
|
||||
_captiveSwitch
|
@ -0,0 +1,95 @@
|
||||
/**
|
||||
* fn_setUnconsciousState.sqf
|
||||
* @Descr: Sets a unit in the unconscious state
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
|
||||
private ["_unit", "_animState", "_dAnim"];
|
||||
_unit = _this select 0;
|
||||
|
||||
_dAnim = ([_unit] call cse_fnc_getDeathAnim);
|
||||
if !([_unit] call cse_fnc_canGoUnconsciousState) exitwith{};
|
||||
if (!local _unit) exitwith {
|
||||
[[_unit], "cse_fnc_setUnconsciousState", _unit, false] spawn BIS_fnc_MP;
|
||||
};
|
||||
|
||||
// get rid of the object we are carrying, before we go unconscious.
|
||||
[_unit, ObjNull, [0,0,0]] call cse_fnc_carryObj;
|
||||
|
||||
_unit setvariable ["cse_state_unconscious",true,true];
|
||||
[_unit] call cse_fnc_setWeaponsCorrectUnconscious;
|
||||
|
||||
_animState = animationState _unit;
|
||||
|
||||
_originalPos = unitPos _unit;
|
||||
if (isPlayer _unit) then {
|
||||
[] call cse_fnc_closeAllDialogs_f;
|
||||
[true] call cse_fnc_effectBlackOut;
|
||||
["unconscious", true] call cse_fnc_disableUserInput_f;
|
||||
[false] call cse_fnc_setVolume_f;
|
||||
|
||||
/* Disable this, because the disableUserInput function call above - users already cannot leave vehicles because of that function. */
|
||||
//[_unit] spawn cse_fnc_lockVehicleOfUnitUntil;
|
||||
} else {
|
||||
_unit setUnitPos "DOWN";
|
||||
[_unit, true] call cse_fnc_disableAI_F;
|
||||
};
|
||||
[_unit, true, "cse_unconsciousState", side group _unit] call cse_fnc_switchToGroupSide_f;
|
||||
|
||||
_captiveSwitch = [_unit, true] call cse_fnc_setCaptiveSwitch;
|
||||
_unit setUnconscious true;
|
||||
[_unit, _dAnim] call cse_fnc_localAnim;
|
||||
|
||||
[_unit,_animState, _captiveSwitch, _originalPos] spawn {
|
||||
private ["_unit", "_vehicleOfUnit","_lockSwitch","_minWaitingTime", "_oldAnimation", "_captiveSwitch"];
|
||||
_unit = _this select 0;
|
||||
_oldAnimation = _this select 1;
|
||||
_captiveSwitch = _this select 2;
|
||||
_originalPos = _this select 3;
|
||||
|
||||
_minWaitingTime = (round(random(10)+5));
|
||||
_counter = time;
|
||||
while {(((time - _counter) < _minWaitingTime) && {alive _unit})} do {
|
||||
if (vehicle _unit == _unit && {animationState _unit != "deadState" && animationState _unit != "unconscious"} && {(alive _unit)} && {(isNull ([_unit] call cse_fnc_getCarriedBy))}) then {
|
||||
[_unit,([_unit] call cse_fnc_getDeathAnim)] call cse_fnc_broadcastAnim;
|
||||
};
|
||||
sleep 0.1;
|
||||
};
|
||||
waituntil{(!([_unit] call cse_fnc_getUnconsciousCondition) || !alive _unit)};
|
||||
[format["setUnconsciousState false - %1",_unit]] call cse_fnc_debug;
|
||||
sleep 0.5;
|
||||
if (_captiveSwitch) then {
|
||||
[_unit, false] call cse_fnc_setCaptiveSwitch;
|
||||
};
|
||||
_unit setUnconscious false;
|
||||
[_unit, false, "cse_unconsciousState", side group _unit] call cse_fnc_switchToGroupSide_f;
|
||||
|
||||
if (isPlayer _unit) then {
|
||||
[false] call cse_fnc_effectBlackOut;
|
||||
[true] call cse_fnc_setVolume_f;
|
||||
["unconscious", false] call cse_fnc_disableUserInput_f;
|
||||
} else {
|
||||
[_unit, false] call cse_fnc_disableAI_F;
|
||||
_unit setUnitPos _originalPos; // This is not position but stance (DOWN, MIDDLE, UP)
|
||||
};
|
||||
|
||||
waituntil {!([_unit] call cse_fnc_beingCarried)};
|
||||
if (alive _unit) then {
|
||||
if (vehicle _unit == _unit) then {
|
||||
[format["Resetting unit animiation to normal %1",_unit]] call cse_fnc_debug;
|
||||
//[_unit,"",false] call cse_fnc_broadcastAnim;
|
||||
[_unit,"amovppnemstpsnonwnondnon",false] call cse_fnc_broadcastAnim;
|
||||
} else {
|
||||
[format["Resetting unit animiation to oldAnimation %1 - %2",_unit, _oldAnimation]] call cse_fnc_debug;
|
||||
[_unit, _oldAnimation,false] call cse_fnc_broadcastAnim;
|
||||
};
|
||||
_unit setvariable ["cse_state_unconscious", false, true];
|
||||
};
|
||||
[[_unit, false],"setUnconsciousState"] call cse_fnc_customEventHandler_F;
|
||||
};
|
||||
[[_unit, true],"setUnconsciousState"] call cse_fnc_customEventHandler_F;
|
@ -0,0 +1,36 @@
|
||||
/**
|
||||
* fn_setWeaponsCorrectUnconscious.sqf
|
||||
* @Descr: Ensures the weapon of a unit is selected correctly for the unconscious state. Prefents wierd animation behaviour
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [unit OBJECT]
|
||||
* @Return: void
|
||||
* @PublicAPI: false
|
||||
*/
|
||||
|
||||
private ["_unit"];
|
||||
_unit = _this select 0;
|
||||
|
||||
if ((vehicle _unit) isKindOf "StaticWeapon") then {
|
||||
moveOut _unit;
|
||||
unassignVehicle _unit;
|
||||
//unassignVehicle _unit;
|
||||
//_unit action ["eject", vehicle _unit];
|
||||
};
|
||||
if (vehicle _unit == _unit) then {
|
||||
if (currentWeapon _unit == secondaryWeapon _unit) then {
|
||||
reload _unit;
|
||||
};
|
||||
};
|
||||
|
||||
if (animationState _unit in ["ladderriflestatic","laddercivilstatic"]) then {
|
||||
_unit action ["ladderOff", (nearestBuilding _unit)];
|
||||
};
|
||||
|
||||
if (vehicle _unit == _unit) then {
|
||||
if (currentWeapon _unit == secondaryWeapon _unit) then {
|
||||
_unit selectWeapon (primaryWeapon _unit);
|
||||
_unit switchMove "";
|
||||
_unit playmoveNow "";
|
||||
};
|
||||
};
|
312
TO_MERGE/cse/f_states/visual/effects.hpp
Normal file
312
TO_MERGE/cse/f_states/visual/effects.hpp
Normal file
@ -0,0 +1,312 @@
|
||||
class RscTitles{
|
||||
class RscCSEScreenEffectsBlack {
|
||||
duration = 10e10;
|
||||
idd = 1111;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSEFadingBlackUI', _this select 0];";
|
||||
|
||||
class controlsBackground {
|
||||
class cse_BlackScreen: cse_gui_backgroundBase {
|
||||
text = "cse\cse_f_states\data\black_out1.paa";
|
||||
colorText[] = {0.0, 0.0, 0.0, 0.0};
|
||||
idc = 11112;
|
||||
x = safezoneX;
|
||||
y = safezoneY;
|
||||
w = safezoneW;
|
||||
h = safezoneH;
|
||||
};
|
||||
};
|
||||
};
|
||||
class RscCSEScreenEffectsPain {
|
||||
duration = 1;
|
||||
idd = 1111;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSEPainScreen', _this select 0];";
|
||||
|
||||
class controlsBackground {
|
||||
class cse_PainScreen: cse_gui_backgroundBase {
|
||||
text = "cse\cse_f_states\data\pain_screen3.paa";
|
||||
colorText[] = {1, 1, 1, 0.5};
|
||||
idc = 11114;
|
||||
x = safezoneX;
|
||||
y = safezoneY;
|
||||
w = safezoneW;
|
||||
h = safezoneH;
|
||||
};
|
||||
};
|
||||
};
|
||||
class RscCSEScreenEffectsBleeding {
|
||||
duration = 1;
|
||||
idd = 1111;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSEBleedingScreen', _this select 0];";
|
||||
|
||||
class controlsBackground {
|
||||
class cse_BleedingScreen: cse_gui_backgroundBase {
|
||||
text = "cse\cse_f_states\data\cse_bleedingScreen_v5.paa";
|
||||
colorText[] = {0.9, 0.2, 0.2, 0.6};
|
||||
idc = 11113;
|
||||
x = safezoneX;
|
||||
y = safezoneY;
|
||||
w = safezoneW;
|
||||
h = safezoneH;
|
||||
};
|
||||
};
|
||||
};
|
||||
class RscCSEScreenEffectsHit{
|
||||
duration = 1.1;
|
||||
idd = 1111;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSEHitScreen', _this select 0];";
|
||||
|
||||
class controlsBackground {
|
||||
class cse_EffectHit: cse_gui_backgroundBase {
|
||||
text = "cse\cse_f_states\data\hit_screen1.paa";
|
||||
colorText[] = {0.7, 0.2, 0.2, 0.4};
|
||||
idc = 11113;
|
||||
x = safezoneX;
|
||||
y = safezoneY;
|
||||
w = safezoneW;
|
||||
h = safezoneH;
|
||||
};
|
||||
};
|
||||
};
|
||||
class RscCSEScreenEffectsHitPain{
|
||||
duration = 1.1;
|
||||
idd = 1111;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSEHitPainScreen', _this select 0];";
|
||||
|
||||
class controlsBackground {
|
||||
class cse_EffectHitNew: cse_gui_backgroundBase {
|
||||
text = "cse\cse_f_states\data\hit_screen1.paa";
|
||||
colorText[] = {0.9, 0.9, 0.9, 0.7};
|
||||
idc = 11113;
|
||||
x = safezoneX;
|
||||
y = safezoneY;
|
||||
w = safezoneW;
|
||||
h = safezoneH;
|
||||
};
|
||||
};
|
||||
};
|
||||
class RscCSEScreenEffectsBlur {
|
||||
duration = 2;
|
||||
idd = 1111;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSEBlurScreen', _this select 0];";
|
||||
|
||||
class controlsBackground {
|
||||
class cse_BlurScreen: cse_gui_backgroundBase {
|
||||
text = "cse\cse_f_states\data\cse_blurryScreen.paa";
|
||||
colorText[] = {0.5, 0.5, 0.5, 0.2};
|
||||
idc = 11114;
|
||||
x = safezoneX;
|
||||
y = safezoneY;
|
||||
w = safezoneW;
|
||||
h = safezoneH;
|
||||
};
|
||||
};
|
||||
};
|
||||
class cse_progressBar_Sample {
|
||||
idd = -1;
|
||||
onLoad = "uiNamespace setVariable ['cse_progressBar_Sample', _this select 0]; ";
|
||||
fadein = 0;
|
||||
fadeout = 0;
|
||||
duration = 10e10;
|
||||
class Controls {
|
||||
|
||||
class background: cse_gui_backgroundBase {
|
||||
idc = -1;
|
||||
colorBackground[] = {0,0,0,1};
|
||||
colorText[] = {1, 1, 1, 1};
|
||||
x = "1 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)";
|
||||
y = "29 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)";
|
||||
w = "38 * (((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
h = "0.4 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
text = "#(argb,8,8,3)color(0,0,0,0.4)";
|
||||
};
|
||||
|
||||
class Progress: cse_gui_RscProgress {
|
||||
idc = 6;
|
||||
x = "1 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)";
|
||||
y = "29 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)";
|
||||
w = "38 * (((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
h = "0.4 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
colorFrame[] = {0,0,0,0};
|
||||
colorBar[] = {0.27,0.5,0.31,0.6};
|
||||
// colorBar[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])", "(profilenamespace getvariable ['GUI_BCG_RGB_A',0.9])"};
|
||||
texture = "#(argb,8,8,3)color(1,1,1,0.7)";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
class CSE_DISPLAY_MESSAGE {
|
||||
duration = 7;
|
||||
idd = 86411;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSE_DISPLAY_MESSAGE', _this select 0];";
|
||||
fadein = 0;
|
||||
class controlsBackground {
|
||||
class header: cse_gui_staticBase {
|
||||
idc = 1;
|
||||
type = CT_STATIC;
|
||||
x = "safezoneX + (safezoneW / 10)";
|
||||
y = "safezoneY + (30 * (safeZoneH / 40))";
|
||||
w = "(safeZoneW / 10)";
|
||||
h = "(safeZoneH / 40)";
|
||||
style = ST_LEFT;
|
||||
font = FontCSE;
|
||||
SizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)";
|
||||
colorText[] = {0.85, 0.85, 0.85, 1.0};
|
||||
colorBackground[] = {0, 0, 0, 0.9};
|
||||
text = "";
|
||||
};
|
||||
class text: header {
|
||||
idc = 2;
|
||||
y = "safezoneY + (31 * (safeZoneH / 40))";
|
||||
w = "(safeZoneW / 10) * 1.3";
|
||||
colorText[] = {0.0, 0.0, 0.0, 1.0};
|
||||
colorBackground[] = {1, 1, 1, 0.9};
|
||||
text = "";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
class CSE_DISPLAY_INFORMATION {
|
||||
duration = 15;
|
||||
idd = 86412;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSE_DISPLAY_INFORMATION', _this select 0];";
|
||||
fadein = 0;
|
||||
class controlsBackground {
|
||||
class header: cse_gui_staticBase {
|
||||
idc = 1;
|
||||
type = CT_STATIC;
|
||||
x = "safezoneX + (safezoneW / 10)";
|
||||
y = "safezoneY + (6 * (safeZoneH / 40))";
|
||||
w = "(safeZoneW / 10)";
|
||||
h = "(safeZoneH / 40)";
|
||||
style = ST_LEFT;
|
||||
font = FontCSE;
|
||||
SizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)";
|
||||
colorText[] = {0.85, 0.85, 0.85, 1.0};
|
||||
colorBackground[] = {0, 0, 0, 0.9};
|
||||
text = "";
|
||||
};
|
||||
class text: header {
|
||||
idc = 2;
|
||||
y = "safezoneY + (7.1 * (safeZoneH / 40))";
|
||||
w = "(safeZoneW / 10) * 1.3";
|
||||
colorText[] = {0.0, 0.0, 0.0, 1.0};
|
||||
colorBackground[] = {1, 1, 1, 0.9};
|
||||
text = "";
|
||||
};
|
||||
class text2: text {
|
||||
idc = 3;
|
||||
y = "safezoneY + (8.2 * (safeZoneH / 40))";
|
||||
};
|
||||
class text3: text {
|
||||
idc = 4;
|
||||
y = "safezoneY + (9.3 * (safeZoneH / 40))";
|
||||
};
|
||||
class text4: text {
|
||||
idc = 5;
|
||||
y = "safezoneY + (10.4 * (safeZoneH / 40))";
|
||||
};
|
||||
class text5: text {
|
||||
idc = 6;
|
||||
y = "safezoneY + (11.5 * (safeZoneH / 40))";
|
||||
};
|
||||
|
||||
|
||||
class icon: cse_gui_backgroundBase {
|
||||
type = CT_STATIC;
|
||||
idc = 10;
|
||||
style = ST_PICTURE;
|
||||
colorBackground[] = {0,0,0,1};
|
||||
colorText[] = {1, 1, 1, 1};
|
||||
font = FontCSE;
|
||||
text = "";
|
||||
sizeEx = 0.032;
|
||||
x = "safezoneX + (safezoneW / 10)";
|
||||
y = "safezoneY + (4 * (safeZoneH / 40))";
|
||||
w = "(safeZoneH / 40)*2";
|
||||
h = "(safeZoneH / 40)*2";
|
||||
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
class CSE_DISPLAY_MESSAGE_CONCEPT {
|
||||
duration = 15;
|
||||
idd = 86413;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSE_DISPLAY_MESSAGE_CONCEPT', _this select 0];";
|
||||
fadein = 0;
|
||||
class controlsBackground {
|
||||
class header: cse_gui_staticBase {
|
||||
idc = 1;
|
||||
type = CT_STATIC;
|
||||
x = "safezoneX + (safezoneW / 10)";
|
||||
y = "safezoneY + (6 * (safeZoneH / 40))";
|
||||
w = "(safeZoneW / 10)";
|
||||
h = "(safeZoneH / 40)";
|
||||
style = ST_LEFT + ST_SHADOW;
|
||||
font = "EtelkaMonospacePro";
|
||||
SizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)";
|
||||
colorText[] = {1,1,1, 1.0};
|
||||
colorBackground[] = {0, 0, 0, 0.0};
|
||||
text = "";
|
||||
shadow = 2;
|
||||
};
|
||||
class text: header {
|
||||
idc = 2;
|
||||
y = "safezoneY + (31 * (safeZoneH / 40))";
|
||||
w = "(safeZoneW / 10) * 1.3";
|
||||
text = "";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
class CSE_sys_field_rations_PlayerStatusUI {
|
||||
duration = 1e+011;
|
||||
idd = 1111;
|
||||
movingenable = 0;
|
||||
onLoad = "uiNamespace setVariable ['CSE_sys_field_rations_PlayerStatusUI', _this select 0];";
|
||||
class controlsBackground {
|
||||
class FoodStatus: cse_gui_backgroundBase {
|
||||
text = "cse\cse_sys_field_rations\data\hud_foodstatus.paa";
|
||||
colorText[] = {0.0,1.0,0.0,0.4};
|
||||
idc = 11112;
|
||||
x = (safezoneW + safezoneX) - (2 * (((safezoneW / safezoneH) min 1.2) / 40));
|
||||
y = "28 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)";
|
||||
w = "1.75 * (((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
h = "1.75 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
};
|
||||
class drinkStatus: cse_gui_backgroundBase {
|
||||
text = "cse\cse_sys_field_rations\data\hud_drinkstatus.paa";
|
||||
colorText[] = {0.0,1.0,0.0,0.4};
|
||||
idc = 11113;
|
||||
x = (safezoneW + safezoneX) - (2 * (((safezoneW / safezoneH) min 1.2) / 40));
|
||||
y = "30 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)";
|
||||
w = "1.75 * (((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
h = "1.75 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
};
|
||||
/* class CamelBak: cse_gui_backgroundBase {
|
||||
text = "cse\cse_sys_field_rations\data\hud_camelbak.paa";
|
||||
colorText[] = {0.0,1.0,0.0,0};
|
||||
idc = 11114;
|
||||
x = "0.955313 * safezoneW + safezoneX";
|
||||
y = "0.80 * safezoneH + safezoneY";
|
||||
w = 0.05;
|
||||
h = 0.09;
|
||||
};*/
|
||||
};
|
||||
};
|
||||
|
||||
// class RscHealthTextures {
|
||||
// onload = "uinamespace setvariable ['RscHealthTextures',_this select 0]; ['RscHealthTextures has activated'] call cse_fnc_debug;";
|
||||
// };
|
||||
};
|
21
TO_MERGE/cse/f_states/visual/empty.hpp
Normal file
21
TO_MERGE/cse/f_states/visual/empty.hpp
Normal file
@ -0,0 +1,21 @@
|
||||
class cse_empty_screen {
|
||||
idd = 679123;
|
||||
movingEnable = false;
|
||||
onLoad = "uiNamespace setVariable ['cse_empty_screen', _this select 0];";
|
||||
onUnload = "if (!isnil 'CSE_DISABLE_USER_INPUT_SCREEN') then { createDialog 'cse_empty_screen';};";
|
||||
class controlsBackground {
|
||||
class cse_background : cse_gui_backgroundBase {
|
||||
idc = 1;
|
||||
x = safezoneX;
|
||||
y = safezoneY;
|
||||
w = safezoneW;
|
||||
h = safezoneH;
|
||||
text = "";
|
||||
moving = 0;
|
||||
};
|
||||
};
|
||||
|
||||
class controls {
|
||||
|
||||
};
|
||||
};
|
19
TO_MERGE/cse/f_states/visual/functions/fn_effectBlackOut.sqf
Normal file
19
TO_MERGE/cse/f_states/visual/functions/fn_effectBlackOut.sqf
Normal file
@ -0,0 +1,19 @@
|
||||
/**
|
||||
* fn_effectBlackOut.sqf
|
||||
* @Descr: Displays the blacked out effect for clients.
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [displayEffect BOOL]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_displayEffect","_CSEFadingBlackUI"];
|
||||
_displayEffect = [_this, 0, false,[false]] call bis_fnc_param;
|
||||
disableSerialization;
|
||||
_CSEFadingBlackUI = uiNamespace getVariable "CSEFadingBlackUI";
|
||||
if (_displayEffect) then {
|
||||
(_CSEFadingBlackUI displayCtrl 11112) ctrlSetTextColor [0.0,0.0,0.0,0.9];
|
||||
} else {
|
||||
(_CSEFadingBlackUI displayCtrl 11112) ctrlSetTextColor [0.0,0.0,0.0,0.0];
|
||||
};
|
30
TO_MERGE/cse/f_states/visual/functions/fn_effectBleeding.sqf
Normal file
30
TO_MERGE/cse/f_states/visual/functions/fn_effectBleeding.sqf
Normal file
@ -0,0 +1,30 @@
|
||||
/**
|
||||
* fn_effectBleeding.sqf
|
||||
* @Descr: Displays the CSE Bleeding effect
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [bloodLoss NUMBER]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
private ["_handle"];
|
||||
if (isnil "cseDisplayingBleedingEffect") then {
|
||||
cseDisplayingBleedingEffect = false;
|
||||
};
|
||||
if (cseDisplayingBleedingEffect) exitwith {};
|
||||
_handle = _this spawn {
|
||||
private ["_unit","_bloodLoss","_time"];
|
||||
_bloodLoss = _this select 0;
|
||||
if (!(_bloodLoss > 0)) exitwith{};
|
||||
_time = 6 - _bloodLoss;
|
||||
if (_time <1.5) then {
|
||||
_time = 1.5;
|
||||
};
|
||||
cseDisplayingBleedingEffect = true;
|
||||
47 cutRsc ["RscCSEScreenEffectsBleeding","PLAIN"];
|
||||
sleep _time;
|
||||
cseDisplayingBleedingEffect = false;
|
||||
};
|
||||
|
||||
_handle
|
27
TO_MERGE/cse/f_states/visual/functions/fn_effectPain.sqf
Normal file
27
TO_MERGE/cse/f_states/visual/functions/fn_effectPain.sqf
Normal file
@ -0,0 +1,27 @@
|
||||
/**
|
||||
* fn_effectPain.sqf
|
||||
* @Descr: Displays the CSE Pain effect
|
||||
* @Author: Glowbal
|
||||
*
|
||||
* @Arguments: [painRatio NUMBER]
|
||||
* @Return: void
|
||||
* @PublicAPI: true
|
||||
*/
|
||||
|
||||
if (isnil "cseDisplayingPainEffect") then {
|
||||
cseDisplayingPainEffect = false;
|
||||
};
|
||||
if (cseDisplayingPainEffect) exitwith {};
|
||||
_this spawn {
|
||||
private ["_ratio","_time"];
|
||||
_ratio = _this select 0;
|
||||
if (!(_ratio > 0)) exitwith{};
|
||||
_time = 6 - _ratio;
|
||||
if (_time <1.5) then {
|
||||
_time = 1.5;
|
||||
};
|
||||
cseDisplayingPainEffect = true;
|
||||
46 cutRsc ["RscCSEScreenEffectsPain","PLAIN"];
|
||||
sleep _time;
|
||||
cseDisplayingPainEffect = false;
|
||||
};
|
Loading…
Reference in New Issue
Block a user