Forum

> > CS2D > Servers > Players cant join Survivors Team
Forums overviewCS2D overview Servers overviewLog in to reply

English Players cant join Survivors Team

15 replies
To the start Previous 1 Next To the start

old Players cant join Survivors Team

_Yank
User Off Offline

Quote
Hello everbody.
This is about Zombies game mode.
I have a zombie server which players fight against Bots (Zombies). When someone join the survivors team nobody can join it too until the next round. They are only able to join Zombies but the server is for players fight against Zombies (bots) (Im using a script which dont let players join zombies, only bots). Then i tried to fix the problem using this scripts i made :

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
addhook("serveraction","k_lol3")
function k_lol3(id, action) 
	if action == 3 and player(id, 'team')==0 then --This one makes the player join CT with F4 key.
		parse('makect '..id..'')
	end
end


addhook("join","k_lol2")
function k_lol2(id)
	parse('mp_wpndmg Five-Seven 10000') -- Forget about this one
	parse('hudtxt2 '..id..' 2 "©255255255   Press F4 To Join CT!" 240 430') --Tells player F4 Info
	parse('hudtxt2 '..id..' 0 " '..player(id,"score")..'" 0 415') -- Forget about this one
end


addhook('team','lolteamxd')
function lolteamxd(id, team)
	if team == 0 then
		parse('hudtxt2 '..id..' 2 "©255255255 Press F4 to Join CT" 260 85') --Tried to do the same as k_lol2 function
	end
end

addhook('team','_teamk_')
function _teamk_(id, team)
	if team == 1 or 2 then 
		parse('hudtxt2 '..id..' 2 "©255255255 " 240 430') --This one deletes the F4 info after player join CT 
		parse('hudtxt2 '..id..' 3 "©255255255 " 260 85')
	end
end

addhook('minute','ssk')
function ssk()
	msg('©051255204Press F4 To join ©000000000CT ©051255204=D') --This one tells the F4 info to player who skip the hud info
end


The script is too basic, noob and stupid because im not pro at lua yet. YET ^.^

Most of people in my server are newbies and they problably dont read the chat or dont know how to answer or dont know how to press F4 , they stay trying to join CT with the default change team menu of CS2D and they cant.

Hope you can help me, if not anyway thx.
PS:I only can go to PC at weekends then i will only can answer you next 5 days, also i can check with my android mobile.

old Re: Players cant join Survivors Team

Yates
Reviewer Off Offline

Quote
Why don't you automatically make them CT if they get killed?

Then again, I also have this do something to join ct system on one of my own servers. I actually refrain myself from doing the posted above due to people being better as a zombie than bots (obviously).

old Re: Players cant join Survivors Team

Rainoth
Moderator Off Offline

Quote
HE meant this

1
2
3
4
5
6
addhook("die","yayImdeadlol")
function yayImdeadlol(v,k,w,x,y)
	if player(v,"bot") == false then
		parse("makect "..v)
	end
end

At least I think that's what _Y meant :3

old Re: Players cant join Survivors Team

_Yank
User Off Offline

Quote
no is not that, the problem is when a player join and someone is playing in ct, the player cant join CT until the next round begin. But the round goes forever and like a said before i already made i script which players never join zombies.

old Re: Players cant join Survivors Team

Rainoth
Moderator Off Offline

Quote
Can it be when player presses button or sth ? If yes then my super useless script that I made is there for your help

Look up my profile and look at what files I uploaded.

old Re: Players cant join Survivors Team

Conscience
User Off Offline

Quote
@user _Yank: Either autoteambalance is on (cs2d cmd mp_autoteambalance) or you don't seem to understand _Y's post.

user Yates has written
> On death (killed by zombie)
> Make CT


You cannot check if someone tries to join CT via the menu because the team hook is only called when someone changes team. So the only way to make everyone CT is to change their team on death. Then again you might have the possibility of people complaining due to them wanting to stay T.

Your choice.

old Re: Players cant join Survivors Team

_Yank
User Off Offline

Quote
user _Yank has written
They are only able to join Zombies but the server is for players fight against Zombies (bots) (Im using a script which dont let players join zombies, only bots).

This is the script im using which i mentioned up.
1
2
3
4
5
6
7
8
9
10
11
12
13
addhook('team', '_k_team')
function _k_team(id, team)
	if player(id, 'bot') then
		if team == 2 then
			return 1
		end
	else
		if team == 1 then
			parse('hudtxt2 '..id..' 2 "" 240 430')
			return 1
		end
	end
end

And guys, the problem is not that when zombie kill a player and the player goes to Zombie Team.
I will try to explain my problem again : When a player joins ct and nobody is in ct becomes the roundstart. (Bots is always at Zombie Team) And everybody is able to join ct but few seconds after they are not able to join ct, they need to wait until roundstart. I made i script which players join ct with "serveraction3" (F4).

Please Help!
edited 1×, last 12.06.13 05:30:37 pm
To the start Previous 1 Next To the start
Log in to reply Servers overviewCS2D overviewForums overview