Mike269 Posted February 10, 2015 Share Posted February 10, 2015 Hello guys, I know that most of you will say that you're just helping us and you wont make scripts for us but I just need help how could I spawn cars for team only like if my team name is NAVY I could use command /create infernus NAVY or something like that, would be very cool if anyone could help me with that, thanks! Link to comment
Enargy, Posted February 10, 2015 Share Posted February 10, 2015 you can use somethin' like this: function spawnCar(thePlayer, command) local x,y,z = getElementPosition(thePlayer) local playerTeam = getPlayerTeam(thePlayer) if playerTeam then local teamName = getTeamName(playerTeam) if ( teamName == "NAVY" ) then car = createVehicle(411, x,y,z) warpPedIntoVehicle(thePlayer, car) else outputChatBox("You're not part of NAVY team!", thePlayer, 255, 0, 0, false) end end end addCommandHandler("spawnc", spawnCar) check it out https://wiki.multitheftauto.com/ Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now