Jump to content

[HELP] How do I set this script to die?


rayzem

Recommended Posts

-- SERVER SIDE

local aclSpawns = {
	["Everyone"] = {
		pos = {1109, 5131, 16},
		skin = 60,
		weapons = {
			{31, 1000},
			{23, 1000},
			{29, 1000},
		},
	},
	
	["Police"] = {
		pos = {-1635, 677, -4},
		skin = 60,
		weapons = {
			{31, 1000},
			{23, 1000},
			{29, 1000},
		},
	},
	
	["Admin"] = {
		pos = {-49, -270, 6},
		skin = 60,
		weapons = {
			{31, 1000},
			{23, 1000},
			{29, 1000},
		},
	},
}

addEventHandler("onPlayerLogin", root, function(_, account)
	for aclname, data in pairs(aclSpawns) do
		if isObjectInACLGroup("user."..getAccountName(account), aclGetGroup(aclname)) then
			setElementPosition(source, data.pos[1], data.pos[2], data.pos[3])
            setElementModel(source, data.skin)
			
			for i, weapon in ipairs(data.weapons) do
				giveWeapon(source, weapon[1], weapon[2])
			end
			
			return
		end
	end
end)

 

How can I set this script to die please help !

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