mirror of
https://github.com/Fallingsheep1985/Arma3Epoch.git
synced 2024-08-30 16:42:12 +00:00
SEM missions system + VEMF fix
This commit is contained in:
parent
12859945de
commit
fa83b04381
BIN
@epochhive/addons/sem.pbo
Normal file
BIN
@epochhive/addons/sem.pbo
Normal file
Binary file not shown.
Binary file not shown.
149
MPMissions/epoch.Altis/VEMFConfig.sqf
Normal file
149
MPMissions/epoch.Altis/VEMFConfig.sqf
Normal file
@ -0,0 +1,149 @@
|
||||
/*
|
||||
Vampire's Epoch Mission Framework Config by Vampire
|
||||
|
||||
If you paid for this script, they are breaking the license terms.
|
||||
If you paid to have this installed, I suggest you get a refund.
|
||||
|
||||
VEMF: https://github.com/SMVampire/VEMF
|
||||
*/
|
||||
|
||||
///////////////////////////////////////////////////////////////////
|
||||
/* Mission Config */
|
||||
///////////////////////////////////////////////////////////////////
|
||||
// VEMF Debug Settings:
|
||||
// Creates a lot of RPT Entries, turn off after debugging
|
||||
VEMFDebugLocs = false;
|
||||
VEMFDebugAI = false;
|
||||
VEMFDebugFunc = false;
|
||||
|
||||
// AI Group Count per City
|
||||
// Default is 3 Groups
|
||||
VEMFGroupCnt = 3;
|
||||
|
||||
// Punish Players who Run Over AI?
|
||||
// Causes 10% Vehicle Damage per AI Runover
|
||||
VEMFPunishRunover = true;
|
||||
|
||||
// Dynamic Crate Loot?
|
||||
// Blacklist Still Applies
|
||||
VEMFDynCrate = true;
|
||||
|
||||
// Crate Loot List
|
||||
// (DynCrate must be off)
|
||||
VEMFLootList = [
|
||||
""
|
||||
];
|
||||
|
||||
// Blacklist Crate Loot
|
||||
VEMFCrateBlacklist = [
|
||||
"DemoCharge_Remote_Mag", "SatchelCharge_Remote_Mag", "ATMine_Range_Mag",
|
||||
"ClaymoreDirectionalMine_Remote_Mag", "APERSMine_Range_Mag",
|
||||
"APERSBoundingMine_Range_Mag", "SLAMDirectionalMine_Wire_Mag",
|
||||
"APERSTripMine_Wire_Mag"
|
||||
];
|
||||
|
||||
// Min & Max Mission Times (Will Be Made Better)
|
||||
// Time is in Minutes
|
||||
// Min Must Be Less Than Max
|
||||
VEMFMinMissTime = 5;
|
||||
VEMFMaxMissTime = 20;
|
||||
|
||||
// Timeout (No Players Near)
|
||||
// Time in minutes
|
||||
VEMFTimeoutTime = 20;
|
||||
|
||||
// Enable Timeout?
|
||||
// In false waits forever
|
||||
VEMFTimeout = true;
|
||||
|
||||
// Announce to Last Killer or to Near Players?
|
||||
// Distance in Meters. 0 for Last Killer option.
|
||||
VEMFMissEndAnn = 0;
|
||||
|
||||
// Mission Name Array
|
||||
VEMFMissionArray = ["DynamicTownInvasion"];
|
||||
|
||||
// Custom Addon Array (Don't Touch Unless You're Positive)
|
||||
// What is your addon script name?
|
||||
// Example: Caves.sqf
|
||||
VEMFAddon = [""];
|
||||
|
||||
// Blacklist Zone Array -- missions will not spawn in these areas
|
||||
// format: [[x,y,z],radius]
|
||||
// Ex: [[06325,07807,0],300] //Starry Sobor
|
||||
VEMFBlacklistZones = [
|
||||
[[0,0,0],50]
|
||||
];
|
||||
|
||||
///////////////////////////////////////////////////////////////////
|
||||
/* AI Config */
|
||||
///////////////////////////////////////////////////////////////////
|
||||
|
||||
// Generate Dynamic Weapon List?
|
||||
// If True WeaponLists Below Ignored
|
||||
// Recommended to Use With Blacklist
|
||||
VEMFDynWeapons = true;
|
||||
|
||||
// Required Kill Percentage
|
||||
// Example 0.80 (80%)
|
||||
VEMFRequiredKillPercent = 1.0;
|
||||
|
||||
// Blacklisted Weapons
|
||||
VEMFWepBlack = [
|
||||
"ChainSaw",
|
||||
"Hatchet",
|
||||
"speargun_epoch",
|
||||
"MultiGun",
|
||||
"m107Tan_EPOCH",
|
||||
"m107_EPOCH",
|
||||
"srifle_GM6_F",
|
||||
"srifle_LRR_F"
|
||||
];
|
||||
|
||||
// AI Headgear Array
|
||||
// 39-70, 74-92, Festives
|
||||
VEMFHeadgearList = [
|
||||
"H_39_EPOCH","H_40_EPOCH","H_41_EPOCH","H_42_EPOCH","H_43_EPOCH","H_44_EPOCH","H_45_EPOCH","H_46_EPOCH","H_47_EPOCH","H_48_EPOCH",
|
||||
"H_49_EPOCH","H_50_EPOCH","H_51_EPOCH","H_52_EPOCH","H_53_EPOCH","H_54_EPOCH","H_55_EPOCH","H_56_EPOCH","H_57_EPOCH","H_58_EPOCH",
|
||||
"H_59_EPOCH","H_60_EPOCH","H_61_EPOCH","H_62_EPOCH","H_63_EPOCH","H_64_EPOCH","H_65_EPOCH","H_66_EPOCH","H_67_EPOCH","H_68_EPOCH",
|
||||
"H_69_EPOCH","H_70_EPOCH","H_74_EPOCH","H_75_EPOCH","H_76_EPOCH","H_77_EPOCH","H_78_EPOCH","H_79_EPOCH","H_80_EPOCH","H_81_EPOCH",
|
||||
"H_82_EPOCH","H_83_EPOCH","H_84_EPOCH","H_85_EPOCH","H_86_EPOCH","H_87_EPOCH","H_88_EPOCH","H_89_EPOCH","H_90_EPOCH","H_91_EPOCH",
|
||||
"H_92_EPOCH",
|
||||
"wolf_mask_epoch","pkin_mask_epoch"
|
||||
];
|
||||
|
||||
// AI Uniform Array
|
||||
VEMFUniformList = [
|
||||
"U_O_CombatUniform_ocamo", "U_O_PilotCoveralls", "U_OG_Guerilla1_1", "U_OG_Guerilla2_1", "U_OG_Guerilla2_3",
|
||||
"U_OG_Guerilla3_1", "U_OG_Guerilla3_2", "U_OG_leader", "U_C_Poloshirt_stripped", "U_C_Poloshirt_blue", "U_C_Poloshirt_burgundy",
|
||||
"U_C_Poloshirt_tricolour", "U_C_Poloshirt_salmon", "U_C_Poloshirt_redwhite", "U_C_Poor_1", "U_C_WorkerCoveralls", "U_C_Journalist",
|
||||
"U_OrestesBody", "U_CamoRed_uniform", "U_CamoBrn_uniform", "U_CamoBlue_uniform", "U_Camo_uniform", "U_C_Driver_3", "U_C_Driver_4"
|
||||
];
|
||||
|
||||
// AI Vest Array
|
||||
VEMFVestList = [
|
||||
"V_1_EPOCH","V_2_EPOCH","V_3_EPOCH","V_4_EPOCH","V_5_EPOCH","V_6_EPOCH","V_7_EPOCH","V_8_EPOCH","V_9_EPOCH","V_10_EPOCH",
|
||||
"V_11_EPOCH","V_12_EPOCH","V_13_EPOCH","V_14_EPOCH","V_15_EPOCH","V_16_EPOCH","V_17_EPOCH","V_18_EPOCH","V_19_EPOCH","V_20_EPOCH",
|
||||
"V_21_EPOCH","V_22_EPOCH","V_23_EPOCH","V_24_EPOCH","V_25_EPOCH","V_26_EPOCH","V_27_EPOCH","V_28_EPOCH","V_29_EPOCH","V_30_EPOCH",
|
||||
"V_31_EPOCH","V_32_EPOCH","V_33_EPOCH","V_34_EPOCH","V_35_EPOCH","V_36_EPOCH","V_37_EPOCH","V_38_EPOCH","V_39_EPOCH","V_40_EPOCH"
|
||||
];
|
||||
|
||||
// AI Rifle Array
|
||||
VEMFRiflesList = [
|
||||
"srifle_EBR_F","srifle_DMR_01_F","arifle_Katiba_F","arifle_Katiba_C_F","arifle_Katiba_GL_F","arifle_MXC_F","arifle_MX_F",
|
||||
"arifle_MX_GL_F","arifle_MXM_F","arifle_SDAR_F","arifle_TRG21_F","arifle_TRG20_F","arifle_TRG21_GL_F","arifle_Mk20_F",
|
||||
"arifle_Mk20C_F","arifle_Mk20_GL_F","arifle_Mk20_plain_F","arifle_Mk20C_plain_F","arifle_Mk20_GL_plain_F","SMG_01_F",
|
||||
"SMG_02_F","hgun_PDW2000_F","arifle_MXM_Black_F","arifle_MX_GL_Black_F","arifle_MX_Black_F","arifle_MXC_Black_F","Rollins_F",
|
||||
"LMG_Mk200_F","arifle_MX_SW_F","LMG_Zafir_F","arifle_MX_SW_Black_F","m249_EPOCH","m249Tan_EPOCH",
|
||||
"m16_EPOCH","m16Red_EPOCH","M14_EPOCH","M14Grn_EPOCH","m4a3_EPOCH","AKM_EPOCH"
|
||||
];
|
||||
|
||||
// AI Pistol Array
|
||||
VEMFPistolsList = [
|
||||
"hgun_ACPC2_F","hgun_Rook40_F","hgun_P07_F","hgun_Pistol_heavy_01_F","hgun_Pistol_heavy_02_F","ruger_pistol_epoch",
|
||||
"1911_pistol_epoch","hgun_Pistol_Signal_F"
|
||||
];
|
||||
|
||||
/* ======== Do Not Modify Below ======== */
|
||||
diag_log text format ["[VEMF]: Configuration File Loaded!"];
|
||||
VEMFVersion = "1.0.0c-PreAlpha";
|
@ -1,19 +1,6 @@
|
||||
//Admin list
|
||||
ADMIN_LIST = ["76561198087015545","0","0"]
|
||||
//VEMF Missions
|
||||
if (!isDedicated) then {
|
||||
"VEMFChatMsg" addPublicVariableEventHandler {
|
||||
systemChat ((_this select 1) select 0);
|
||||
[
|
||||
[
|
||||
[((_this select 1) select 0),"align = 'center' size = '1' font='PuristaBold'"],
|
||||
["","<br/>"],
|
||||
[((_this select 1) select 1),"align = 'center' size = '0.5'"]
|
||||
]
|
||||
] spawn BIS_fnc_typeText2;
|
||||
VEMFChatMsg = nil;
|
||||
};
|
||||
};
|
||||
ADMIN_LIST = ["76561198087015545","0","0"];
|
||||
|
||||
|
||||
//Status Bar
|
||||
[] execVM "custom\fn_statusBar.sqf";
|
||||
@ -50,4 +37,21 @@ _target = cursorTarget;
|
||||
_isbike = _target isKindOf "ebike_epoch";
|
||||
if (_isbike) then{
|
||||
player addaction [("<t color=""#0074E8"">" + ("PackBike") +"</t>"),"custom\packbike2.sqf","",5,false,true,"",""];
|
||||
};
|
||||
//SEM Missions
|
||||
if(hasInterface)then{execVM "semClient.sqf"};
|
||||
|
||||
//VEMF Missions
|
||||
if (!isDedicated) then {
|
||||
"VEMFChatMsg" addPublicVariableEventHandler {
|
||||
systemChat ((_this select 1) select 0);
|
||||
[
|
||||
[
|
||||
[((_this select 1) select 0),"align = 'center' size = '1' font='PuristaBold'"],
|
||||
["","<br/>"],
|
||||
[((_this select 1) select 1),"align = 'center' size = '0.5'"]
|
||||
]
|
||||
] spawn BIS_fnc_typeText2;
|
||||
VEMFChatMsg = nil;
|
||||
};
|
||||
};
|
129
MPMissions/epoch.Altis/semClient.sqf
Normal file
129
MPMissions/epoch.Altis/semClient.sqf
Normal file
@ -0,0 +1,129 @@
|
||||
/* KiloSwiss */
|
||||
if(isDedicated)exitWith{}; //Everything below this line is only executed on the client (player or local host)
|
||||
|
||||
[] spawn { waitUntil{player == player && !isNil "SEM_version"}; sleep 50;
|
||||
/* This is the advertisement. */
|
||||
private "_worldName";
|
||||
_worldName = switch(toLower worldName)do{
|
||||
case "bootcamp_acr" :{"Bukovina"};
|
||||
case "woodland_acr" :{"Bystrica"};
|
||||
case "chernarus_summer" :{"Chernarus (summer)"};
|
||||
case "mbg_celle2" :{"Celle"};
|
||||
case "isladuala" :{"Isla-Duala"};
|
||||
case "panthera2" :{"Panthera"};
|
||||
case "panthera3" :{"Panthera"};
|
||||
case "smd_sahrani_a2" :{"Sahrani"};
|
||||
case "sara" :{"Sahrani"};
|
||||
case "saralite" :{"Sahrani"};
|
||||
case "sara_dbe1" :{"Sahrani"};
|
||||
case "tavi" :{"Taviana"};
|
||||
default{worldName};
|
||||
};
|
||||
titleText [format["\nWelcome to EPOCH %1 survivor %2.", _worldName, name player], "PLAIN DOWN", 2];
|
||||
sleep 15;
|
||||
titleText [format["This server is running %1 v%2", str "Simple Epoch Missions", SEM_version], "PLAIN DOWN", 2];
|
||||
/* End of advertisement */
|
||||
"SEM_version" addPublicVariableEventHandler {titleText [format["This server is running %1 v%2", str "Simple Epoch Missions", _this select 1], "PLAIN DOWN"]};
|
||||
};
|
||||
|
||||
|
||||
SEM_client_createMissionMarker = { private ["_create","_markerTimeout","_markerPos","_markerID","_markerA","_markerB","_markerC","_markerC_Pos","_markerName"];
|
||||
_create = _this select 0;
|
||||
|
||||
//Create Marker
|
||||
if(_create)then[{
|
||||
|
||||
_markerPos = _this select 1;
|
||||
_markerID = _this select 2;
|
||||
_markerName = _this select 3;
|
||||
|
||||
_markerA = createMarkerLocal [format["SEM_MissionMarkerA_%1", _markerID], _markerPos];
|
||||
_markerB = createMarkerLocal [format["SEM_MissionMarkerB_%1", _markerID], _markerPos];
|
||||
_markerC = createMarkerLocal [format["SEM_MissionMarkerC_%1", _markerID], _markerPos];
|
||||
|
||||
{ _x setMarkerShapeLocal "ELLIPSE"; _x setMarkerSizeLocal [350,350];
|
||||
_x setMarkerPosLocal _markerPos}forEach [_markerA,_markerB];
|
||||
|
||||
_markerA setMarkerBrushLocal "Cross";
|
||||
_markerA setMarkerColorLocal "ColorYellow";
|
||||
|
||||
_markerB setMarkerBrushLocal "Border";
|
||||
_markerB setMarkerColorLocal "ColorRed";
|
||||
|
||||
_markerC_Pos = [(_markerPos select 0) - (count _markerName * 12), (_markerPos select 1) - 370, 0];
|
||||
_markerC setMarkerShapeLocal "Icon";
|
||||
_markerC setMarkerTypeLocal "HD_Arrow";
|
||||
_markerC setMarkerColorLocal "ColorRed";
|
||||
_markerC setMarkerPosLocal _markerC_Pos;
|
||||
_markerC setMarkerTextLocal _markerName;
|
||||
_markerC setMarkerDirLocal 37;
|
||||
|
||||
},{ //else delete marker
|
||||
|
||||
_this spawn { private ["_markerTimeout","_markerID"];
|
||||
_markerTimeout = _this select 1;
|
||||
_markerID = _this select 2;
|
||||
|
||||
if(_markerTimeout > 0)then{
|
||||
format["SEM_MissionMarkerB_%1", _markerID] setMarkerColorLocal "ColorGreen";
|
||||
format["SEM_MissionMarkerC_%1", _markerID] setMarkerColorLocal "ColorGreen";
|
||||
sleep _markerTimeout;
|
||||
};
|
||||
|
||||
if (getMarkerColor format["SEM_MissionMarkerA_%1", _markerID] != "")then{ //Only delete existing Marker
|
||||
deleteMarkerLocal format["SEM_MissionMarkerA_%1", _markerID];
|
||||
deleteMarkerLocal format["SEM_MissionMarkerB_%1", _markerID];
|
||||
deleteMarkerLocal format["SEM_MissionMarkerC_%1", _markerID];
|
||||
};
|
||||
};
|
||||
}];
|
||||
};
|
||||
|
||||
if(!isNil "SEM_globalMissionMarker")then{SEM_globalMissionMarker call SEM_client_createMissionMarker};
|
||||
"SEM_globalMissionMarker" addPublicVariableEventHandler {_this select 1 call SEM_client_createMissionMarker};
|
||||
|
||||
SEM_lastEvent = 0;
|
||||
"SEM_globalHint" addPublicVariableEventHandler {
|
||||
_this select 1 spawn { private "_sound";
|
||||
//waitUntil{time - SEM_lastEvent > 20}; SEM_lastEvent = time;
|
||||
waitUntil{if(time - SEM_lastEvent > 20)exitwith{SEM_lastEvent = time; true}; false};
|
||||
_sound = _this select 0;
|
||||
switch(_sound)do{
|
||||
case 0:{playSound "UAV_05"}; //Mission start
|
||||
case 1:{playSound "UAV_01"}; //Mission fail (object destroyed)
|
||||
case 2:{playSound "UAV_04"}; //Mission fail (time out)
|
||||
case 3:{playsound "UAV_03"}; //Mission success
|
||||
};
|
||||
hint parseText format["%1", _this select 1];
|
||||
};
|
||||
};
|
||||
|
||||
"SEM_vehDamage" addPublicVariableEventHandler { private ["_vk","_vP","_s"];
|
||||
_vk = _this select 1;
|
||||
_vP = vehicle player;
|
||||
if(!local _vk)exitWith{};
|
||||
if(_vk != _vP)exitWith{};
|
||||
_s = [ "MOTOR","karoserie","palivo","glass1","glass2","glass3","door1","door2","door3","door4",
|
||||
"wheel_1_1_steering","wheel_2_1_steering","wheel_1_2_steering","wheel_2_2_steering",
|
||||
"wheel_1_3_steering","wheel_2_3_steering","wheel_1_4_steering","wheel_2_4_steering"];
|
||||
{_vk setHit [_x,(_vk getHit _x)+(.2+(random .15))]}count _s;
|
||||
};
|
||||
|
||||
|
||||
[] spawn {
|
||||
waitUntil{!isNil "SEM_AIsniperDamageDistance"};
|
||||
waitUntil{!isNil "SEM_AI_Units"};
|
||||
|
||||
while{true}do{ private "_units";
|
||||
_units = SEM_AI_Units;
|
||||
{ sleep 0.05;
|
||||
if(_x distance (vehicle player) > SEM_AIsniperDamageDistance)then[{
|
||||
if(!isPlayer _x)then{_x allowDamage false};
|
||||
},{
|
||||
if(!isPlayer _x)then{_x allowDamage true};
|
||||
}];
|
||||
}forEach _units;
|
||||
};
|
||||
};
|
||||
//if(!isNil "SEM_AIsniperDamageEH")then{SEM_AI_Units call SEM_client_AIaddDamageEH};
|
||||
//"SEM_AI_Units" addPublicVariableEventHandler {_this select 1 call SEM_client_AIaddDamageEH};
|
Loading…
Reference in New Issue
Block a user