[Home] [Downloads] [Search] [Help/forum]


Register forum user name Search FAQ

Gammon Forum

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Miniwindows
. . -> [Subject]  Colour changing problem

Colour changing problem

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page


Posted by Mendacitas   (10 posts)  [Biography] bio
Date Thu 05 Aug 2010 04:55 AM (UTC)
Message
So for some reason one of my window strings won't change colour for me:

here's part of the function:

WindowCreate (atkwin, 640, 325, 175, 200, 6, 2, ColourNameToRGB("silver"))
WindowShow (atkwin, true)
WindowFont (atkwin, "a","Trebuchet MS", 12, true, false, false, false)
WindowText (atkwin, "f","Attacks:", 4, 0, 0, 0, ColourNameToRGB ("lightgreen"), false)


WindowText (atkwin, "f", "Spells:", 4, 67, 0, 0, 0, ColourNameToRGB ("lightgreen"), false)
...

"f" is defined elsewhere like so:

WindowFont (win2, "f","Trebuchet MS", 10, true, false, false, false)

thing is, "Attacks:" is becoming light green no problem with that syntax, but "Spells:" will only show as black, no matter what I put inside of ColourNameToRGB
[Go to top] top

Posted by Nick Gammon   Australia  (22,973 posts)  [Biography] bio   Forum Administrator
Date Reply #1 on Thu 05 Aug 2010 05:48 AM (UTC)
Message
Quote:

WindowText (atkwin, "f","Attacks:", 4, 0, 0, 0, ColourNameToRGB ("lightgreen"), false)


WindowText (atkwin, "f", "Spells:", 4, 67, 0, 0, 0, ColourNameToRGB ("lightgreen"), false)


You have an extra 0 in the second one, which is black in RGB.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Mendacitas   (10 posts)  [Biography] bio
Date Reply #2 on Thu 05 Aug 2010 01:15 PM (UTC)
Message
0.0 I can't believe I didn't see that. I blame the hour.
[Go to top] top

Posted by Twisol   USA  (2,257 posts)  [Biography] bio
Date Reply #3 on Thu 05 Aug 2010 05:46 PM (UTC)
Message
No way I'd have seen that unless I knew what I was looking for. :(

'Soludra' on Achaea

Blog: http://jonathan.com/
GitHub: http://github.com/Twisol
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


10,865 views.

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.

[Home]


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at HostDash]