How to change Font Color?


#1

Hello Choice of Games. This is a very simple question and I know it has a simple answer. But I have looked everywhere but I can’t seem to figure out how to change the Font Color. My game has a Dark Blue Background and I would like to have the text be of White Color. I know it will be a very easy thing but I am very stuck. Please Help.


Changing text colours
Help my Code.... The Civil Evolution
Formatting in choicescript
#2

style.css ->

body {
color: #somecolourcode
}


#3

Thanks, It worked.


#4

@CJW (and @anyoneelsewhoknowstheforce)

Little post bump BUT… I was wondering if there is a way of having variable font colours for a CS game. I understand the above stylesheet hack changes ALL the font in a game but I don’t want to change all the font colour all the time, just some of the colour some of the time.

Is there a way of doing it like you would bold something and then you would italic something and then you would [blue] write in blue text for a time [/blue] before going back to normal? If not - would it be simple enough to add to the codestuff that makes all this CS madness possible?

I’m hoping yes but then I’m just a protocol droid and not very knowledgeable about such things! :-??

Much love
D

(edit - the blue text above may not be visible on everyone’s browser!)


#5

@nine

Only by changing the cs interpreter code.
Look in the ui.js file and at the top there is a function called printx
within it there is a series of .replace lines, like:

.replace(/\\[i\\]/g, '<i>') .replace(/\\[\\/i\\]/g, '</i>')

You want to add two more, similar to this:

.replace(/\\[blue\\]/g, '<span style="color:blue;">') .replace(/\\[\\/blue\\]/g, '</span>');

Note that the semicolon is only necessary on your last line.
Whether or not this sort of modification will work with published titles, I cannot say.


Text Formatting?
Different looking text in game
Inserting spaces, or invisible character " "
#6

@CJW thank you very much! Genius!


"Conversation Markers"