|
Last change
on this file since 11297 was
8858,
checked in by landauf, 14 years ago
|
|
merged output branch back to trunk.
Changes:
- you have to include util/Output.h instead of util/Debug.h
- COUT(x) is now called orxout(level)
- output levels are now defined by an enum instead of numbers. see util/Output.h for the definition
- it's possible to use output contexts with orxout(level, context). see util/Output.h for some common contexts. you can define more contexts
- you must use 'endl' at the end of an output message, '\n' does not flush the message
Output levels:
- instead of COUT(0) use orxout()
- instead of COUT(1) use orxout(user_error) or orxout(internal_error)
- instead of COUT(2) use orxout(user_warning) or orxout(internal_warning)
- instead of COUT(3) use orxout(user_status/user_info) or orxout(internal_status/internal_info)
- instead of COUT(4) use orxout(verbose)
- instead of COUT(5) use orxout(verbose_more)
- instead of COUT(6) use orxout(verbose_ultra)
Guidelines:
- user_* levels are for the user, visible in the console and the log-file
- internal_* levels are for developers, visible in the log-file
- verbose_* levels are for debugging, only visible if the context of the output is activated
Usage in C++:
- orxout() << "message" << endl;
- orxout(level) << "message" << endl;
- orxout(level, context) << "message" << endl;
Usage in Lua:
- orxout("message")
- orxout(orxonox.level.levelname, "message")
- orxout(orxonox.level.levelname, "context", "message")
Usage in Tcl (and in the in-game-console):
- orxout levelname message
- orxout_context levelname context message
- shortcuts: log message, error message, warning message, status message, info message, debug message
|
-
Property svn:eol-style set to
native
|
|
File size:
1.7 KB
|
| Line | |
|---|
| 1 | <!-- DEBUG OVERLAY --> |
|---|
| 2 | <OverlayGroup |
|---|
| 3 | name = "Debug" |
|---|
| 4 | scale = "1.0, 1.0" |
|---|
| 5 | scroll = "0, 0" |
|---|
| 6 | visible = false |
|---|
| 7 | > |
|---|
| 8 | <OverlayText |
|---|
| 9 | name = "FPSTextCaption" |
|---|
| 10 | position = "0.03, 0.05" |
|---|
| 11 | font = "Monofur" |
|---|
| 12 | caption = "Frames per second:" |
|---|
| 13 | textsize = 0.03 |
|---|
| 14 | /> |
|---|
| 15 | |
|---|
| 16 | <DebugFPSText |
|---|
| 17 | name = "FPSText" |
|---|
| 18 | position = "0.3, 0.05" |
|---|
| 19 | font = "Monofur" |
|---|
| 20 | textsize = 0.03 |
|---|
| 21 | /> |
|---|
| 22 | |
|---|
| 23 | <OverlayText |
|---|
| 24 | name = "RTRTextCaption" |
|---|
| 25 | position = "0.03, 0.09" |
|---|
| 26 | font = "Monofur" |
|---|
| 27 | caption = "Tick time in ms: " |
|---|
| 28 | textsize = 0.03 |
|---|
| 29 | /> |
|---|
| 30 | |
|---|
| 31 | <DebugRTRText |
|---|
| 32 | name = "RTRText" |
|---|
| 33 | position = "0.3, 0.09" |
|---|
| 34 | font = "Monofur" |
|---|
| 35 | textsize = 0.03 |
|---|
| 36 | /> |
|---|
| 37 | |
|---|
| 38 | </OverlayGroup> |
|---|
| 39 | |
|---|
| 40 | <Template name="defaultHUD"> |
|---|
| 41 | <OverlayGroup name = "defaultHUD" scale = "1, 1"> |
|---|
| 42 | <KillMessage |
|---|
| 43 | name = "killmessage" |
|---|
| 44 | position = "0.5, 0.15" |
|---|
| 45 | font = "VeraMono" |
|---|
| 46 | textsize = 0.035 |
|---|
| 47 | colour = "1.0, 1.0, 0.5, 1.0" |
|---|
| 48 | align = "center" |
|---|
| 49 | /> |
|---|
| 50 | |
|---|
| 51 | <DeathMessage |
|---|
| 52 | name = "deathmessage" |
|---|
| 53 | position = "0.5, 0.20" |
|---|
| 54 | font = "VeraMono" |
|---|
| 55 | textsize = 0.035 |
|---|
| 56 | colour = "1.0, 0.3, 0.3, 1.0" |
|---|
| 57 | align = "center" |
|---|
| 58 | /> |
|---|
| 59 | |
|---|
| 60 | <PauseNotice |
|---|
| 61 | name = "pausenotice" |
|---|
| 62 | position = "0.5, 0.1" |
|---|
| 63 | font = "VeraMono" |
|---|
| 64 | textsize = 0.03 |
|---|
| 65 | colour = "1.0, 1.0, 1.0, 1.0" |
|---|
| 66 | align = "center" |
|---|
| 67 | /> |
|---|
| 68 | |
|---|
| 69 | <AnnounceMessage |
|---|
| 70 | name = "announcemessage" |
|---|
| 71 | position = "0.5, 0.75" |
|---|
| 72 | font = "VeraMono" |
|---|
| 73 | textsize = 0.05 |
|---|
| 74 | colour = "0.5, 0.5, 1.0, 1.0" |
|---|
| 75 | align = "center" |
|---|
| 76 | /> |
|---|
| 77 | |
|---|
| 78 | <ChatOverlay |
|---|
| 79 | name = "chat" |
|---|
| 80 | position = "0.03, 0.08" |
|---|
| 81 | font = "VeraMono" |
|---|
| 82 | caption = "" |
|---|
| 83 | textsize = 0.025 |
|---|
| 84 | /> |
|---|
| 85 | |
|---|
| 86 | </OverlayGroup> |
|---|
| 87 | </Template> |
|---|
Note: See
TracBrowser
for help on using the repository browser.