Jump to content

Manually trigger EpochEvents


Guest

Recommended Posts

Hi guys,

 

is there a way to manually trigger EpochEvents for debugging?

Editing, recompiling, uploading, server restarting, login, downloading mpmission.pbo, waiting for event ... is killing my nerves.  <_<

 

Thanks

Link to comment
Share on other sites

I'm guessing this is the section we would be using. When I get home later I will test and let you guys know my results.

SQS example:

_genAct = generator addAction ["Switch on generator", "activate_generator.sqs"]

activate_generator.sqs:

_gen = _this select 0

_caller = _this select 1

_id = _this select 2

; remove the action once it is activated

_gen removeAction _id

This example shows an action called "Switch on generator" added to an object with the name 'generator'. As soon as the player gets close to this object, he can execute the given action via the action menu. Then the script 'activate_generator.sqs' is executed, which in our example only removes the action from the generator.

Link to comment
Share on other sites

I tried adding this to the end of my fn_selfactions: 

//Admin events
if ((getPlayerUID player) in ["123456789"]) then { 
if (goldrun < 0) then {
		goldrun = player addaction[("<t color=""#FDB813"">" + ("Gold Run") +"</t>"),"gold_run.sqf",_cursorTarget, 0, false, true, "", ""];
};
if (lootevent < 0) then {
		lootevent = player addaction[("<t color=""#39B0FF"">" + ("Loot event") +"</t>"),"loot_event.sqf",_cursorTarget, 0, false, true, "", ""];
};
} else {
    player removeAction goldrun;
    goldrun = -1;
	player removeAction lootevent;
    lootevent = -1;
};

Didn't work tough, how do i get it to work? (btw i changed the UID here, had my own in it).

Link to comment
Share on other sites

I tried creating a file called adminevent.sqf and adding the following (UID replaced with fake one):

waituntil {!alive player ; !isnull (finddisplay 46)};
if ((getPlayerUID player) in ["123456789"]) then {
	sleep 10;
	player addaction[("<t color=""#FDB813"">" + ("Gold Run") +"</t>"),"gold_run.sqf",_cursorTarget, 0, false, true, "", ""];
	player addaction[("<t color=""#39B0FF"">" + ("Loot event") +"</t>"),"loot_event.sqf",_cursorTarget, 0, false, true, "", ""];
};

And adding this to the init.sqf on the bottom of the file:

//Admin events
[]execVM "scripts\adminmenu\adminevent.sqf"

Not working either, menu doesn't show up.

 

Am i looking in the right direction here?

Link to comment
Share on other sites

i use this :

 

in mission i create a folder named "eventi"

 

and put 3 event in it (giallo.spf , blu,sqf, rosso,sqf)

 

then i use a fn_selfaction and put inside 

//Trigger event KARENA
    
_karena = items player;

    if ("Cobalt_File" in _karena) then {
        hasBagItem = true;
    } else { hasBagItem = false;};
    if((speed player <= 1) && hasBagItem && _canDo) then {
        if (evento < 0) then {
            evento = player addaction[("<t color=""#ffff15"">" + ("Evento Giallo") +"</t>"),"eventi\giallo.sqf","",-10,false,true,"", ""];
            evento1 = player addaction[("<t color=""#1515ff"">" + ("Evento Blu") +"</t>"),"eventi\blu.sqf","",-10,false,true,"", ""];
            evento2 = player addaction[("<t color=""#ff1515"">" + ("Evento Rosso") +"</t>"),"eventi\rosso.sqf","",-10,false,true,"", ""];
            };
    } else {
        player removeAction evento;
        evento = -1;
        player removeAction evento1;
        evento1 = -1;
        player removeAction evento2;
        evento2 = -1;
    };
//fine trigger event KARENA

immediately after the _canDo

 

u can put this after the selfblod

 

now u MUST have a special item in inventory " Cobalt_File " 

Link to comment
Share on other sites

cobalt_file is itemtool NON in loot tablet for now, u can put cobalt_file in your inventory whit the special loadout or whit manual add in db or can spawn it whit some admin tool.

 

if u not like it ... u can change it :D

 

 

if cobalt file is in player hand ... the playe can start the Event.

Link to comment
Share on other sites

hi, any idea how i fix battleye kicks if i manually trigger an event??

 

got kicked for createvehicle (ammobox) and publicvariableval stuff

 

 

your best bet is to shuffle through the BE filters searching for the exact reasons you were kicked.

not sure which host you are using or if you are using a personal machine but its all about the same.  

Link to comment
Share on other sites

  • 4 months later...
  • 5 months later...
  • 2 weeks later...
  • 4 months later...
  • 1 month later...
  • 1 month later...

Hey guys, I'm using nox's admin tools so just added the following line/ put the Heli crash spawner file in the right place, and it works in a sense, but all heli's start and crash in the exact same place, anybody got any ideas why/ how to fix?

 

my line:

 

["Spawn Helicopter Crash",[],"", -5,[["expression",format[_EXECscript1,"spawncrash.sqf"]]],"1","1"],
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...