I figure it could be made in two functions and a if then else hook, right?
[code]
if (some steamID Function here) then (A trigger to do something, just ply:kill() for simplicity) else end
[/code]
Right?
[QUOTE=LehFreakshow;17334586]I figure it could be made in two functions and a if then else hook, right?
[code]
if (some steamID Function here) then (A trigger to do something, just ply:kill() for simplicity) else end
[/code]
Right?[/QUOTE]
I'm not entirely sure what you're trying to do here, but here's how you'd do something when a specific player joins.
[lua]hook.Add("PlayerInitialSpawn","WeDontLikeTom",function(player)
-- If you have the player's Steam ID then replace the condition with
-- player:SteamID() == SteamIDString
if player:Name() == "Tom" then
player:Kill()
player:ChatPrint("We don't serve your kind here")
end
end)[/lua]
I think he means a costum Entity!
Why bad SPelling?
You'll have to specify where or how you want this check to happen.
[lua]
function Killem( ply )
--If the person's ID is that then..
if( ply:SteamID() == "ID" ) then
ply:Kill()
--Other wise..
else
Msg( "hello" )
end
end
hook.Add( "PlayerSpawn", "Killem", Killem )
--You could also use PlayerInitialSpawn
hook.Add( "PlayerInitialSpawn", "Killem", Killem )
[/lua]
You mean something like that?
Sorry, you need to Log In to post a reply to this thread.