|
From: <Mac...@us...> - 2006-06-01 13:11:09
|
Revision: 79 Author: Machaira Date: 2006-06-01 06:10:49 -0700 (Thu, 01 Jun 2006) ViewCVS: http://svn.sourceforge.net/perceptioncrash/?rev=79&view=rev Log Message: ----------- Added first cut of character creation window; some changes to quest classes. Modified Paths: -------------- trunk/perceptioncrash/contrib/VC++Project/perceptioncrash/perceptioncrash.vcproj trunk/perceptioncrash/src/Entity.hpp trunk/perceptioncrash/src/IntroState.cpp trunk/perceptioncrash/src/MainMenuState.cpp trunk/perceptioncrash/src/Quest.cpp trunk/perceptioncrash/src/Quest.hpp trunk/perceptioncrash/src/QuestManager.cpp trunk/perceptioncrash/src/QuestManager.hpp Added Paths: ----------- trunk/perceptioncrash/data/gui/newgame.xml trunk/perceptioncrash/src/Quests.hpp Modified: trunk/perceptioncrash/contrib/VC++Project/perceptioncrash/perceptioncrash.vcproj =================================================================== --- trunk/perceptioncrash/contrib/VC++Project/perceptioncrash/perceptioncrash.vcproj 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/contrib/VC++Project/perceptioncrash/perceptioncrash.vcproj 2006-06-01 13:10:49 UTC (rev 79) @@ -39,7 +39,7 @@ <Tool Name="VCCLCompilerTool" Optimization="0" - AdditionalIncludeDirectories="..\..\..\lib\sdl\win\include;include;"$(OGRE_HOME)\include";"$(OGRE_HOME)\samples\include";C:\boost_1_33_1;"$(OGRE_HOME)\include\CEGUI"" + AdditionalIncludeDirectories=""C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Include";include;"$(OGRE_HOME)\include";"$(OGRE_HOME)\include\CEGUI";"$(OGRE_HOME)\samples\include";C:\boost_1_33_1;..\..\..\lib\sdl\win\include;C:\SVN\trunk\perceptioncrash\src\tinyxml" PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS" MinimalRebuild="true" ExceptionHandling="1" @@ -64,10 +64,10 @@ /> <Tool Name="VCLinkerTool" - AdditionalDependencies="OgreMain_d.lib CEGUIBase_d.lib OgreGUIRenderer_d.lib" - OutputFile="..\..\..\$(ProjectName).exe" + AdditionalDependencies="OgreMain_d.lib CEGUIBase_d.lib OgreGUIRenderer_d.lib SDL.lib SDLmain.lib" + OutputFile="$(OGRE_HOME)\bin\debug\$(ProjectName).exe" LinkIncremental="2" - AdditionalLibraryDirectories="$(OGRE_HOME)\lib" + AdditionalLibraryDirectories=""$(OGRE_HOME)\lib";C:\SVN\trunk\perceptioncrash\lib\sdl\win\lib" GenerateDebugInformation="true" ProgramDatabaseFile="$(OutDir)/perceptioncrash.pdb" SubSystem="2" @@ -78,6 +78,7 @@ /> <Tool Name="VCManifestTool" + UseFAT32Workaround="true" /> <Tool Name="VCXDCMakeTool" @@ -125,7 +126,7 @@ <Tool Name="VCCLCompilerTool" InlineFunctionExpansion="1" - AdditionalIncludeDirectories="include;$(OGRE_HOME)\include;$(OGRE_HOME)\include\CEGUI;$(OGRE_HOME)\samples\include" + AdditionalIncludeDirectories="include;"$(OGRE_HOME)\include";"$(OGRE_HOME)\include\CEGUI";"$(OGRE_HOME)\samples\include";"C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Include";C:\boost_1_33_1;..\..\..\lib\sdl\win\include;C:\SVN\trunk\perceptioncrash\src\tinyxml" PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS" MinimalRebuild="true" ExceptionHandling="1" @@ -149,10 +150,10 @@ /> <Tool Name="VCLinkerTool" - AdditionalDependencies="OgreMain.lib CEGUIBase.lib OgreGUIRenderer.lib" - OutputFile="..\..\..\$(ProjectName).exe" + AdditionalDependencies="OgreMain.lib CEGUIBase.lib OgreGUIRenderer.lib SDL.lib SDLmain.lib" + OutputFile="$(OGRE_HOME)\bin\release\$(ProjectName).exe" LinkIncremental="1" - AdditionalLibraryDirectories="$(OGRE_HOME)\lib" + AdditionalLibraryDirectories="$(OGRE_HOME)\lib;C:\SVN\trunk\perceptioncrash\lib\sdl\win\lib" GenerateDebugInformation="true" SubSystem="2" OptimizeReferences="2" @@ -223,6 +224,10 @@ > </File> <File + RelativePath="..\..\..\src\NewGameState.cpp" + > + </File> + <File RelativePath="..\..\..\src\PauseState.cpp" > </File> @@ -242,6 +247,22 @@ RelativePath="..\..\..\src\QuestManager.cpp" > </File> + <File + RelativePath="..\..\..\src\tinyxml\tinystr.cpp" + > + </File> + <File + RelativePath="..\..\..\src\tinyxml\tinyxml.cpp" + > + </File> + <File + RelativePath="..\..\..\src\tinyxml\tinyxmlerror.cpp" + > + </File> + <File + RelativePath="..\..\..\src\tinyxml\tinyxmlparser.cpp" + > + </File> </Filter> <Filter Name="Header Files" @@ -253,6 +274,10 @@ > </File> <File + RelativePath="..\..\..\src\EntityManager.hpp" + > + </File> + <File RelativePath="..\..\..\src\Factory.hpp" > </File> @@ -293,6 +318,10 @@ > </File> <File + RelativePath="..\..\..\src\NewGameState.hpp" + > + </File> + <File RelativePath="..\..\..\src\PauseState.hpp" > </File> @@ -313,6 +342,18 @@ > </File> <File + RelativePath="..\..\..\src\Quests.hpp" + > + </File> + <File + RelativePath="..\..\..\src\tinyxml\tinystr.h" + > + </File> + <File + RelativePath="..\..\..\src\tinyxml\tinyxml.h" + > + </File> + <File RelativePath="..\..\..\src\item_system\WeaponItem.hpp" > </File> Added: trunk/perceptioncrash/data/gui/newgame.xml =================================================================== --- trunk/perceptioncrash/data/gui/newgame.xml (rev 0) +++ trunk/perceptioncrash/data/gui/newgame.xml 2006-06-01 13:10:49 UTC (rev 79) @@ -0,0 +1,225 @@ +<?xml version="1.0" encoding="UTF-8"?> +<GUILayout> +<Window Type="DefaultWindow" Name="Root" > +<Property Name="UnifiedAreaRect" Value="{{0.000000,0.000000},{0.000000,0.000000},{1.000000,0.000000},{1.000000,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +<Window Type="TaharezLook/StaticText" Name="lblPoints" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Points Remaining:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.065000,0.000000},{0.085000,0.000000},{0.210000,0.000000},{0.145000,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblPointsRemaining" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="10" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.252500,0.000000},{0.085000,0.000000},{0.311250,0.000000},{0.145000,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblSTR" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Strength:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.065000,0.000000},{0.168333,0.000000},{0.210000,0.000000},{0.228333,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Spinner" Name="spnAGI" > +<Property Name="CurrentValue" Value="60.000000" /> +<Property Name="Text" Value="60" /> +<Property Name="UnifiedAreaRect" Value="{{0.252500,0.000000},{0.250000,0.000000},{0.327500,0.000000},{0.306667,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblAGI" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Agility:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.065000,0.000000},{0.250000,0.000000},{0.210000,0.000000},{0.310000,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Spinner" Name="spnSTR" > +<Property Name="CurrentValue" Value="60.000000" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="Text" Value="60" /> +<Property Name="UnifiedAreaRect" Value="{{0.252500,0.000000},{0.168334,0.000000},{0.327500,0.000000},{0.225001,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblCON" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Constitution:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.065000,0.000000},{0.415000,0.000000},{0.210000,0.000000},{0.475000,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Spinner" Name="spnDEX" > +<Property Name="CurrentValue" Value="60.000000" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="Text" Value="60" /> +<Property Name="UnifiedAreaRect" Value="{{0.251250,0.000000},{0.333334,0.000000},{0.326250,0.000000},{0.390001,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Spinner" Name="spnCON" > +<Property Name="CurrentValue" Value="60.000000" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="Text" Value="60" /> +<Property Name="UnifiedAreaRect" Value="{{0.251250,0.000000},{0.415000,0.000000},{0.326250,0.000000},{0.471667,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblDEX" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Dexterity:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.065000,0.000000},{0.333333,0.000000},{0.210000,0.000000},{0.393333,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblWIL" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Will:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.066250,0.000000},{0.581667,0.000000},{0.211250,0.000000},{0.641667,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Spinner" Name="spnINT" > +<Property Name="CurrentValue" Value="60.000000" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="Text" Value="60" /> +<Property Name="UnifiedAreaRect" Value="{{0.253750,0.000000},{0.503334,0.000000},{0.328750,0.000000},{0.560001,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Spinner" Name="spnWIL" > +<Property Name="CurrentValue" Value="60.000000" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="Text" Value="60" /> +<Property Name="UnifiedAreaRect" Value="{{0.255000,0.000000},{0.583334,0.000000},{0.330000,0.000000},{0.640001,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblINT" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Intelligence:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.065000,0.000000},{0.501666,0.000000},{0.210000,0.000000},{0.561666,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Editbox" Name="txtName" > +<Property Name="MaxTextLength" Value="1073741823" /> +<Property Name="MouseCursorImage" Value="set:TaharezLook image:MouseTextBar" /> +<Property Name="UnifiedAreaRect" Value="{{0.253750,0.000000},{0.668333,0.000000},{0.503750,0.000000},{0.728333,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblName" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Name:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.065000,0.000000},{0.666667,0.000000},{0.157500,0.000000},{0.728333,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Button" Name="bntOK" > +<Property Name="MouseCursorImage" Value="set:TaharezLook image:MouseArrow" /> +<Property Name="Text" Value="OK" /> +<Property Name="UnifiedAreaRect" Value="{{0.325000,0.000000},{0.841667,0.000000},{0.453750,0.000000},{0.931667,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/Button" Name="btnCancel" > +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="MouseCursorImage" Value="set:TaharezLook image:MouseArrow" /> +<Property Name="Text" Value="Cancel" /> +<Property Name="UnifiedAreaRect" Value="{{0.477500,0.000000},{0.840000,0.000000},{0.606250,0.000000},{0.930000,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/StaticText" Name="lblSex" > +<Property Name="BackgroundImage" Value="set:TaharezLook image:StaticBackdrop" /> +<Property Name="BottomFrameImage" Value="set:TaharezLook image:StaticBottom" /> +<Property Name="BottomLeftFrameImage" Value="set:TaharezLook image:StaticBottomLeft" /> +<Property Name="BottomRightFrameImage" Value="set:TaharezLook image:StaticBottomRight" /> +<Property Name="LeftFrameImage" Value="set:TaharezLook image:StaticLeft" /> +<Property Name="RightFrameImage" Value="set:TaharezLook image:StaticRight" /> +<Property Name="Text" Value="Sex:" /> +<Property Name="TopFrameImage" Value="set:TaharezLook image:StaticTop" /> +<Property Name="TopLeftFrameImage" Value="set:TaharezLook image:StaticTopLeft" /> +<Property Name="TopRightFrameImage" Value="set:TaharezLook image:StaticTopRight" /> +<Property Name="UnifiedAreaRect" Value="{{0.066250,0.000000},{0.753333,0.000000},{0.125000,0.000000},{0.813333,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/RadioButton" Name="rdoMale" > +<Property Name="Text" Value="Male" /> +<Property Name="UnifiedAreaRect" Value="{{0.255000,0.000000},{0.753333,0.000000},{0.327500,0.000000},{0.800000,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +<Window Type="TaharezLook/RadioButton" Name="rdoFemale" > +<Property Name="Font" Value="Commonwealth-10" /> +<Property Name="Text" Value="Female" /> +<Property Name="UnifiedAreaRect" Value="{{0.376250,0.000000},{0.751666,0.000000},{0.470000,0.000000},{0.798333,0.000000}}" /> +<Property Name="UnifiedMaxSize" Value="{{1.000000,0.000000},{1.000000,0.000000}}" /> +</Window> +</Window> +</GUILayout> Modified: trunk/perceptioncrash/src/Entity.hpp =================================================================== --- trunk/perceptioncrash/src/Entity.hpp 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/src/Entity.hpp 2006-06-01 13:10:49 UTC (rev 79) @@ -2,19 +2,40 @@ #define PC_ENTITY_HPP #include <OgreEntity.h> +#include <string> +#include <vector> +#include "tinyxml/tinyxml.h" + +#include "Quest.hpp" +#include "QuestManager.hpp" + +class QuestManager; +class Quest; + class Entity : public Ogre::Entity { public: Entity(void); + Entity(TiXmlElement* node); + public: ~Entity(void); + bool HasQuest; + private: - std::string mName; + std::string mName; + std::vector<Quest*> mQuests; //quests that the entity has that the player can get + + QuestManager* mAssignedQuests; //quests the player has accepted + + + + }; #endif /* PC_ENTITY_HPP */ Modified: trunk/perceptioncrash/src/IntroState.cpp =================================================================== --- trunk/perceptioncrash/src/IntroState.cpp 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/src/IntroState.cpp 2006-06-01 13:10:49 UTC (rev 79) @@ -23,8 +23,10 @@ mExitGame = false; - mTimerID = SDL_AddTimer(3000, IntroState::timerCallback, this); + //SDL_Init(SDL_INIT_TIMER); + //mTimerID = SDL_AddTimer(3000, IntroState::timerCallback, this); + } void @@ -38,8 +40,7 @@ mRoot->getAutoCreatedWindow()->removeAllViewports(); mRoot->destroySceneManager(mSceneMgr); - SDL_RemoveTimer(mTimerID); - + //SDL_Quit(); } void @@ -88,6 +89,7 @@ Uint32 IntroState::timerCallback(Uint32 interval, void* param) { + SDL_RemoveTimer(IntroState::getInstance()->mTimerID); IntroState::getInstance()->changeState(MainMenuState::getInstance()); return 0; Modified: trunk/perceptioncrash/src/MainMenuState.cpp =================================================================== --- trunk/perceptioncrash/src/MainMenuState.cpp 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/src/MainMenuState.cpp 2006-06-01 13:10:49 UTC (rev 79) @@ -1,7 +1,7 @@ #include <Ogre.h> #include "MainMenuState.hpp" -#include "PlayState.hpp" +#include "NewGameState.hpp" MainMenuState MainMenuState::mMainMenuState; @@ -72,7 +72,7 @@ { if (e->getButton() == "select") { - changeState(PlayState::getInstance()); + changeState(NewGameState::getInstance()); } if (e->getButton() == "back") Modified: trunk/perceptioncrash/src/Quest.cpp =================================================================== --- trunk/perceptioncrash/src/Quest.cpp 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/src/Quest.cpp 2006-06-01 13:10:49 UTC (rev 79) @@ -7,3 +7,9 @@ Quest::~Quest(void) { } + +Quest::Quest(TiXmlElement* node) +{ + + +} \ No newline at end of file Modified: trunk/perceptioncrash/src/Quest.hpp =================================================================== --- trunk/perceptioncrash/src/Quest.hpp 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/src/Quest.hpp 2006-06-01 13:10:49 UTC (rev 79) @@ -1,12 +1,15 @@ #ifndef PC_QUEST_HPP #define PC_QUEST_HPP -#include "tinyxml/tinyxml.h" #include <string> #include <vector> -using namespace std; +#include "tinyxml/tinyxml.h" +#include "Entity.hpp" + +class Entity; + enum QuestType { QUEST_FED_EX, @@ -24,50 +27,62 @@ REWARD_LOOT }; -struct QuestStep +class Quest; + +class QuestStep { public: - string StepName; + std::string StepName; + Entity* Target; + int ConversationIndex; + int RewardIndex; + int ItemToGiveIndex; + QuestType Interaction; + long TimeLimit; + std::vector<Quest> SubQuests; + }; + class Quest { public: Quest(void); - Quest(TiXmlElement* element); + Quest(TiXmlElement* node); public: ~Quest(void); void Save(); - void Save(string filename); + void Save(std::string filename); + void Save(TiXmlElement* parent); - void Load(string filename); + void Load(std::string filename); + void Load(TiXmlElement* node); - private: - string mName; - QuestType mType; - int mID; - string mDescription; + int mID; + std::string mName; + QuestType mType; + std::string mDescription; - RewardType mRewardType; - int mRewardID; //for loot reward - int mRewardAmount; //for cash reward + RewardType mRewardType; + int mRewardID; //for loot reward + int mRewardAmount; //for cash reward - vector<QuestStep> mSteps; + std::vector<QuestStep> mSteps; - long mTimeLimit; //measured in milliseconds, 0 = no time limit + long mTimeLimit; //measured in milliseconds, 0 = no time limit - vector<int> mPreQuestsRequired; //quests that must be completed before this one + std::vector<int> mPreQuestsRequired; //quests that must be completed before this one - bool mAllowMultiple; //can this quest be performed multiple times - long mTimeBetweenQuests; //measured in milliseconds, 0 = no time limit + bool mAllowMultiple; //can this quest be performed multiple times + long mTimeBetweenQuests; //measured in milliseconds, 0 = no time limit - string mFileName; //the file this quest is saved in + std::string mFileName; //the file this quest is saved in Modified: trunk/perceptioncrash/src/QuestManager.cpp =================================================================== --- trunk/perceptioncrash/src/QuestManager.cpp 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/src/QuestManager.cpp 2006-06-01 13:10:49 UTC (rev 79) @@ -1,4 +1,48 @@ #include "QuestManager.hpp" -QuestManager QuestManager::mQuestManager; +Quest* QuestManager::FindQuest(int id) +{ + + return NULL; +} + +void QuestManager::Load(TiXmlElement* node) +{ + +} + +void QuestManager::Save(TiXmlElement* parent) +{ + + +} + +bool QuestManager::AssignQuest(int id, Entity* entity) +{ + + if (!PlayerHasQuest(id)) + { + AssignedQuest* qst = new AssignedQuest(); + + qst->mID=id; + qst->mCurStep=0; + + mQuests.push_back(*qst); + + return true; + } + + return false; +} + +bool QuestManager::PlayerHasQuest(int id) +{ + for (int i=0; i < ((int)mQuests.size())-1; i++) + { + if (mQuests[i].mID == id) + return true; + } + + return false; +} \ No newline at end of file Modified: trunk/perceptioncrash/src/QuestManager.hpp =================================================================== --- trunk/perceptioncrash/src/QuestManager.hpp 2006-05-26 19:57:10 UTC (rev 78) +++ trunk/perceptioncrash/src/QuestManager.hpp 2006-06-01 13:10:49 UTC (rev 79) @@ -1,23 +1,50 @@ #ifndef PC_QUEST_MANAGER_HPP #define PC_QUEST_MANAGER_HPP +#include <vector> +#include "tinyxml/tinyxml.h" #include "GameState.hpp" #include "QuestLogState.hpp" +#include "Entity.hpp" +#include "Quest.hpp" +class Entity; +class Quest; + +class AssignedQuest +{ +public: + + int mID; //quest ID - unique identifier + int mQuestIndex; //index into quests array for level + int mCurStep; //the current step of the quest that the player is on + long mTimeStepStarted; //time the current step was started + long mTimeStepFinished; //time the previous step was finished + long mTimeQuestStarted; //time the quest was started + long mTimeQuestFinished; //if the quest has been finished, time it was finished +}; + +//manager class for the quests that the player has accepted class QuestManager { public: - static QuestManager* getInstance() - { return &mQuestManager; } + QuestManager(TiXmlElement* node); + void ShowQuestLog() {GameManager::getSingleton().pushState(QuestLogState::getInstance());} -private: + void Load(TiXmlElement* node); + void Save(TiXmlElement* parent); - static QuestManager mQuestManager; + bool AssignQuest(int id, Entity* entity); + bool PlayerHasQuest(int id); + Quest* FindQuest(int id); +private: + std::vector<AssignedQuest> mQuests; + }; #endif /* PC_QUEST_MANAGER_HPP */ Added: trunk/perceptioncrash/src/Quests.hpp =================================================================== --- trunk/perceptioncrash/src/Quests.hpp (rev 0) +++ trunk/perceptioncrash/src/Quests.hpp 2006-06-01 13:10:49 UTC (rev 79) @@ -0,0 +1,25 @@ +#ifndef QUESTS_HPP +#define QUESTS_HPP + +#include <vector> +#include "Quest.hpp" + +class Quest; + +//manager class for all entities in a level +class Quests: public std::vector<Quest> +{ +public: + + static Quests* getInstance() + { return &mQuests; } + +protected: + Quests() { }; + +private: + + static Quests mQuests; + +} +#endif /* QUESTS_HPP */ \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |