Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- init.lua
- AddCSLuaFile( "cl_init.lua" )
- AddCSLuaFile( "shared.lua" )
- include( 'shared.lua' )
- -- Serverside only stuff goes here
- function GM:PlayerInitialSpawn( pl ) -- This is when the player spawns the first time, you can do this to take away weapons after death, etc.
- pl:GiveAmmo( 255, "Pistol", true ) -- This gives the amount of ammo you get and to what weapon respectively, 255 = 255 ammo, pistol = pistol
- pl:Give( "weapon_crowbar" ) -- this gives the player a weapon, specifically crowbar
- pl:SetGravity( 1 ) -- This integer is a multiplyer, the default gravity is 60, so if you want to decrease it, use a decimal, for example 50% would be ( 0.5 ) and 200% would be ( 2 )
- pl:SetWalkSpeed( "300" ) -- You will use a string here to define how many units per second you walk, 250 is the default so using 300 will show a difference.
- pl:SetRunSpeed( "600" ) -- I don't remember the default run speed, but this is an exaggerated amount.
- end
- function GM:PlayerSpawn( pl ) -- pl is a variable, when you are writing your code, if you are writing a function, you will want to include the variable in your code.
- pl:Give( "weapon_ar2" )
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement