Short Cords Admin tool, Error in initadmin.sqf, Help?

likeablas

New Member
Edit:
Sadly, Short cords menu is broken, The menu doesn't generate even though text appears saying f = tele, F5 = spawn vehicle, and hijack vehicle. Posting purplishs code here (And me putting the message.) if anyone wants to fix the entire menu.
Code:
waituntil {!alive player ; !isnull (finddisplay 46)};
sleep 30;
if ((getPlayerUID player) in ["10355529","14195657"]) then {
    player addaction [("<t color=""#ff0000"">" + ("Admin Menu") +"</t>"),"admintools\start.sqf"];
    sleep 5;
    hint parseText "<t size='2.5' color='#00FF00'>Welcome SWNN Admin! Use Scroll Wheel and click Admin menu to access your tools!</t>";
};
 
//Purplish Edited Initadmin.sqf with scroll menu as the toggle! Also tools points to the mission folder.

Old Post, Error has been fixed. Thank you purplish :) :

Hey can someone help me with this? The way you trigger the admin menu in the free blur gaming antihack script wasn't working, so i used the alternative, but when i use initadmin.sqf, i get this error:
Code:
 0:59:29 File mpmissions\DayZ_Epoch_11.Chernarus\initadmin.sqf, line 4
0:59:29 Error in expression <359497"]) then {
displayAddEventHandler ["KeyUp", "if ((_this select 1) == 0xD3)>
0:59:29 Error position: <["KeyUp", "if ((_this select 1) == 0xD3)>
0:59:29 Error Missing ;

This is my initadmin.sqf:
Code:
waituntil {!alive player ; !isnull (finddisplay 46)};
sleep 30;
if ((getPlayerUID player) in ["*censored*"]) then {
displayAddEventHandler ["KeyUp", "if ((_this select 1) == 0xD3) then {call compile preprocessFileLineNumbers ""\z\addons\dayz_server\tools\start.sqf"";};"]
sleep 5;
hint parseText "<t size='2.5' color='#00FF00'>Press "Delete" to Open your Admin menu</t>";
};
 
//0xD3 is "Delete" above the arrow keys

Can someone help me fix the error? Thanks ;)
 
waituntil {!alive player ; !isnull (finddisplay 46)};
sleep 30;
if ((getPlayerUID player) in ["*censored*"]) then {
displayAddEventHandler ["KeyUp", "if ((_this select 1) == 0xD3) then {call compile preprocessFileLineNumbers ""\z\addons\dayz_server\tools\start.sqf"";};"];
sleep 5;
hint parseText "<t size='2.5' color='#00FF00'>Press "Delete" to Open your Admin menu</t>";
};

//0xD3 is "Delete" above the arrow keys


Fixed it
 
(Sorry for the late reply) So I applied your fix, and still got the same error, So I decided to download Blur's free antihack, and then used short cords trigger method for the antihack. I had to edit the line in 1535 (Admin Menu Start) to be like this so it wouldn't crash:
Code:
(findDisplay 46) displayAddEventHandler ["KeyUp", "if ((_this select 1) == 0xD3) then {call compile preprocessFileLineNumbers ""\tools\start.sqf"";};"];
(Had to put the tools folder into the compile folder for the script to find start.sqf)
But then when i press delete, Nothing pops in. My best guess is that the start.sqf script is outdated, and I'm wondering if anyone can rewrite it, I seriously doubt anyone would take the time to rewrite it, but if someone has free time, maybe they can help someone from the internet :).

EDIT: I'm really afraid to put the start.sqf on public, So download it from here: http://opendayz.net/threads/short-cords-admin-tools.12128/ Or PM me.
 
(Sorry for the late reply) So I applied your fix, and still got the same error, So I decided to download Blur's free antihack, and then used short cords trigger method for the antihack. I had to edit the line in 1535 (Admin Menu Start) to be like this so it wouldn't crash:
Code:
(findDisplay 46) displayAddEventHandler ["KeyUp", "if ((_this select 1) == 0xD3) then {call compile preprocessFileLineNumbers ""\tools\start.sqf"";};"];
(Had to put the tools folder into the compile folder for the script to find start.sqf)
But then when i press delete, Nothing pops in. My best guess is that the start.sqf script is outdated, and I'm wondering if anyone can rewrite it, I seriously doubt anyone would take the time to rewrite it, but if someone has free time, maybe they can help someone from the internet :).

EDIT: I'm really afraid to put the start.sqf on public, So download it from here: http://opendayz.net/threads/short-cords-admin-tools.12128/ Or PM me.
The Rpt is reporting syntax errors, which need to be fixed before testing to see if it actually works
Shouldn't be
""\tools\start.sqf"";};"];
Should be:
"\tools\start.sqf";};"];
 
I didn't have any error with the code i previously had.
I got this error on the .rpt
Code:
 0:12:11 Error in expression <call compile preprocessFileLineNumbers "\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error position: <\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error Missing ]
0:12:11 File z\addons\dayz_server\compile\ah.sqf, line 1535
0:12:11 Error in expression <call compile preprocessFileLineNumbers "\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error position: <\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error Missing ]
0:12:11 File z\addons\dayz_server\compile\ah.sqf, line 1535
Got any more ideas?
 
I didn't have any error with the code i previously had.
I got this error on the .rpt
Code:
 0:12:11 Error in expression <call compile preprocessFileLineNumbers "\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error position: <\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error Missing ]
0:12:11 File z\addons\dayz_server\compile\ah.sqf, line 1535
0:12:11 Error in expression <call compile preprocessFileLineNumbers "\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error position: <\tools\start.sqf";};"];
(findDisplay 46)>
0:12:11  Error Missing ]
0:12:11 File z\addons\dayz_server\compile\ah.sqf, line 1535
Got any more ideas?

Then, my syntax is off, forgot that the if statement was already in quotation marks. Revert to the previous.
On that thread you posted you forgot to actually add the finddisplay command so it should be based on that thread (findDisplay 46) displayAddEventHandler ["KeyUp", "if ((_this select 1) == 0xD3) then {call compile preprocessFileLineNumbers "\z\addons\dayz_server\tools\start.sqf";};"];
 
Already tried that before ;_;.

When I did that the script couldn't find it so i had to put it in the script's folder and it worked, but nothing popped up.
 
Already tried that before ;_;.

When I did that the script couldn't find it so i had to put it in the script's folder and it worked, but nothing popped up.

What does the rpt say when you press delete? I might just rewrite it to add an action instead.
 
Thank you so much :D

Should work, at least in editor. Also, where are you placing this code?
Code:
waituntil {!alive player ; !isnull (finddisplay 46)};
sleep 30;
if ((getPlayerUID player) in ["*censored*"]) then {
player addaction ["Admin tools","\z\addons\dayz_server\tools\start.sqf"];
};
 
Sadly, Short cords menu is broken, The menu doesn't generate even though text appears saying f = tele, F5 = spawn vehicle, and hijack vehicle. Posting purplishs code here (And me putting the message.) if anyone wants to fix the entire menu.
Code:
waituntil {!alive player ; !isnull (finddisplay 46)};
sleep 30;
if ((getPlayerUID player) in ["10355529","14195657"]) then {
    player addaction [("<t color=""#ff0000"">" + ("Admin Menu") +"</t>"),"admintools\start.sqf"];
    sleep 5;
    hint parseText "<t size='2.5' color='#00FF00'>Welcome SWNN Admin! Use Scroll Wheel and click Admin menu to access your tools!</t>";
};
 
//Purplish Edited Initadmin.sqf with scroll menu as the toggle! Also tools points to the mission folder.

you want admin tools?? i may be able to help.. do u have a teampseak?

I went on the ts3 server on your sig and they said you haven't been on in a month, I don't have a ts3 server in the moment. PM me if you wanna talk ;).
 
Should work, at least in editor. Also, where are you placing this code?
Code:
waituntil {!alive player ; !isnull (finddisplay 46)};
sleep 30;
if ((getPlayerUID player) in ["*censored*"]) then {
player addaction ["Admin tools","\z\addons\dayz_server\tools\start.sqf"];
};

Thank you so much for helping me :D. I cant explain how much i am thankful.
 
Back
Top