Jump to content

how can i auto start debugscript on start?


mrvicio

Recommended Posts

Posted

hi all, im trying to get the "debugscript 3" inmediatly after connect, how can i do this?

i have tried on client side:

executeCommandHandler ( "debugscript","3") 
  
--and 
  
executeCommandHandler ( "debugscript 3") 

and on server side

  
addEventHandler ( "onPlayerJoin", getRootElement(), function()  
     
executeCommandHandler(source,"debugscript 3") 
--and 
executeCommandHandler(source,"debugscript", "3") 
end) 
  

and any of that functions works :S

How can i do that?

Posted

debugscript 3 is only for admin's so your resource need's admin right's to execute that command hander

Ingame Name : |DGT|Puma

DGT Clan Server 24/7 Owner/Scripter

MultiGameMode in progress :

n-560x95_FFFFFF_FFFFFF_0283C4_000000.png

Posted

Wrong, FatalTerror, 'source' is the player event of onPlayerLogin.

addEventHandler("onPlayerLogin", getRootElement(), 
function() 
executeCommandHandler(source, "debugscript", 3) 
end) 

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

bool executeCommandHandler ( string commandName, player thePlayer, [ string args ] )

Its:

  
executeCommandHandler("debugscript", source, 3) 
  

Ingame nick: Cadu12

Posted
addEventHandler("onPlayerLogin", getRootElement(), 
function() 
executeCommandHandler(source, "debugscript", 3) 
end) 

that don't give any errors, but it doesn't work either :S

Posted

mrvicio if you read what Cadu12 told you, you would know it's

executeCommandHandler("debugscript",source, "3")

the order matters (check the wiki) + the argument must be a string so use "3" not 3.

although i'm not sure executeCommandHandler will work with this built-in command

Posted
addEventHandler("onPlayerLogin", getRootElement(), 
function() 
executeCommandHandler("debugscript",source, "3") 
end) 

Here you go

n-560x95_E60303_FFFFFF_030303_FF0303.png
Posted

Please, speak only English on this forum, use the "Spanish" section to speak in your language.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...