I have defined client.script in one of my files to set what the chat window should look like, but is there a way I can change that during my game? For example, say my chat window is blue text on a black bacground by default, but I want it to change to a black text on a red background during combat.
I tried altering client.script in a proc, but BYOND didn't like that very much. :-D
=$= Big J Money =$=
ID:135769
![]() Feb 27 2004, 9:50 am
|
|
Thing is, it would revert the next time you got any output in the text window. I believe Lummox is working on a way to edit client.script at runtime.
|
You can send the player a different style sheet as it is now. Just send them the style html tag with whatever you want inside.
|
That's not a permanent thing -- it reverts to the original style sheet everytime output is sent to the client.
|
So you make sure that all text sent to the player during that time is marked with that style. World-wide messages would present slightly more of a problem, but that could be overcome without too many difficulties.
|
<code>// In client.script .combat { background:red; text:black } // In the code src << "<span class=combat>CHARGE!!!!!!!</span>"</code>
Incidentally, black on red text looks horrible. =P