• Props - Custom gamemode
    5 replies, posted
Hey Is there way i can implement the sandbox spawnmenu? And how do i spawn a prop like you spawning the prop in the spawnmenu. Have tried to check the files in sandbox, to see how they did it. But couldnt find it.
[lua]DeriveGamemode("sandbox")[/lua]
Just set your gamemode's base to sandbox. Look in the gamemode_name.txt and set the base to sandbox. Then in gamemode/shared.lua call [IMG]http://wiki.garrysmod.com/favicon.ico[/IMG] [URL="http://wiki.garrysmod.com/page/Global/DeriveGamemode"]Global.DeriveGamemode[/URL].
Thanks you solved my first problem, anyone can answer my second problem?
by using the spawn menu
[QUOTE=TheEvilDirect;47645544]Thanks you solved my first problem, anyone can answer my second problem?[/QUOTE] The console command `gm_spawn[sent/swep/vehicle] [model/classname]` is what gets called by the spawnmenu buttons. Is that what you want? [url]https://github.com/garrynewman/garrysmod/blob/e7111a4ab8318b69c3a29e2cbea6cc57ec0bcf5a/garrysmod/gamemodes/sandbox/gamemode/commands.lua#L280[/url]
Sorry, you need to Log In to post a reply to this thread.