[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Pingus-CVS] CVS: Games/Pingus/src/worldobjsdata bumper_data.cxx,1.2,1.3
From: |
grumbel |
Subject: |
[Pingus-CVS] CVS: Games/Pingus/src/worldobjsdata bumper_data.cxx,1.2,1.3 bumper_data.hxx,1.1,1.2 fake_exit_data.cxx,1.2,1.3 fake_exit_data.hxx,1.1,1.2 guillotine_data.cxx,1.2,1.3 guillotine_data.hxx,1.1,1.2 hammer_data.cxx,1.2,1.3 hammer_data.hxx,1.1,1.2 laser_exit_data.cxx,1.2,1.3 laser_exit_data.hxx,1.1,1.2 smasher_data.hxx,1.1,1.2 spike_data.cxx,1.2,1.3 spike_data.hxx,1.1,1.2 teleporter_data.cxx,1.1,1.2 |
Date: |
10 Sep 2002 19:24:22 -0000 |
Update of /usr/local/cvsroot/Games/Pingus/src/worldobjsdata
In directory dark:/tmp/cvs-serv5031/src/worldobjsdata
Modified Files:
bumper_data.cxx bumper_data.hxx fake_exit_data.cxx
fake_exit_data.hxx guillotine_data.cxx guillotine_data.hxx
hammer_data.cxx hammer_data.hxx laser_exit_data.cxx
laser_exit_data.hxx smasher_data.hxx spike_data.cxx
spike_data.hxx teleporter_data.cxx
Log Message:
changed indention of namespaces in a few places
Index: bumper_data.cxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/bumper_data.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- bumper_data.cxx 10 Sep 2002 15:36:44 -0000 1.2
+++ bumper_data.cxx 10 Sep 2002 19:24:19 -0000 1.3
@@ -26,52 +26,52 @@
namespace WorldObjsData {
- BumperData::BumperData ()
- {
- }
+BumperData::BumperData ()
+{
+}
- BumperData::BumperData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/bumper", "traps"))
- {
- cur = cur->children;
- while (cur)
- {
- XMLhelper::skip_blank(cur);
+BumperData::BumperData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/bumper", "traps"))
+{
+ cur = cur->children;
+ while (cur)
+ {
+ XMLhelper::skip_blank(cur);
- if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
- {
- pos = XMLhelper::parse_vector(doc, cur);
- }
+ if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
+ {
+ pos = XMLhelper::parse_vector(doc, cur);
+ }
- cur = cur->next;
- }
- }
-
- BumperData::BumperData (const BumperData& old) : WorldObjData(old),
- surface(old.surface),
- pos(old.pos)
- {
- }
+ cur = cur->next;
+ }
+}
- void
- BumperData::write_xml (std::ostream& xml)
- {
- xml << "<worldobj type=\"bumper\">\n\t";
- XMLhelper::write_vector_xml(xml, pos);
- xml << "</worldobj>\n\n";
- }
+BumperData::BumperData (const BumperData& old) : WorldObjData(old),
+ surface(old.surface),
+ pos(old.pos)
+{
+}
- WorldObj*
- BumperData::create_WorldObj ()
- {
- return new WorldObjs::Bumper(this);
- }
+void
+BumperData::write_xml (std::ostream& xml)
+{
+ xml << "<worldobj type=\"bumper\">\n\t";
+ XMLhelper::write_vector_xml(xml, pos);
+ xml << "</worldobj>\n\n";
+}
- EditorObjLst
- BumperData::create_EditorObj ()
- {
- return EditorObjLst(1, new EditorObjs::BumperObj(this));
- }
+WorldObj*
+BumperData::create_WorldObj ()
+{
+ return new WorldObjs::Bumper(this);
+}
+EditorObjLst
+BumperData::create_EditorObj ()
+{
+ return EditorObjLst(1, new EditorObjs::BumperObj(this));
}
+
+} // WorldObjsData
/* EOF */
Index: bumper_data.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/bumper_data.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- bumper_data.hxx 4 Sep 2002 14:55:13 -0000 1.1
+++ bumper_data.hxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -27,28 +27,28 @@
namespace WorldObjsData {
- class BumperData : public WorldObjData {
- public:
- CL_Surface surface;
- CL_Vector pos;
+class BumperData : public WorldObjData {
+public:
+ CL_Surface surface;
+ CL_Vector pos;
- public:
- BumperData ();
- BumperData (xmlDocPtr doc, xmlNodePtr node);
- BumperData (const BumperData& old);
+public:
+ BumperData ();
+ BumperData (xmlDocPtr doc, xmlNodePtr node);
+ BumperData (const BumperData& old);
- void write_xml (std::ostream& xml);
+ void write_xml (std::ostream& xml);
- WorldObj* create_WorldObj ();
+ WorldObj* create_WorldObj ();
- EditorObjLst create_EditorObj ();
+ EditorObjLst create_EditorObj ();
- private:
- BumperData operator= (const BumperData&);
+private:
+ BumperData operator= (const BumperData&);
- };
+};
-}
+} // namespace WorldObjsData
#endif
Index: fake_exit_data.cxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/fake_exit_data.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- fake_exit_data.cxx 10 Sep 2002 15:36:44 -0000 1.2
+++ fake_exit_data.cxx 10 Sep 2002 19:24:20 -0000 1.3
@@ -26,52 +26,52 @@
namespace WorldObjsData {
- FakeExitData::FakeExitData ()
- {
- }
+FakeExitData::FakeExitData ()
+{
+}
- FakeExitData::FakeExitData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/fake_exit", "traps"))
- {
- cur = cur->children;
- while (cur)
- {
- XMLhelper::skip_blank(cur);
+FakeExitData::FakeExitData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/fake_exit", "traps"))
+{
+ cur = cur->children;
+ while (cur)
+ {
+ XMLhelper::skip_blank(cur);
- if (! strcmp(reinterpret_cast<const char*>(cur->name), "position"))
- {
- pos = XMLhelper::parse_vector(doc, cur);
- }
+ if (! strcmp(reinterpret_cast<const char*>(cur->name), "position"))
+ {
+ pos = XMLhelper::parse_vector(doc, cur);
+ }
- cur = cur->next;
- }
- }
-
- FakeExitData::FakeExitData (const FakeExitData& old) : WorldObjData(old),
- surface(old.surface),
- pos(old.pos)
- {
- }
+ cur = cur->next;
+ }
+}
- void
- FakeExitData::write_xml (std::ostream& xml)
- {
- xml << "<worldobj type=\"fake_exit\">\n\t";
- XMLhelper::write_vector_xml(xml, pos);
- xml << "</worldobj>\n\n";
- }
+FakeExitData::FakeExitData (const FakeExitData& old) : WorldObjData(old),
+ surface(old.surface),
+ pos(old.pos)
+{
+}
- WorldObj*
- FakeExitData::create_WorldObj ()
- {
- return new WorldObjs::FakeExit(this);
- }
+void
+FakeExitData::write_xml (std::ostream& xml)
+{
+ xml << "<worldobj type=\"fake_exit\">\n\t";
+ XMLhelper::write_vector_xml(xml, pos);
+ xml << "</worldobj>\n\n";
+}
- EditorObjLst
- FakeExitData::create_EditorObj ()
- {
- return EditorObjLst(1, new EditorObjs::FakeExitObj(this));
- }
+WorldObj*
+FakeExitData::create_WorldObj ()
+{
+ return new WorldObjs::FakeExit(this);
+}
+EditorObjLst
+FakeExitData::create_EditorObj ()
+{
+ return EditorObjLst(1, new EditorObjs::FakeExitObj(this));
}
+
+} // namespace WorldObjsData
/* EOF */
Index: fake_exit_data.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/fake_exit_data.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- fake_exit_data.hxx 4 Sep 2002 14:55:13 -0000 1.1
+++ fake_exit_data.hxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -28,29 +28,29 @@
namespace WorldObjsData {
- class FakeExitData : public WorldObjData {
- public:
- CL_Surface surface;
- CL_Vector pos;
- GameCounter counter;
+class FakeExitData : public WorldObjData {
+public:
+ CL_Surface surface;
+ CL_Vector pos;
+ GameCounter counter;
- public:
- FakeExitData ();
- FakeExitData (xmlDocPtr doc, xmlNodePtr node);
- FakeExitData (const FakeExitData& old);
+public:
+ FakeExitData ();
+ FakeExitData (xmlDocPtr doc, xmlNodePtr node);
+ FakeExitData (const FakeExitData& old);
- void write_xml (std::ostream& xml);
+ void write_xml (std::ostream& xml);
- WorldObj* create_WorldObj ();
+ WorldObj* create_WorldObj ();
- EditorObjLst create_EditorObj ();
+ EditorObjLst create_EditorObj ();
- private:
- FakeExitData operator= (const FakeExitData&);
+private:
+ FakeExitData operator= (const FakeExitData&);
- };
+};
-}
+} // namespace WorldObjsData
#endif
Index: guillotine_data.cxx
===================================================================
RCS file:
/usr/local/cvsroot/Games/Pingus/src/worldobjsdata/guillotine_data.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- guillotine_data.cxx 10 Sep 2002 15:36:44 -0000 1.2
+++ guillotine_data.cxx 10 Sep 2002 19:24:20 -0000 1.3
@@ -28,60 +28,60 @@
namespace WorldObjsData {
- GuillotineData::GuillotineData ()
- {
- }
+GuillotineData::GuillotineData ()
+{
+}
- GuillotineData::GuillotineData (xmlDocPtr doc, xmlNodePtr cur)
- : surface
(PingusResource::load_surface("Traps/guillotinekill", "traps")),
-
idle_surf(PingusResource::load_surface("Traps/guillotineidle", "traps"))
- {
- if (cur->name)
- std::cout << (const char*)cur->name << std::endl;
+GuillotineData::GuillotineData (xmlDocPtr doc, xmlNodePtr cur)
+ : surface (PingusResource::load_surface("Traps/guillotinekill", "traps")),
+ idle_surf(PingusResource::load_surface("Traps/guillotineidle", "traps"))
+{
+ if (cur->name)
+ std::cout << (const char*)cur->name << std::endl;
- cur = cur->children;
- while (cur)
- {
- XMLhelper::skip_blank(cur);
+ cur = cur->children;
+ while (cur)
+ {
+ XMLhelper::skip_blank(cur);
- if (! strcmp(reinterpret_cast<const char*>(cur->name), "position"))
- {
- pos = XMLhelper::parse_vector(doc, cur);
- }
- else
- std::cout << (const char*)cur->name << std::endl;
+ if (! strcmp(reinterpret_cast<const char*>(cur->name), "position"))
+ {
+ pos = XMLhelper::parse_vector(doc, cur);
+ }
+ else
+ std::cout << (const char*)cur->name << std::endl;
- cur = cur->next;
- }
- }
-
- GuillotineData::GuillotineData (const GuillotineData& old) :
WorldObjData(old),
-
surface(old.surface),
-
idle_surf(old.idle_surf),
- pos(old.pos)
- {
- }
+ cur = cur->next;
+ }
+}
- void
- GuillotineData::write_xml (std::ostream& xml)
- {
- xml << "<worldobj type=\"guillotine\">\n\t";
- XMLhelper::write_vector_xml(xml, pos);
- xml << "</worldobj>\n\n";
- }
+GuillotineData::GuillotineData (const GuillotineData& old) : WorldObjData(old),
+
surface(old.surface),
+
idle_surf(old.idle_surf),
+ pos(old.pos)
+{
+}
- WorldObj*
- GuillotineData::create_WorldObj ()
- {
- return new WorldObjs::Guillotine(this);
- }
+void
+GuillotineData::write_xml (std::ostream& xml)
+{
+ xml << "<worldobj type=\"guillotine\">\n\t";
+ XMLhelper::write_vector_xml(xml, pos);
+ xml << "</worldobj>\n\n";
+}
- EditorObjLst
- GuillotineData::create_EditorObj ()
- {
- return EditorObjLst(1, new EditorObjs::GuillotineObj(this));
- }
+WorldObj*
+GuillotineData::create_WorldObj ()
+{
+ return new WorldObjs::Guillotine(this);
+}
+EditorObjLst
+GuillotineData::create_EditorObj ()
+{
+ return EditorObjLst(1, new EditorObjs::GuillotineObj(this));
}
+
+} // namespace WorldObjsData
/* EOF */
Index: guillotine_data.hxx
===================================================================
RCS file:
/usr/local/cvsroot/Games/Pingus/src/worldobjsdata/guillotine_data.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- guillotine_data.hxx 4 Sep 2002 14:55:13 -0000 1.1
+++ guillotine_data.hxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -29,32 +29,32 @@
namespace WorldObjsData {
- class GuillotineData : public WorldObjData {
- public:
- CL_Surface surface;
- CL_Surface idle_surf;
- CL_Vector pos;
- Direction direction;
- GameCounter counter;
- GameCounter idle_counter;
+class GuillotineData : public WorldObjData {
+public:
+ CL_Surface surface;
+ CL_Surface idle_surf;
+ CL_Vector pos;
+ Direction direction;
+ GameCounter counter;
+ GameCounter idle_counter;
- public:
- GuillotineData ();
- GuillotineData (xmlDocPtr doc, xmlNodePtr node);
- GuillotineData (const GuillotineData& old);
+public:
+ GuillotineData ();
+ GuillotineData (xmlDocPtr doc, xmlNodePtr node);
+ GuillotineData (const GuillotineData& old);
- void write_xml (std::ostream& xml);
+ void write_xml (std::ostream& xml);
- WorldObj* create_WorldObj ();
+ WorldObj* create_WorldObj ();
- EditorObjLst create_EditorObj ();
+ EditorObjLst create_EditorObj ();
- private:
- GuillotineData operator= (const GuillotineData&);
+private:
+ GuillotineData operator= (const GuillotineData&);
- };
+};
-}
+} // namespace WorldObjsData
#endif
Index: hammer_data.cxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/hammer_data.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- hammer_data.cxx 10 Sep 2002 15:36:44 -0000 1.2
+++ hammer_data.cxx 10 Sep 2002 19:24:20 -0000 1.3
@@ -26,53 +26,53 @@
namespace WorldObjsData {
- HammerData::HammerData ()
- {
- }
+HammerData::HammerData ()
+{
+}
- HammerData::HammerData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/hammer", "traps"))
- {
- cur = cur->children;
- while (cur)
- {
- XMLhelper::skip_blank(cur);
+HammerData::HammerData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/hammer", "traps"))
+{
+ cur = cur->children;
+ while (cur)
+ {
+ XMLhelper::skip_blank(cur);
- if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
- {
- pos = XMLhelper::parse_vector(doc, cur);
- }
+ if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
+ {
+ pos = XMLhelper::parse_vector(doc, cur);
+ }
- cur = cur->next;
- }
- }
-
- HammerData::HammerData (const HammerData& old) : WorldObjData(old),
- surface(old.surface),
- pos(old.pos)
- {
- }
+ cur = cur->next;
+ }
+}
- void
- HammerData::write_xml (std::ostream& xml)
- {
- xml << "<worldobj type=\"hammer\">\n\t";
- XMLhelper::write_vector_xml(xml, pos);
- xml << "</worldobj>\n\n";
- }
+HammerData::HammerData (const HammerData& old) : WorldObjData(old),
+ surface(old.surface),
+ pos(old.pos)
+{
+}
- WorldObj*
- HammerData::create_WorldObj ()
- {
- return new WorldObjs::Hammer(this);
- }
+void
+HammerData::write_xml (std::ostream& xml)
+{
+ xml << "<worldobj type=\"hammer\">\n\t";
+ XMLhelper::write_vector_xml(xml, pos);
+ xml << "</worldobj>\n\n";
+}
- EditorObjLst
- HammerData::create_EditorObj ()
- {
- return EditorObjLst(1, new EditorObjs::HammerObj(this));
- }
+WorldObj*
+HammerData::create_WorldObj ()
+{
+ return new WorldObjs::Hammer(this);
+}
+EditorObjLst
+HammerData::create_EditorObj ()
+{
+ return EditorObjLst(1, new EditorObjs::HammerObj(this));
}
+
+} // namespace WorldObjsData
/* EOF */
Index: hammer_data.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/hammer_data.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- hammer_data.hxx 4 Sep 2002 14:55:13 -0000 1.1
+++ hammer_data.hxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -28,29 +28,29 @@
namespace WorldObjsData {
- class HammerData : public WorldObjData {
- public:
- CL_Surface surface;
- CL_Vector pos;
- GameCounter counter;
+class HammerData : public WorldObjData {
+public:
+ CL_Surface surface;
+ CL_Vector pos;
+ GameCounter counter;
- public:
- HammerData ();
- HammerData (xmlDocPtr doc, xmlNodePtr node);
- HammerData (const HammerData& old);
+public:
+ HammerData ();
+ HammerData (xmlDocPtr doc, xmlNodePtr node);
+ HammerData (const HammerData& old);
- void write_xml (std::ostream& xml);
+ void write_xml (std::ostream& xml);
- WorldObj* create_WorldObj ();
+ WorldObj* create_WorldObj ();
- EditorObjLst create_EditorObj ();
+ EditorObjLst create_EditorObj ();
- private:
- HammerData operator= (const HammerData&);
+private:
+ HammerData operator= (const HammerData&);
- };
+};
-}
+} // namespace WorldObjsData
#endif
Index: laser_exit_data.cxx
===================================================================
RCS file:
/usr/local/cvsroot/Games/Pingus/src/worldobjsdata/laser_exit_data.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- laser_exit_data.cxx 10 Sep 2002 15:36:44 -0000 1.2
+++ laser_exit_data.cxx 10 Sep 2002 19:24:20 -0000 1.3
@@ -26,52 +26,52 @@
namespace WorldObjsData {
- LaserExitData::LaserExitData ()
- {
- }
+LaserExitData::LaserExitData ()
+{
+}
- LaserExitData::LaserExitData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/laser_exit", "traps"))
- {
- cur = cur->children;
- while (cur)
- {
- XMLhelper::skip_blank(cur);
+LaserExitData::LaserExitData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/laser_exit", "traps"))
+{
+ cur = cur->children;
+ while (cur)
+ {
+ XMLhelper::skip_blank(cur);
- if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
- {
- pos = XMLhelper::parse_vector(doc, cur);
- }
+ if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
+ {
+ pos = XMLhelper::parse_vector(doc, cur);
+ }
- cur = cur->next;
- }
- }
-
- LaserExitData::LaserExitData (const LaserExitData& old) : WorldObjData(old),
-
surface(old.surface),
- pos(old.pos)
- {
- }
+ cur = cur->next;
+ }
+}
- void
- LaserExitData::write_xml (std::ostream& xml)
- {
- xml << "<worldobj type=\"laser_exit\">\n\t";
- XMLhelper::write_vector_xml(xml, pos);
- xml << "</worldobj>\n\n";
- }
+LaserExitData::LaserExitData (const LaserExitData& old) : WorldObjData(old),
+ surface(old.surface),
+ pos(old.pos)
+{
+}
- WorldObj*
- LaserExitData::create_WorldObj ()
- {
- return new WorldObjs::LaserExit(this);
- }
+void
+LaserExitData::write_xml (std::ostream& xml)
+{
+ xml << "<worldobj type=\"laser_exit\">\n\t";
+ XMLhelper::write_vector_xml(xml, pos);
+ xml << "</worldobj>\n\n";
+}
- EditorObjLst
- LaserExitData::create_EditorObj ()
- {
- return EditorObjLst(1, new EditorObjs::LaserExitObj(this));
- }
+WorldObj*
+LaserExitData::create_WorldObj ()
+{
+ return new WorldObjs::LaserExit(this);
+}
+EditorObjLst
+LaserExitData::create_EditorObj ()
+{
+ return EditorObjLst(1, new EditorObjs::LaserExitObj(this));
}
+
+} // namespace WorldObjsData
/* EOF */
Index: laser_exit_data.hxx
===================================================================
RCS file:
/usr/local/cvsroot/Games/Pingus/src/worldobjsdata/laser_exit_data.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- laser_exit_data.hxx 4 Sep 2002 14:55:13 -0000 1.1
+++ laser_exit_data.hxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -28,29 +28,29 @@
namespace WorldObjsData {
- class LaserExitData : public WorldObjData {
- public:
- CL_Surface surface;
- CL_Vector pos;
- GameCounter counter;
+class LaserExitData : public WorldObjData {
+public:
+ CL_Surface surface;
+ CL_Vector pos;
+ GameCounter counter;
- public:
- LaserExitData ();
- LaserExitData (xmlDocPtr doc, xmlNodePtr node);
- LaserExitData (const LaserExitData& old);
+public:
+ LaserExitData ();
+ LaserExitData (xmlDocPtr doc, xmlNodePtr node);
+ LaserExitData (const LaserExitData& old);
- void write_xml (std::ostream& xml);
+ void write_xml (std::ostream& xml);
- WorldObj* create_WorldObj ();
+ WorldObj* create_WorldObj ();
- EditorObjLst create_EditorObj ();
+ EditorObjLst create_EditorObj ();
- private:
- LaserExitData operator= (const LaserExitData&);
+private:
+ LaserExitData operator= (const LaserExitData&);
- };
+};
-}
+} // namespace WorldObjsData
#endif
Index: smasher_data.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/smasher_data.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- smasher_data.hxx 4 Sep 2002 14:55:13 -0000 1.1
+++ smasher_data.hxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -27,28 +27,28 @@
namespace WorldObjsData {
- class SmasherData : public WorldObjData {
- public:
- CL_Surface surface;
- CL_Vector pos;
+class SmasherData : public WorldObjData {
+public:
+ CL_Surface surface;
+ CL_Vector pos;
- public:
- SmasherData ();
- SmasherData (xmlDocPtr doc, xmlNodePtr node);
- SmasherData (const SmasherData& old);
+public:
+ SmasherData ();
+ SmasherData (xmlDocPtr doc, xmlNodePtr node);
+ SmasherData (const SmasherData& old);
- void write_xml (std::ostream& xml);
+ void write_xml (std::ostream& xml);
- WorldObj* create_WorldObj ();
+ WorldObj* create_WorldObj ();
- EditorObjLst create_EditorObj ();
+ EditorObjLst create_EditorObj ();
- private:
- SmasherData operator= (const SmasherData&);
+private:
+ SmasherData operator= (const SmasherData&);
- };
+};
-}
+} // namespace WorldObjsData
#endif
Index: spike_data.cxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/spike_data.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- spike_data.cxx 10 Sep 2002 15:36:44 -0000 1.2
+++ spike_data.cxx 10 Sep 2002 19:24:20 -0000 1.3
@@ -26,52 +26,52 @@
namespace WorldObjsData {
- SpikeData::SpikeData ()
- {
- }
+SpikeData::SpikeData ()
+{
+}
- SpikeData::SpikeData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/spike", "traps"))
- {
- cur = cur->children;
- while (cur)
- {
- XMLhelper::skip_blank(cur);
+SpikeData::SpikeData (xmlDocPtr doc, xmlNodePtr cur) :
surface(PingusResource::load_surface("Traps/spike", "traps"))
+{
+ cur = cur->children;
+ while (cur)
+ {
+ XMLhelper::skip_blank(cur);
- if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
- {
- pos = XMLhelper::parse_vector(doc, cur);
- }
+ if (strcmp(reinterpret_cast<const char*>(cur->name), "position") == 0)
+ {
+ pos = XMLhelper::parse_vector(doc, cur);
+ }
- cur = cur->next;
- }
- }
-
- SpikeData::SpikeData (const SpikeData& old) : WorldObjData(old),
- surface(old.surface),
- pos(old.pos)
- {
- }
+ cur = cur->next;
+ }
+}
- void
- SpikeData::write_xml (std::ostream& xml)
- {
- xml << "<worldobj type=\"spike\">\n\t";
- XMLhelper::write_vector_xml(xml, pos);
- xml << "</worldobj>\n\n";
- }
+SpikeData::SpikeData (const SpikeData& old) : WorldObjData(old),
+ surface(old.surface),
+ pos(old.pos)
+{
+}
- WorldObj*
- SpikeData::create_WorldObj ()
- {
- return new WorldObjs::Spike(this);
- }
+void
+SpikeData::write_xml (std::ostream& xml)
+{
+ xml << "<worldobj type=\"spike\">\n\t";
+ XMLhelper::write_vector_xml(xml, pos);
+ xml << "</worldobj>\n\n";
+}
- EditorObjLst
- SpikeData::create_EditorObj ()
- {
- return EditorObjLst(1, new EditorObjs::SpikeObj(this));
- }
+WorldObj*
+SpikeData::create_WorldObj ()
+{
+ return new WorldObjs::Spike(this);
+}
+EditorObjLst
+SpikeData::create_EditorObj ()
+{
+ return EditorObjLst(1, new EditorObjs::SpikeObj(this));
}
+
+} // namespace WorldObjsData
/* EOF */
Index: spike_data.hxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/worldobjsdata/spike_data.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- spike_data.hxx 4 Sep 2002 14:55:13 -0000 1.1
+++ spike_data.hxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -28,29 +28,29 @@
namespace WorldObjsData {
- class SpikeData : public WorldObjData {
- public:
- CL_Surface surface;
- CL_Vector pos;
- GameCounter counter;
+class SpikeData : public WorldObjData {
+public:
+ CL_Surface surface;
+ CL_Vector pos;
+ GameCounter counter;
- public:
- SpikeData ();
- SpikeData (xmlDocPtr doc, xmlNodePtr node);
- SpikeData (const SpikeData& old);
+public:
+ SpikeData ();
+ SpikeData (xmlDocPtr doc, xmlNodePtr node);
+ SpikeData (const SpikeData& old);
- void write_xml (std::ostream& xml);
+ void write_xml (std::ostream& xml);
- WorldObj* create_WorldObj ();
+ WorldObj* create_WorldObj ();
- EditorObjLst create_EditorObj ();
+ EditorObjLst create_EditorObj ();
- private:
- SpikeData operator= (const SpikeData&);
+private:
+ SpikeData operator= (const SpikeData&);
- };
+};
-}
+} // namespace WorldObjsData
#endif
Index: teleporter_data.cxx
===================================================================
RCS file:
/usr/local/cvsroot/Games/Pingus/src/worldobjsdata/teleporter_data.cxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- teleporter_data.cxx 10 Sep 2002 12:11:29 -0000 1.1
+++ teleporter_data.cxx 10 Sep 2002 19:24:20 -0000 1.2
@@ -26,89 +26,90 @@
namespace WorldObjsData {
- TeleporterData::TeleporterData () : sprite("teleporter", "worldobjs", 20.0f,
Sprite::NONE, Sprite::ONCE),
- target_sprite("teleportertarget",
"worldobjs", 20.0f, Sprite::NONE, Sprite::ONCE)
- {
- }
+TeleporterData::TeleporterData ()
+ : sprite("teleporter", "worldobjs", 20.0f, Sprite::NONE, Sprite::ONCE),
+ target_sprite("teleportertarget", "worldobjs", 20.0f, Sprite::NONE,
Sprite::ONCE)
+{
+}
- TeleporterData::TeleporterData (const TeleporterData& data) :
WorldObjData(data),
- pos(data.pos),
-
target_pos(data.target_pos),
-
sprite(data.sprite),
-
target_sprite(data.target_sprite)
- {
- }
+TeleporterData::TeleporterData (const TeleporterData& data) :
WorldObjData(data),
+ pos(data.pos),
+
target_pos(data.target_pos),
+
sprite(data.sprite),
+
target_sprite(data.target_sprite)
+{
+}
- void
- TeleporterData::write_xml (std::ostream& xml)
- {
- xml << " <worldobj type=\"teleporter\">";
- XMLhelper::write_vector_xml (xml, pos);
- xml << " <target>" << std::endl;
- XMLhelper::write_vector_xml (xml, target_pos);
- xml << " </target>" << std::endl;
- xml << " </worldobj>" << std::endl;
- }
+void
+TeleporterData::write_xml (std::ostream& xml)
+{
+ xml << " <worldobj type=\"teleporter\">";
+ XMLhelper::write_vector_xml (xml, pos);
+ xml << " <target>" << std::endl;
+ XMLhelper::write_vector_xml (xml, target_pos);
+ xml << " </target>" << std::endl;
+ xml << " </worldobj>" << std::endl;
+}
- TeleporterData::TeleporterData (xmlDocPtr doc, xmlNodePtr cur)
- {
- cur = cur->children;
+TeleporterData::TeleporterData (xmlDocPtr doc, xmlNodePtr cur)
+{
+ cur = cur->children;
- while (cur != NULL)
- {
- if (xmlIsBlankNode(cur))
- {
- cur = cur->next;
- continue;
- }
+ while (cur != NULL)
+ {
+ if (xmlIsBlankNode(cur))
+ {
+ cur = cur->next;
+ continue;
+ }
- if (strcmp((char*)cur->name, "position") == 0)
- {
- pos = XMLhelper::parse_vector (doc, cur);
- }
- else if (strcmp((char*)cur->name, "target") == 0)
- {
- xmlNodePtr ncur = cur->children;
+ if (strcmp((char*)cur->name, "position") == 0)
+ {
+ pos = XMLhelper::parse_vector (doc, cur);
+ }
+ else if (strcmp((char*)cur->name, "target") == 0)
+ {
+ xmlNodePtr ncur = cur->children;
- if (xmlIsBlankNode(ncur)) ncur = ncur->next;
+ if (xmlIsBlankNode(ncur)) ncur = ncur->next;
- if (ncur != NULL)
- target_pos = XMLhelper::parse_vector (doc, ncur);
- else
- std::cout << "TeleporterData::create (): <target> is empty" <<
std::endl;
- }
- else
- {
- std::cout << "TeleportData::create (): Unhandled " << cur->name <<
std::endl;
- }
+ if (ncur != NULL)
+ target_pos = XMLhelper::parse_vector (doc, ncur);
+ else
+ std::cout << "TeleporterData::create (): <target> is empty" <<
std::endl;
+ }
+ else
+ {
+ std::cout << "TeleportData::create (): Unhandled " << cur->name <<
std::endl;
+ }
- cur = cur->next;
- }
- }
+ cur = cur->next;
+ }
+}
- WorldObj*
- TeleporterData::create_WorldObj ()
- {
- return new WorldObjs::Teleporter(this);
- }
+WorldObj*
+TeleporterData::create_WorldObj ()
+{
+ return new WorldObjs::Teleporter(this);
+}
- EditorObjLst
- TeleporterData::create_EditorObj ()
- {
- std::cout << "TeleportData::create_EditorObj () " << std::endl;
- EditorObjLst objs(2);
+EditorObjLst
+TeleporterData::create_EditorObj ()
+{
+ std::cout << "TeleportData::create_EditorObj () " << std::endl;
+ EditorObjLst objs(2);
- EditorObjs::TeleporterObj* teleporter = new
EditorObjs::TeleporterObj(this);
- EditorObjs::TeleporterTargetObj* teleporter_target = new
EditorObjs::TeleporterTargetObj(teleporter);
-
- objs[0] = teleporter;
- objs[1] = teleporter_target;
+ EditorObjs::TeleporterObj* teleporter = new
EditorObjs::TeleporterObj(this);
+ EditorObjs::TeleporterTargetObj* teleporter_target = new
EditorObjs::TeleporterTargetObj(teleporter);
- std::cout << "TeleportData::create_EditorObj (): done" << std::endl;
+ objs[0] = teleporter;
+ objs[1] = teleporter_target;
- return objs;
- }
+ std::cout << "TeleportData::create_EditorObj (): done" << std::endl;
+ return objs;
}
+
+} // namespace WorldObjsData
/* EOF */
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Pingus-CVS] CVS: Games/Pingus/src/worldobjsdata bumper_data.cxx,1.2,1.3 bumper_data.hxx,1.1,1.2 fake_exit_data.cxx,1.2,1.3 fake_exit_data.hxx,1.1,1.2 guillotine_data.cxx,1.2,1.3 guillotine_data.hxx,1.1,1.2 hammer_data.cxx,1.2,1.3 hammer_data.hxx,1.1,1.2 laser_exit_data.cxx,1.2,1.3 laser_exit_data.hxx,1.1,1.2 smasher_data.hxx,1.1,1.2 spike_data.cxx,1.2,1.3 spike_data.hxx,1.1,1.2 teleporter_data.cxx,1.1,1.2,
grumbel <=
- Prev by Date:
[Pingus-CVS] CVS: Games/Pingus/src/editorobjs bumper_obj.cxx,1.5,1.6 bumper_obj.hxx,1.3,1.4 fake_exit_obj.cxx,1.6,1.7 fake_exit_obj.hxx,1.4,1.5 guillotine_obj.cxx,1.5,1.6 guillotine_obj.hxx,1.3,1.4 hammer_obj.cxx,1.5,1.6 hammer_obj.hxx,1.3,1.4 laser_exit_obj.cxx,1.5,1.6 laser_exit_obj.hxx,1.3,1.4 smasher_obj.hxx,1.4,1.5 spike_obj.cxx,1.5,1.6 spike_obj.hxx,1.3,1.4 teleporter_obj.hxx,1.2,1.3 teleporter_target_obj.cxx,1.2,1.3
- Next by Date:
[Pingus-CVS] CVS: Games/Pingus/src/worldobjs bumper.cxx,1.2,1.3 conveyor_belt.cxx,1.9,1.10 conveyor_belt.hxx,1.7,1.8 fake_exit.hxx,1.2,1.3 guillotine.cxx,1.2,1.3 guillotine.hxx,1.2,1.3 hammer.cxx,1.2,1.3 info_box.cxx,1.9,1.10 info_box.hxx,1.8,1.9 laser_exit.cxx,1.2,1.3 laser_exit.hxx,1.2,1.3 smasher.cxx,1.2,1.3 smasher.hxx,1.2,1.3 spike.cxx,1.2,1.3 spike.hxx,1.2,1.3 switch_door.cxx,1.10,1.11 switch_door.hxx,1.8,1.9 teleporter.cxx,1.8,1.9 teleporter.hxx,1.11,1.12
- Previous by thread:
[Pingus-CVS] CVS: Games/Pingus/src/editorobjs bumper_obj.cxx,1.5,1.6 bumper_obj.hxx,1.3,1.4 fake_exit_obj.cxx,1.6,1.7 fake_exit_obj.hxx,1.4,1.5 guillotine_obj.cxx,1.5,1.6 guillotine_obj.hxx,1.3,1.4 hammer_obj.cxx,1.5,1.6 hammer_obj.hxx,1.3,1.4 laser_exit_obj.cxx,1.5,1.6 laser_exit_obj.hxx,1.3,1.4 smasher_obj.hxx,1.4,1.5 spike_obj.cxx,1.5,1.6 spike_obj.hxx,1.3,1.4 teleporter_obj.hxx,1.2,1.3 teleporter_target_obj.cxx,1.2,1.3
- Next by thread:
[Pingus-CVS] CVS: Games/Pingus/src/worldobjs bumper.cxx,1.2,1.3 conveyor_belt.cxx,1.9,1.10 conveyor_belt.hxx,1.7,1.8 fake_exit.hxx,1.2,1.3 guillotine.cxx,1.2,1.3 guillotine.hxx,1.2,1.3 hammer.cxx,1.2,1.3 info_box.cxx,1.9,1.10 info_box.hxx,1.8,1.9 laser_exit.cxx,1.2,1.3 laser_exit.hxx,1.2,1.3 smasher.cxx,1.2,1.3 smasher.hxx,1.2,1.3 spike.cxx,1.2,1.3 spike.hxx,1.2,1.3 switch_door.cxx,1.10,1.11 switch_door.hxx,1.8,1.9 teleporter.cxx,1.8,1.9 teleporter.hxx,1.11,1.12
- Index(es):