2
* Copyright (C) 2002,2003,2004 Daniel Heck
3
* Copyright (C) 2008 Ronald Lamprecht
5
* This program is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU General Public License
7
* as published by the Free Software Foundation; either version 2
8
* of the License, or (at your option) any later version.
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
15
* You should have received a copy of the GNU General Public License along
16
* with this program; if not, write to the Free Software Foundation, Inc.,
17
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
20
#ifndef SIMPLEFLOORS_HH
21
#define SIMPLEFLOORS_HH
30
class Abyss : public Floor {
37
virtual std::string getClass() const;
40
virtual bool is_destructible() const;
41
virtual void actor_contact(Actor *);
47
class DummyFloor : public Floor {
54
virtual std::string getClass() const;
57
virtual void actor_contact(Actor *);
63
class FakeFloor : public Floor {
67
FakeFloor(std::string flavor ="abyss");
70
virtual std::string getClass() const;
72
// GridObject interface
73
virtual std::string getModelName() const;
79
class IceFloor : public Floor {
86
virtual std::string getClass() const;
92
class InverseFloor : public Floor {
93
CLONEOBJ(InverseFloor);
96
InverseFloor(std::string flavor ="white");
99
virtual std::string getClass() const;
101
// GridObject interface
102
virtual std::string getModelName() const;
108
class Space : public Floor {
112
enum ObjectPrivatFlagsBits {
113
OBJBIT_FORCETYP = 1<<24 ///< apply flat force on space
117
Space(bool withForce = false);
120
virtual std::string getClass() const;
123
virtual void add_force(Actor *a, ecl::V2 &); // Note: actor = 0 must be allowed!
129
class Swamp : public Floor {
136
virtual std::string getClass() const;
139
virtual bool is_destructible() const;
140
virtual void get_sink_speed (double &sinkspeed, double &raisespeed) const;
146
class YinyangFloor : public Floor {
147
CLONEOBJ(YinyangFloor);
151
YIN, ///< player 0 - black image
152
YANG ///< player 1 - white image
155
enum ObjectPrivatFlagsBits {
156
OBJBIT_INVISIBLE = 1<<24, ///< yinyang symbol not visible
160
YinyangFloor(int initState, bool isInvisible =false);
163
virtual std::string getClass() const;
164
virtual void setAttr(const std::string &key, const Value &val);
165
virtual Value getAttr(const std::string &key) const;
167
// GridObject interface
168
virtual std::string getModelName() const;
171
virtual ecl::V2 process_mouseforce (Actor *a, ecl::V2 force);
173
} // namespace enigma