Last change
on this file since 481 was
481,
checked in by Sam Hocevar, 12 years ago
|
Fuck the history, I'm renaming all .hpp files to .h for my own sanity.
|
-
Property svn:keywords set to
Id
|
File size:
1.2 KB
|
Line | |
---|
1 | /* |
---|
2 | * Abuse - dark 2D side-scrolling platform game |
---|
3 | * Copyright (c) 1995 Crack dot Com |
---|
4 | * |
---|
5 | * This software was released into the Public Domain. As with most public |
---|
6 | * domain software, no warranty is made or implied by Crack dot Com or |
---|
7 | * Jonathan Clark. |
---|
8 | */ |
---|
9 | |
---|
10 | #ifndef __STATUS_HPP_ |
---|
11 | #define __STATUS_HPP_ |
---|
12 | |
---|
13 | #include "visobj.h" // get visual object declaration |
---|
14 | |
---|
15 | |
---|
16 | class status_manager |
---|
17 | { |
---|
18 | public : |
---|
19 | virtual void push(char const *name, visual_object *show) = 0; |
---|
20 | virtual void update(int percentage) = 0; |
---|
21 | virtual void pop() = 0; |
---|
22 | virtual void force_display() { ; } |
---|
23 | virtual ~status_manager() {} |
---|
24 | } ; |
---|
25 | |
---|
26 | |
---|
27 | class text_status_node; |
---|
28 | |
---|
29 | class text_status_manager : public status_manager |
---|
30 | { |
---|
31 | public : |
---|
32 | int level; |
---|
33 | text_status_node *first; |
---|
34 | text_status_manager(); |
---|
35 | virtual void push(char const *name, visual_object *show); |
---|
36 | virtual void update(int percentage); |
---|
37 | virtual void pop(); |
---|
38 | } ; |
---|
39 | |
---|
40 | |
---|
41 | extern status_manager *stat_man; |
---|
42 | |
---|
43 | class stack_stat // something you can declare on the stact that is sure to get cleaned up |
---|
44 | { |
---|
45 | public : |
---|
46 | stack_stat(char const *st, visual_object *show=NULL) { if (stat_man) stat_man->push(st,show); } |
---|
47 | ~stack_stat() { if (stat_man) stat_man->pop(); } |
---|
48 | } ; |
---|
49 | |
---|
50 | |
---|
51 | #endif |
---|
52 | |
---|
Note: See
TracBrowser
for help on using the repository browser.