LOCKDEFS text colour - possible?

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Post Reply
User avatar
Enjay
 
 
Posts: 27639
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

LOCKDEFS text colour - possible?

Post by Enjay »

Does anyone know if it is possible to colour the messages in LOCKDEFS? I'd like the "you need a X key" to be coloured appropriately to the key.

e.g. I have this:

Code: Select all

Message "This needs a Blue key."
and that just prints in the default red text.

So, I tried using the colour codes that work in Print and HUDMessage:

Code: Select all

Message "\chThis needs a Blue key."
But that just printed the full thing, including to escape code, to the screen. I tried a few variants of the above, but nothing worked.

So, is what I'm trying to do even possible?
User avatar
Enjay
 
 
Posts: 27639
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Re: LOCKDEFS text colour - possible?

Post by Enjay »

I think I've got it. I don't think LOCKDEFS supports \c but the LANGUAGE lump does. So, I can put the messages in there (which I probably should anyway) and reference the entries in LOCKDEFS.
Post Reply

Return to “Scripting”