Forum

> > CS2D > Scripts > Who could tell me why this script isn't working?
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch Who could tell me why this script isn't working?

15 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt Who could tell me why this script isn't working?

Xirot
User Off Offline

Zitieren
Well, I just wanna know why this script isn't working.
I checked the console it haves no errors.
Mehr >


EDIT: Can you please tell me how I can add colors for each message?

alt Re: Who could tell me why this script isn't working?

Xirot
User Off Offline

Zitieren
Okay, the code is fixed.
Mehr >


How to make this message color red for example?
1
msg (player(killer,"name").." made double kill!")

alt Re: Who could tell me why this script isn't working?

Mora
User Off Offline

Zitieren
@user Xirot: as @user Talented Doge: said, using \169rrrgggbbb:
1
msg ("\169255000000"..player(killer,"name").." made double kill!")
Also you can make the table of the colors:
1
2
3
4
5
colors = {
	"\169255255255",
	"\169000255000",
	"\169255000255",
}
and using them as:
1
msg(colors[1].." "..player(killer,"name").." made double kill!")
1× editiert, zuletzt 11.08.15 21:04:47

alt Re: Who could tell me why this script isn't working?

Mami Tomoe
User Off Offline

Zitieren
Or... do it the easy way for newbies like me... and use the © thingy.

example:
©255255255 is white
©000000000 is black

©255255255 i like milk ©000000000 and i need it now!
          will be white          will be black
easy

alt Re: Who could tell me why this script isn't working?

Mora
User Off Offline

Zitieren
@user Mami Tomoe: not all ppls know that they're need to press alt+0169, and not all even smart a bit for take it from symbols table :d.
Anyway, © and \169 doing the same, but i need to press 4 keys instead of 5 and i may get it wrong. also it may lead to problems(maybe) with unicode(however it's called).
/anyway the problem already fixed in pm.

alt Re: Who could tell me why this script isn't working?

Xirot
User Off Offline

Zitieren
A small bug?
Mehr >

I don't know why doublekill,killingspree,triplekill colors have bug they appears like this
Zitat
Player y255255255 : test1

Also when a player make triple,killingspree or more kills he goes back to level 0 which means when he stops killing and come back to fight and get more kills after a while he goes back to doublekill which is a bug.

Players should not make successive kills to get sounds..

alt Re: Who could tell me why this script isn't working?

Ridho
User Off Offline

Zitieren
you can put this in the beginning of your script
color=string.char(169)
colo={"©255000000","©000255000","©000000255","©255255255"}

to find color code (RGB), you can use Color Schemer

use "colo", if your color choice is in the table
but if you want to use other color, use "color"

example:
msg2(id,""..colo[2].."You, "..color.."190190190"..player(id,"name").." "..colo[1].."killed "..colo[2]..""..player(victim,"name"))

output:
msg to a player, it says "You" with green color, then "your character name" with grey color, then "killed" with red color, and "victim name" with green color again

read carefully
I hope you understand
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht