Ulysses
General => Developers Corner => Topic started by: Rad on July 13, 2007, 03:51:22 AM
-
How do you set up the starting weapons? I searched the forums but starting weapons did not return anything useful
I was able to find this link (http://forums.ulyssesmod.net/index.php/topic,360.msg1689.html#msg1689) but I do not know how to set it up. I put that file (ulx_scripts.lua) in the gmod/addons/Ulib/lua/Ulib/modules directory, but the commands dont seem to work.
Plus, its not exactly what I was looking for, I want to change starting weapons not use commands to give players SWEPS
Not sure if this is where it should go, it doesnt really belong in Suggestions, or Bug Report heh... and I would think this would be a FAQ (Unless I just missed something obvious)
-
Take a look at:
Gamemode.PlayerSpawn (http://www.garrysmod.com/wiki/?title=Gamemode.PlayerSpawn)
and
Player.Give (http://www.garrysmod.com/wiki/?title=Player.Give)
Then you can do something like that, very basically:
local function GiveCrowbarOnSpawn( ply )
ply:Give( "weapon_crowbar" )
end
hook.Add( "PlayerSpawn", "GiveCrowbarOnSpawnFunc", GiveCrowbarOnSpawn )
I'm also beginner so don't blame me if i'm wrong :P
-
If I do this, where do I put the script? How do I remove the other weapons etc? I have never messed with lua (Other than changing some strings etc), but I have done some minor programming before
-
[Note] - Topic moved and renamed due to improper forum location and off-topic to thread posted question