delete. Posted February 9, 2017 Share Posted February 9, 2017 (edited) Hi, just made a really simple script for teams, but everytime a player joins it puts him on above of all teams. I need help from you guys how to make default team "Unemployed" local Unemployed = createTeam("Unemployed", 255, 0, 255) setPlayerTeam(player, Unemployed) setElementModel(player, 0) end Thanks! Edited February 9, 2017 by testchannel50 Link to comment
Dimos7 Posted February 9, 2017 Share Posted February 9, 2017 (edited) local Unemployed = createTeam("Unemployed", 255, 0, 255) addEventHandler("onPlayerJoin", root, function() setPlayerTeam(source, Unempolyed) setElementModel(source, 0) end end) Edited February 9, 2017 by Dimos7 Link to comment
delete. Posted February 10, 2017 Author Share Posted February 10, 2017 ERROR: Loading script failed: jobcommand\server.lua:31: ')' expected (to close '(' at line 26) near 'end' @Dimos7 Link to comment
Dimos7 Posted February 10, 2017 Share Posted February 10, 2017 local Unemployed = createTeam("Unemployed", 255, 0, 255) addEventHandler("onPlayerJoin", root, function() setPlayerTeam(source, Unempolyed) setElementModel(source, 0) end) Link to comment
delete. Posted February 10, 2017 Author Share Posted February 10, 2017 24 minutes ago, Dimos7 said: local Unemployed = createTeam("Unemployed", 255, 0, 255) addEventHandler("onPlayerJoin", root, function() setPlayerTeam(source, Unempolyed) setElementModel(source, 0) end) Nope, it still sets me as no team when i reconnect/join: Link to comment
Dimos7 Posted February 10, 2017 Share Posted February 10, 2017 local Unemployed = createTeam("Unemployed", 255, 0, 255) addEventHandler("onPlayerConnect", root, function() setPlayerTeam(source, Unempolyed) setElementModel(source, 0) end) try that Link to comment
delete. Posted February 10, 2017 Author Share Posted February 10, 2017 34 minutes ago, Dimos7 said: local Unemployed = createTeam("Unemployed", 255, 0, 255) addEventHandler("onPlayerConnect", root, function() setPlayerTeam(source, Unempolyed) setElementModel(source, 0) end) try that Not sure why, still not working. Link to comment
Dimos7 Posted February 10, 2017 Share Posted February 10, 2017 local Unemployed = createTeam("Unemployed", 255, 0, 255) addEventHandler("onPlayerConnect", root, function() setPlayerTeam(source, Unemployed) setElementModel(source, 0) end) spell mistake Link to comment
delete. Posted February 10, 2017 Author Share Posted February 10, 2017 (edited) 32 minutes ago, Dimos7 said: local Unemployed = createTeam("Unemployed", 255, 0, 255) addEventHandler("onPlayerConnect", root, function() setPlayerTeam(source, Unemployed) setElementModel(source, 0) end) spell mistake Still not working. Edit: it does work now, thank you. Edited February 10, 2017 by testchannel50 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