Ulysses

General => Developers Corner => Topic started by: Deathtitan77 on February 11, 2013, 07:21:27 AM

Title: Spawn script
Post by: Deathtitan77 on February 11, 2013, 07:21:27 AM
Alright, so I am making a jailbreak gamemode. I am having a problem though, I can't get my spawn script to work. I would appreciate any help.

GM.Name = "Jailbreak"
GM.Author = ""
GM.Email = ""
GM.Website = ""

warden = ""
function GM:Initialize()
self.BaseClass.Initialize( self )
end

function GM:CreateTeams()
team.SetUp( 1, "Guards"    , Color(0  ,0,255), false)
team.SetSpawnPoint( 1, "info_player_counterterrorist" )
team.SetUp( 2, "Prisoners" , Color(255,0,0  ), false)
team.SetSpawnPoint( 2, "info_player_terrorist" )
end
Title: Re: Spawn script
Post by: nathan736 on February 11, 2013, 10:55:38 AM
give us full code this is not the spawn system this is just the back bone team system
PS: MOVE THIS TO DEV AREA
PSS: use the code brackets or use ideone for reading >: )
Title: Re: Spawn script
Post by: Bite That Apple on February 12, 2013, 01:15:34 AM
give us full code this is not the spawn system this is just the back bone team system
PS: MOVE THIS TO DEV AREA
PSS: use the code brackets or use ideone for reading >: )

Who is us?
Title: Re: Spawn script
Post by: Deathtitan77 on February 12, 2013, 04:38:58 AM
Well, this is my code. This is my whole spawn code.
Title: Re: Spawn script
Post by: Bite That Apple on February 12, 2013, 08:07:15 AM
Are there any console errors? If there are no errors, are you making sure to play the gamemode on a counter strike map or a map you made using counter strike as your mod in SDK Hammer?
Title: Re: Spawn script
Post by: nathan736 on February 12, 2013, 08:22:59 AM
EDIT
Well, this is my code. This is my whole spawn code.
this is not spawn code  by the way, this is how you set up the teams theres your problem click the link at the bottom \/ for info about teams

spawn code im sure does not work if you are not on a team (i don't think you get set to a team auto so you need a spectator and or dead team#)
ps : also you don't need to define warden as "" in game int or wherever you doing this (does not hurt tho)
pss: this might help some but might be old
Quote from: http://maurits.tv/data/garrysmod/wiki/wiki.garrysmod.com/index6665.html
You need to set the team up on both the client and the server. This would ideally be achieved by defining your team-setup's in your gamemode's shared file.

psss: might want to make sure you have your team set up you kind of did not give me everything so >: (
http://maurits.tv/data/garrysmod/wiki/wiki.garrysmod.com/index75fb.html