lp://qastaging/~sapidlib-dev/sapidlib/message_class
- Get this branch:
- bzr branch lp://qastaging/~sapidlib-dev/sapidlib/message_class
Branch merges
Related bugs
Related blueprints
Branch information
Recent revisions
- 52. By DaelasKai
-
Modified receive_message() in mobile.c to reference msg_colours.h for the appropriate
color and starting text.For example:
message( "success", "message\n", this_player() ); will now show this:
[%^GREEN%^ BOLD%^SUCCESS% ^RESET% ^]: message\n In the msg_colours.h I defined the message class "success" to put the header in front
of the actual message. This is not nessesary. Instead, you can just put the pinkfish
tag of the desired color to colorize the message.One problem with this system of using color tags is if I define the message class "talk"
to be "%^CYAN%^" and do:message( "talk", "Hello everyone. I am %^RED%^
Happy%^ RESET%^ to see you!", this_player() ); Then, the message class "talk" will make the "Hello everyone. I am" to show up as cyan
"Happy" will be red and the "to see you!" will be white (because of the RESET).The workaround to this is to have the following in the code:
msg = replace_string(msg, "%^RESET%^", col);
and put it above this:
msg = col + msg + "%^RESET%^";The only problem this causes is with the first example of using a header text:
[%^GREEN%^ BOLD%^SUCCESS% ^RESET% ^]:
Then the header text would be written with every %^RESET%^ that is found.
This is bad so using headers should either be discouraged or simply done differently.An example:
message( "success", "", this_player() );
message( "text", "You have successfully....\n", this_player() ); Another example:
change the replace_string() that we added to a different standardized color tag such
as %^NOR%^. *shrugs* - 47. By Cody A.W. Somerville
-
Removed symlink and replaced with hard copy so that people using windows can download the branch.
- 45. By Richard Thomas Harrison
-
Fixed reset() in pager.c
If the pager object doesn't have an environment() then it would fail with
a runtime error in the logs because of the second line.
Replaced destruct(this_object( )) with destruct(). There is no difference
execution-wise since the pager object does not have a remove() function. - 44. By Richard Thomas Harrison
-
Cleared up an old bug that plagued set_ids in object.c
Cleaned up object.c to be a little more readable. - 43. By Richard Thomas Harrison
-
Removed experimental auto tune code.
Removed redundant #include's from I3 code.