Jump to content

Simple script problem.


Karuzo

Recommended Posts

Hey Guys,

I have a Simple-Script, but it doesn't really work..

function Spawn1(thePlayer) 
        spawnPlayer(thePlayer, 1177.51917, -1324.05542, 14.07470,-90, math.random(1,50) , 0, 0, nil) 
        outputChatBox("Welcome!", thePlayer, 0, 255, 0, false) 
end 
addEventHandler("onPlayerJoin", getRootElement(), Spawn1) 

Link to comment
function Spawn1(source) 
        spawnPlayer(source, 1177.51917, -1324.05542, 14.07470,-90, math.random(1,50) , 0, 0, nil) 
        outputChatBox("Welcome!", source, 0, 255, 0, false) 
end 
addEventHandler("onPlayerJoin", getRootElement(), Spawn1) 

Don't defined the source because it's already defined from the event as a player!

Link to comment

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...