Skip to content

Commit

Permalink
enhanced map editor (with layers)
Browse files Browse the repository at this point in the history
  • Loading branch information
spidamoo committed May 23, 2014
1 parent a8cdf21 commit dff2478
Show file tree
Hide file tree
Showing 118 changed files with 4,359 additions and 640 deletions.
590 changes: 590 additions & 0 deletions SoDlib/SoDLib.depend

Large diffs are not rendered by default.

191 changes: 117 additions & 74 deletions SoDlib/SoDlib.layout
Original file line number Diff line number Diff line change
@@ -1,183 +1,226 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<CodeBlocks_layout_file>
<ActiveTarget name="Debug" />
<File name="src\GUIWindow.cpp" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\EffectAction.cpp" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1429" topLine="38" />
<Cursor1 position="2788" topLine="42" />
</Cursor>
<Folding>
<Collapse line="9" />
</Folding>
</File>
<File name="include\EffectPrototype.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\MapAnimation.h" open="1" top="0" tabpos="6" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="2975" topLine="74" />
<Cursor1 position="245" topLine="0" />
</Cursor>
</File>
<File name="src\Game.cpp" open="1" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="hgesprite.cpp" open="1" top="0" tabpos="3" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="32607" topLine="1000" />
<Cursor1 position="5992" topLine="262" />
</Cursor>
<Folding>
<Collapse line="2" />
</Folding>
</File>
<File name="include\GUIWindow.h" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\EffectPrototype.cpp" open="0" top="0" tabpos="11" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="314" topLine="0" />
<Cursor1 position="1187" topLine="12" />
</Cursor>
</File>
<File name="src\Character.cpp" open="0" top="0" tabpos="9" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\NonPlayerCharacter.h" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="8312" topLine="6" />
<Cursor1 position="223" topLine="0" />
</Cursor>
<Folding>
<Collapse line="2" />
<Collapse line="31" />
<Collapse line="35" />
</Folding>
</File>
<File name="hgegui.cpp" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="3306" topLine="194" />
<Cursor1 position="5552" topLine="286" />
</Cursor>
</File>
<File name="include\Game.h" open="1" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\GUIWindow.cpp" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="5883" topLine="172" />
<Cursor1 position="1429" topLine="38" />
</Cursor>
</File>
<File name="src\CharacterAction.cpp" open="1" top="0" tabpos="6" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\PlayerCharacter.h" open="0" top="0" tabpos="8" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1282" topLine="15" />
<Cursor1 position="101" topLine="0" />
</Cursor>
<Folding>
<Collapse line="44" />
<Collapse line="64" />
<Collapse line="82" />
</Folding>
</File>
<File name="src\NonPlayerCharacter.cpp" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="hgeguictrls.cpp" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="675" topLine="3" />
<Cursor1 position="1141" topLine="324" />
</Cursor>
</File>
<File name="src\CharacterActionCause.cpp" open="0" top="0" tabpos="7" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\Game.cpp" open="1" top="1" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="371" topLine="0" />
<Cursor1 position="32091" topLine="844" />
</Cursor>
<Folding>
<Collapse line="26" />
<Collapse line="2" />
<Collapse line="110" />
<Collapse line="116" />
<Collapse line="193" />
<Collapse line="201" />
<Collapse line="273" />
<Collapse line="327" />
<Collapse line="332" />
</Folding>
</File>
<File name="include\Character.h" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\SoDlib.h" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="271" topLine="0" />
</Cursor>
</File>
<File name="src\GroundLine.cpp" open="1" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1454" topLine="39" />
<Cursor1 position="2978" topLine="123" />
</Cursor>
</File>
<File name="src\CharacterActionEffect.cpp" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\hgeGUIEditableLabel.h" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1101" topLine="12" />
<Cursor1 position="700" topLine="0" />
</Cursor>
</File>
<File name="include\CharacterAction.h" open="1" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\CharacterAction.h" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="400" topLine="0" />
</Cursor>
</File>
<File name="include\NonPlayerCharacter.h" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\MapAnimation.cpp" open="1" top="0" tabpos="7" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="223" topLine="0" />
<Cursor1 position="445" topLine="0" />
</Cursor>
</File>
<File name="src\CharacterHotSpot.cpp" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\hgeGUIMenuItem.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="129" topLine="0" />
</Cursor>
</File>
<File name="src\NonPlayerCharacter.cpp" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="290" topLine="0" />
<Cursor1 position="675" topLine="3" />
</Cursor>
</File>
<File name="include\hgegui.h" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="648" topLine="22" />
</Cursor>
</File>
<File name="src\hgeGUIEditableLabel.cpp" open="0" top="0" tabpos="6" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="2250" topLine="101" />
<Cursor1 position="2273" topLine="101" />
</Cursor>
</File>
<File name="src\hgeGUIMenuItem.cpp" open="0" top="0" tabpos="7" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="290" topLine="0" />
<Cursor1 position="1290" topLine="43" />
</Cursor>
</File>
<File name="include\PlayerCharacter.h" open="0" top="0" tabpos="8" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\muParserBase.cpp" open="0" top="0" tabpos="12" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="101" topLine="0" />
<Cursor1 position="54457" topLine="1415" />
</Cursor>
</File>
<File name="include\SoDlib.h" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\CharacterActionEffect.h" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="271" topLine="0" />
<Cursor1 position="686" topLine="0" />
</Cursor>
</File>
<File name="include\CharacterHotSpot.h" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="332" topLine="0" />
</Cursor>
</File>
<File name="include\ConditionPrototype.h" open="0" top="0" tabpos="7" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="190" topLine="0" />
<Cursor1 position="564" topLine="9" />
</Cursor>
</File>
<File name="include\hgeGUIEditableLabel.h" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\CharacterActionCause.cpp" open="0" top="0" tabpos="7" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="700" topLine="0" />
<Cursor1 position="371" topLine="0" />
</Cursor>
<Folding>
<Collapse line="26" />
</Folding>
</File>
<File name="include\hgeGUIMenuItem.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\CharacterActionEffect.cpp" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="579" topLine="0" />
<Cursor1 position="1101" topLine="12" />
</Cursor>
</File>
<File name="hgeguictrls.cpp" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\Effect.h" open="0" top="0" tabpos="3" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1141" topLine="324" />
<Cursor1 position="739" topLine="4" />
</Cursor>
</File>
<File name="include\hgegui.h" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\Character.h" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="648" topLine="22" />
<Cursor1 position="858" topLine="30" />
</Cursor>
</File>
<File name="hgeanim.cpp" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\CharacterHotSpot.cpp" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="2293" topLine="113" />
<Cursor1 position="150" topLine="0" />
</Cursor>
</File>
<File name="src\Effect.cpp" open="0" top="0" tabpos="8" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\EffectAction.h" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="8299" topLine="192" />
<Cursor1 position="1221" topLine="11" />
</Cursor>
</File>
<File name="src\EffectAction.cpp" open="0" top="0" tabpos="5" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\EffectPrototype.h" open="0" top="0" tabpos="10" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="2788" topLine="42" />
<Cursor1 position="2136" topLine="64" />
</Cursor>
</File>
<File name="src\ConditionPrototype.cpp" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1885" topLine="109" />
</Cursor>
<Folding>
<Collapse line="9" />
<Collapse line="12" />
</Folding>
</File>
<File name="src\EffectPrototype.cpp" open="0" top="0" tabpos="3" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\CharacterActionCause.h" open="0" top="0" tabpos="8" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="8767" topLine="0" />
<Cursor1 position="513" topLine="9" />
</Cursor>
</File>
<File name="include\Effect.h" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\GUIWindow.h" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="304" topLine="7" />
<Cursor1 position="314" topLine="0" />
</Cursor>
</File>
<File name="include\CharacterActionEffect.h" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="hgeanim.cpp" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="686" topLine="0" />
<Cursor1 position="2293" topLine="113" />
</Cursor>
</File>
<File name="include\EffectAction.h" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="src\Character.cpp" open="0" top="0" tabpos="9" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1221" topLine="11" />
<Cursor1 position="18099" topLine="305" />
</Cursor>
<Folding>
<Collapse line="2" />
<Collapse line="31" />
<Collapse line="35" />
</Folding>
</File>
<File name="include\CharacterActionCause.h" open="0" top="0" tabpos="8" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<File name="include\Game.h" open="1" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="513" topLine="9" />
<Cursor1 position="5129" topLine="147" />
</Cursor>
</File>
<File name="src\CharacterAction.cpp" open="0" top="0" tabpos="6" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="1282" topLine="15" />
</Cursor>
<Folding>
<Collapse line="44" />
</Folding>
</File>
<File name="src\Effect.cpp" open="0" top="0" tabpos="4" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
<Cursor>
<Cursor1 position="3901" topLine="129" />
</Cursor>
</File>
</CodeBlocks_layout_file>
2 changes: 1 addition & 1 deletion SoDlib/include/Character.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class Character
float getHalfWidth();
int getOnGround();

float getHotSpotX(int index), getHotSpotY(int index);
float getHotSpotX(int index), getHotSpotY(int index); int getHotSpotIndex(char* name);

float getAnimTime();

Expand Down
6 changes: 4 additions & 2 deletions SoDlib/include/CharacterHotSpot.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@ class CharacterHotSpot
CharacterHotSpot(TiXmlElement* xml);
virtual ~CharacterHotSpot();

b2Shape* getShape();
b2Shape* getShape();
char* getName(); void setName(char* name);
protected:
b2Shape* shape;
int type;
int type;
char* name;
private:
};

Expand Down
5 changes: 4 additions & 1 deletion SoDlib/include/ConditionPrototype.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,17 @@ class ConditionPrototype
virtual ~ConditionPrototype();

void loadFromXml(TiXmlElement* xml);
void saveToXml(TiXmlElement* elem);

void setParam(int index, float value);
void setParamsFromCharacter(Character* character);
void setName(const char* name);
char* getName();

int getType();
int getType(); void setType(int type);
float getValue(), getDuration(), getInterval();
const char* getValueFormula(); const char* getDurationFormula(); const char* getIntervalFormula();
void setValueFormula(char* formula), setDurationFormula(char* formula), setIntervalFormula(char* formula);

Condition* spawnCondition(Character* inflictor, Character* bearer);
protected:
Expand Down
2 changes: 2 additions & 0 deletions SoDlib/include/Effect.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ class Effect

float getTime();
void setPosition(b2Vec2 position); b2Vec2 getPosition();
void setHotSpotIndex(int index);

void setAnimation(hgeAnimation* animation, int blendMode);

Expand All @@ -27,6 +28,7 @@ class Effect
float time;
int r, g, b, a;
float scale;
int hotSpotIndex;

EffectPrototype* prototype;

Expand Down
7 changes: 4 additions & 3 deletions SoDlib/include/EffectPrototype.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ class EffectPrototype
Effect* spawnEffect(Character* character);
Effect* spawnEffect(Effect* effect);

int getPositionType(), getAreaType(), getHotSpotIndex();
void setPositionType(int type), setAreaType(int type);
int getPositionType(), getAreaType(); char* getHotSpotName();
void setPositionType(int type), setAreaType(int type), setHotSpotName(char* name);

int getActionsCount(); EffectAction* getAction(int index);
void addAction(), removeAction(int index);
Expand Down Expand Up @@ -102,7 +102,8 @@ class EffectPrototype

float* params;

int positionType, areaType, hotSpotIndex;
int positionType, areaType;
char* hotSpotName;

EffectAction** actions; int actionsCount;
char** animations; int animationsCount; int blendMode;
Expand Down
Loading

0 comments on commit dff2478

Please sign in to comment.