Forum

> > CS2D > Scripts > How to change color during game
Forums overviewCS2D overview Scripts overviewLog in to reply

English How to change color during game

4 replies
To the start Previous 1 Next To the start

old Re: How to change color during game

T-69
User Off Offline

Quote
You can't change chat colour in vanilla CS2D. But some servers that have scripts have special commands to change chat colour. The command, however, is different on every server.

old Re: How to change color during game

Rainoth
Moderator Off Offline

Quote
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
clr = {
user = {},
["red"] = "255000000",
["green"] = "000255000",
["blue"] = "000000255"
}

addhook("join","_j")
function _j(id)
	clr.user[id] = clr.red
end

addhook("say","_s")
function _s(id,t)
	for k,v in pairs (clr) do
		if t:find(k) then
			clr.user[id] = clr[k]
			return 1
		end
	end
	msg("/169..clr.user[id]..player(id,"name")..t)
end
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview