You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(136) |
Dec
(218) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(214) |
Feb
(208) |
Mar
(186) |
Apr
(15) |
May
(3) |
Jun
(35) |
Jul
(6) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2005 |
Jan
(1) |
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
(58) |
Aug
(123) |
Sep
(31) |
Oct
(9) |
Nov
|
Dec
(1) |
2006 |
Jan
(25) |
Feb
(10) |
Mar
(25) |
Apr
(61) |
May
|
Jun
(78) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2007 |
Jan
|
Feb
|
Mar
|
Apr
(12) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(10) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
2014 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <you...@us...> - 2004-01-20 07:00:42
|
Update of /cvsroot/timewarp/docs In directory sc8-pr-cvs1:/tmp/cvs-serv19373 Added Files: WebpageDesign.txt Log Message: adding a summary of the new webpage design --- NEW FILE: WebpageDesign.txt --- This doc describes a possible layout of the Timewarp Homepage. 2004.01.20 youBastrd! started NOT DONE YET! Needs: N1. Show the name of the project "Timewarp." Show a short summary (one paragraph) of the game. Show screenshots of what the game looks like. N. Show technical overview of the game (2 player internet/LAN, multiplayer hot seat, gametypes). N2. Allow user to download the software. Allow user to get the latest official release. User should be able to download the latest official release within 1-3 clicks, the fewer clicks, the better. N. USer should be able to find quick solutions to common installation/compilation problems for all supported platforms. (FAQ?) N. Show credits for everyone that has participated in the project. This list must be exhaustive in naming people. Listing each participant's contribution may prove difficult. Show things like contact info, active status, etc N. must link to forums. N. must link to saucecast. N. must show news links. any chance that these can be commented on in the forum? N. Must have banners required by GameSpy, ClassicGaming, Sourceforge N. Must have the following keywords in the text and in the head tag: Star Control, StarCon, Timewarp, Star Control 1, Star Control 2, Star Control 3, Ur-Quan Masters, Space Adventure Game N. N. Wants: W. Overview of the project's history. W. W. W. W. W. Nice to Have: H: H: H: H: H: H: H: H: Solutions: S1. S. S. S. S. S. S. |
From: <you...@us...> - 2004-01-20 05:04:57
|
Update of /cvsroot/timewarp/docs In directory sc8-pr-cvs1:/tmp/cvs-serv1138/docs Modified Files: LuaFullGameTheories.txt Log Message: updating lua theories, this may not get worked on for a while Index: LuaFullGameTheories.txt =================================================================== RCS file: /cvsroot/timewarp/docs/LuaFullGameTheories.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** LuaFullGameTheories.txt 15 Jan 2004 07:27:35 -0000 1.1 --- LuaFullGameTheories.txt 20 Jan 2004 05:04:54 -0000 1.2 *************** *** 5,15 **** N1. the ability to place planets and stars, and to define their positions, orbits, picture(s), techtonics, weather, bio, energy items, etc - N2. Speedy data structures for things like collision detection and gameplay. (TW already does this). This should not be lost if and when a full game is added! ! N3. - N4. There are distinct "Spaces" when the full game is being played. (ie the Sol system is different from the Alpha Centari, even though they are both in Truespace. The point (100,100) in Sol is distinct from the point (100,100) in the Alpha Centari system.) A player should be able to visit one "space," leave to go somewhere else, and the first space should be pretty much the same, but adjusted to show what's changed in the time the player was away. (Do we want a space to ! N. Minimize the number of libraries used (and their sizes), to maximize the number of platforms TW works on (in terms of file size, memory needed and how difficult it is to get a build working). --- 5,25 ---- N1. the ability to place planets and stars, and to define their positions, orbits, picture(s), techtonics, weather, bio, energy items, etc ! N2. Speedy data structures for things like collision detection and gameplay. (TW already does this). This should not be lost when a full game is added! ! N3. Ability to assign actions to events for all objects. That means events like: creation, destruction, collisions, timer events, etc. Ability to run custom event code before the event (which also allows to cancel the event), and after the event. Ability to dispatch events from Lua, either triggering the custom events, or specifically not triggering custom events. see http://java.sun.com/docs/books/tutorial/uiswing/events/ ! N3-1. Where possible, use OO to decide what events are valid for a given object. ! ! ! N4. There are distinct "Spaces" when the full game is being played, they can be run independently. ! ! (ie the Sol system is different from the Alpha Centari, even though they are both in Truespace. The point (100,100) in Sol is distinct from the point (100,100) in the Alpha Centari system.) A player should be able to visit one "space," leave to go somewhere else, and the first space should be pretty much the same, but adjusted to show what's changed in the time the player was away. ! ! ! N5. The code should gracefullly respond to errors. The code should not crash under normal conditions. ! ! ! N6. Minimize the number of libraries used (and their sizes), to maximize the number of platforms TW works on (in terms of file size, memory needed and how difficult it is to get a build working). *************** *** 23,29 **** - Plans: --- ! P1. --- 33,63 ---- ! ! Solutions: --- ! ! S1. Use one of the C++/Lua libraries (toLua or LuaBind) to expose C++ classes to Lua, and vice versa. A reasonable selection of C++ classes should be exposed in this manner. ! ! Pro: ! * maximum versatility. Any C++ class can be subclassed to do whatever is needed. ! ! Con: ! * extra library is needed. ! * no real difference between coding everything in C++, except that the debugging will be harder. ! * May be a security risk to run arbitrary C++ code. May be mitigated by limiting selection of C++ classes, but hiding things like opening files may require shuffling some methods around to non-exposed classes. ! ! ! S2. Make a minimal API in C++, and use the macro lua_register to expose those C++ functions. ! ! Pro: ! * ! ! Con: ! * Will require stack manipulation-type coding to handle parameters in C++. Make a macro for this? How do other projects do this? ! * Will require some clever coding to ! ! ! ! *************** *** 46,50 **** addShip{ species="Ur-quan Kzer-za",shipType="Dreadnaught" } addShip( {} ) ! } } --- 80,84 ---- addShip{ species="Ur-quan Kzer-za",shipType="Dreadnaught" } addShip( {} ) ! end } *************** *** 52,56 **** - http://java.sun.com/docs/books/tutorial/uiswing/events/ --- 86,89 ---- |
From: <yu...@us...> - 2004-01-19 19:15:40
|
Update of /cvsroot/timewarp/gamedata In directory sc8-pr-cvs1:/tmp/cvs-serv23551/gamedata Modified Files: TestQuest.lua Log Message: Pkunk test quest added Index: TestQuest.lua =================================================================== RCS file: /cvsroot/timewarp/gamedata/TestQuest.lua,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** TestQuest.lua 17 Jan 2004 22:47:23 -0000 1.3 --- TestQuest.lua 19 Jan 2004 19:15:37 -0000 1.4 *************** *** 8,19 **** function GAME_EVENT_SHIP_DIE( Type ) if Type == "shosc" then shoscKilled = shoscKilled - 1 end ! if shoscLilled == 0 then Complited = 1 end end ! function GAME_EVENT_VISIT_LOCATION( locationID ) ! if locationID == QuestSourceLocationID then if Complited == 1 then return Reward() end return HurryLazyPlayer() ! end end --- 8,20 ---- function GAME_EVENT_SHIP_DIE( Type ) if Type == "shosc" then shoscKilled = shoscKilled - 1 end ! if shoscKilled == 0 then Complited = 1 end end ! function GAME_EVENT_ENTER_STATION( locationID ) ! if allready_get_reward == 1 then return end ! -- if locationID == QuestSourceLocationID then if Complited == 1 then return Reward() end return HurryLazyPlayer() ! -- end end *************** *** 22,25 **** --- 23,28 ---- DialogWrite "Congratulations, those bastards are all dead now! Take 20 bucks" answer = DialogAnswer ( "Thanks!" ) + AddBuckazoids(20); + allready_get_reward = 1; DialogEnd() end *************** *** 35,59 **** DialogStart "gamedata/pkunk-standing.bmp" function question1() ! DialogWrite "Hello, my spiritual child. I have no quest for you yet" ! answer = DialogAnswer("But I am realy need one!", ! "Lets just talk a bit!!!", ! "bye") if answer == 1 then return question2() end if answer == 2 then return question3() end - if answer == 3 then return DialogWrite "Bye" end end function question2() ! DialogWrite "Sorry, this part of game is on very early development stage. But don't lose hope :)" ! answer = DialogAnswer("Ok, lets just talk then", "Bye") if answer == 1 then return question3() end - if answer == 2 then return DialogWrite "Bye" end end function question3() ! DialogWrite "And what are we doing now?" ! answer = DialogAnswer ("Testing!!!", "Bye") ! if answer == 1 then return DialogWrite ("Booring..."); end ! if answer == 2 then return question1() end end --- 38,58 ---- DialogStart "gamedata/pkunk-standing.bmp" function question1() ! DialogWrite "Hello, my spiritual child. I kill Shofixti Scout for me." ! answer = DialogAnswer("Why?", ! "I agree") if answer == 1 then return question2() end if answer == 2 then return question3() end end function question2() ! DialogWrite "They influence badly on our Ye-hat brothers" ! answer = DialogAnswer("I agree") if answer == 1 then return question3() end end function question3() ! DialogWrite "What are you waiting for?" ! answer = DialogAnswer ("Bye") ! if answer == 1 then return DialogWrite ("Bye"); end end |
From: <yu...@us...> - 2004-01-19 19:15:40
|
Update of /cvsroot/timewarp/source/games In directory sc8-pr-cvs1:/tmp/cvs-serv23551/source/games Modified Files: ggob.cpp Log Message: Pkunk test quest added Index: ggob.cpp =================================================================== RCS file: /cvsroot/timewarp/source/games/ggob.cpp,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** ggob.cpp 17 Jan 2004 22:47:22 -0000 1.18 --- ggob.cpp 19 Jan 2004 19:15:37 -0000 1.19 *************** *** 812,815 **** --- 812,821 ---- game->window->x,game->window->y,game->window->w, game->window->h); game->window->unlock(); + + EventEnterStation e; + e.player = s; + e.station = this; + gobgame->GenerateEvent(&e); + while (true) { sprintf(dialog_string[0], "%03d Starbucks %03d Buckazoids", s->starbucks, s->buckazoids); *************** *** 894,897 **** --- 900,904 ---- GobPlayer *p = gobgame->get_player(other); if (!p) return; + gobgame->pause(); char buffy[256]; |
From: <yu...@us...> - 2004-01-19 19:15:40
|
Update of /cvsroot/timewarp/source/other In directory sc8-pr-cvs1:/tmp/cvs-serv23551/source/other Modified Files: gevent.cpp gevent.h gquest.cpp gquest.h Log Message: Pkunk test quest added Index: gevent.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gevent.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** gevent.cpp 17 Jan 2004 22:47:22 -0000 1.3 --- gevent.cpp 19 Jan 2004 19:15:37 -0000 1.4 *************** *** 29,32 **** --- 29,38 ---- return GAME_EVENT_SHIP_GET_DAMAGE; } + + unsigned int EventEnterStation::GetEventType() + { + return GAME_EVENT_ENTER_STATION; + } + EventListner::EventListner() { Index: gevent.h =================================================================== RCS file: /cvsroot/timewarp/source/other/gevent.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** gevent.h 17 Jan 2004 22:47:22 -0000 1.3 --- gevent.h 19 Jan 2004 19:15:37 -0000 1.4 *************** *** 15,18 **** --- 15,19 ---- class Ship; class GobPlayer; + class GobStation; enum EventTypes *************** *** 21,24 **** --- 22,26 ---- GAME_EVENT_SHIP_DIE, GAME_EVENT_SHIP_GET_DAMAGE, + GAME_EVENT_ENTER_STATION, }; *************** *** 41,48 **** class EventShipGetDamage: public IEvent { ! Ship * s; ! int total; ! public: ! virtual unsigned int GetEventType(); }; --- 43,60 ---- class EventShipGetDamage: public IEvent { ! public: ! Ship * ship; ! int total; ! ! virtual unsigned int GetEventType(); ! }; ! ! class EventEnterStation: public IEvent ! { ! public: ! GobStation* station; ! GobPlayer* player; ! ! virtual unsigned int GetEventType(); }; Index: gquest.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** gquest.cpp 17 Jan 2004 22:47:22 -0000 1.7 --- gquest.cpp 19 Jan 2004 19:15:37 -0000 1.8 *************** *** 26,37 **** // Register C function ! lua_register(L, "Dialog", l_Dialog); ! lua_register(L, "AddObject", l_AddObject); ! lua_register(L, "RemoveObject", l_RemoveObject); // Load Quest lua_dofile(L, szLuaFile); // Register Events ! RegisterEvent(GAME_EVENT_SHIP_DIE, gobgame); } --- 26,57 ---- // Register C function ! lua_register(L, "Dialog", l_Dialog); ! lua_register(L, "AddObject", l_AddObject); ! lua_register(L, "RemoveObject", l_RemoveObject); ! lua_register(L, "AddBuckazoids", l_AddBuckazoids); ! // Load Quest lua_dofile(L, szLuaFile); + // Register Events + int top = lua_gettop(L); ! lua_pushstring(L, "GAME_EVENT_SHIP_DIE"); ! lua_gettable ( L, LUA_GLOBALSINDEX ); ! if ( lua_isfunction(L, -1) ) ! RegisterEvent(GAME_EVENT_SHIP_DIE, gobgame); ! lua_settop(L, top); ! ! lua_pushstring(L, "GAME_EVENT_SHIP_GET_DAMAGE"); ! lua_gettable ( L, LUA_GLOBALSINDEX ); ! if ( lua_isfunction(L, -1) ) ! RegisterEvent(GAME_EVENT_SHIP_GET_DAMAGE, gobgame); ! lua_settop(L, top); ! ! lua_pushstring(L, "GAME_EVENT_ENTER_STATION"); ! lua_gettable ( L, LUA_GLOBALSINDEX ); ! if ( lua_isfunction(L, -1) ) ! RegisterEvent(GAME_EVENT_ENTER_STATION, gobgame); ! lua_settop(L, top); } *************** *** 96,99 **** --- 116,120 ---- lua_settop(L, top); + g_player = NULL; return; } *************** *** 101,106 **** --- 122,129 ---- void Quest::ProcessEvent ( IEvent* event ) { + g_player = gob_player; int type = event->GetEventType(); int top; + const char * temp; switch ( type ) { *************** *** 119,123 **** tw_error("Quest script is not contain GAME_EVENT_SHIP_DIE function"); }; ! lua_pushstring( L, ((EventShipDie*)event)->victim->get_shiptype() -> id ); //reserved --- 142,146 ---- tw_error("Quest script is not contain GAME_EVENT_SHIP_DIE function"); }; ! temp = ((EventShipDie*)event)->victim->get_shiptype() -> id; lua_pushstring( L, ((EventShipDie*)event)->victim->get_shiptype() -> id ); //reserved *************** *** 127,138 **** case GAME_EVENT_SHIP_GET_DAMAGE: break; default: break; } } int Quest::l_Dialog(lua_State* ls) { ! return 0; } --- 150,179 ---- case GAME_EVENT_SHIP_GET_DAMAGE: break; + case GAME_EVENT_ENTER_STATION: + // Test Implementation + top = lua_gettop(L); + lua_pushstring ( L, "GAME_EVENT_ENTER_STATION" ); + lua_gettable ( L, LUA_GLOBALSINDEX ); + + if ( !lua_isfunction(L, -1) ) + { + tw_error("Quest script is not contain GAME_EVENT_ENTER_STATION function"); + }; + + lua_pushnumber( L, 1 ); //need to be implemented + + lua_call(L, 1, 0 ); + lua_settop(L, top); + + break; default: break; } + g_player = NULL; } int Quest::l_Dialog(lua_State* ls) { ! return NOT_IMPLEMENTED; } *************** *** 140,149 **** { gobgame->add_new_enemy(); ! return 0; } int Quest::l_RemoveObject(lua_State* ls) { ! return 0; } --- 181,201 ---- { gobgame->add_new_enemy(); ! return NOT_IMPLEMENTED; } int Quest::l_RemoveObject(lua_State* ls) { ! return NOT_IMPLEMENTED; ! } ! int Quest::l_AddBuckazoids(lua_State*ls) ! { ! int top = lua_gettop(ls); ! if ( top != 1 ) ! { ! tw_error ("Wrong argument count for AddBuckazoids"); ! } ! int money = lua_tonumber(ls, -1); ! g_player->buckazoids += money; ! return 0; } Index: gquest.h =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** gquest.h 17 Jan 2004 01:56:49 -0000 1.4 --- gquest.h 19 Jan 2004 19:15:37 -0000 1.5 *************** *** 39,42 **** --- 39,44 ---- /*! \brief Remove quest object ( ship, starbase ... ) */ static int l_RemoveObject(lua_State*ls); + /*! \brief Add buckazoids */ + static int l_AddBuckazoids(lua_State*ls); }; |
From: <yu...@us...> - 2004-01-17 22:47:26
|
Update of /cvsroot/timewarp In directory sc8-pr-cvs1:/tmp/cvs-serv21362 Modified Files: twwin.dsp Added Files: twwin.sln twwin.vcproj Log Message: Adding VS.NET project file, sources modified a bit to compile with this compiler --- NEW FILE: twwin.vcproj --- <?xml version="1.0" encoding="windows-1251"?> <VisualStudioProject ProjectType="Visual C++" Version="7.10" Name="twwin" SccProjectName="" SccLocalPath=""> <Platforms> <Platform Name="Win32"/> </Platforms> <Configurations> <Configuration Name="Release|Win32" OutputDirectory=".\Release" IntermediateDirectory=".\Release" ConfigurationType="1" UseOfMFC="0" ATLMinimizesCRunTimeLibraryUsage="FALSE" [...6269 lines suppressed...] Filter=""> <File RelativePath="include\jgmod.h"> </File> </Filter> </Filter> <Filter Name="Resource Files" Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"> <File RelativePath="scpwin.ico"> </File> <File RelativePath="scpwin.rc"> </File> </Filter> </Files> <Globals> </Globals> </VisualStudioProject> Index: twwin.dsp =================================================================== RCS file: /cvsroot/timewarp/twwin.dsp,v retrieving revision 1.56 retrieving revision 1.57 diff -C2 -d -r1.56 -r1.57 *** twwin.dsp 17 Jan 2004 01:56:49 -0000 1.56 --- twwin.dsp 17 Jan 2004 22:47:23 -0000 1.57 *************** *** 71,76 **** # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c ! # ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Op /I "./include" /I "./source" /I "./source/gamex" /D "_DEBUG" /D "DEBUGMODE" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "__i386__" /YX /FD /GZ /c ! # SUBTRACT CPP /Fr # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 --- 71,75 ---- # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c ! # ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Op /I "./include" /I "./source" /I "./source/gamex" /D "_DEBUG" /D "DEBUGMODE" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "__i386__" /Fr /YX /FD /GZ /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 |
From: <yu...@us...> - 2004-01-17 22:47:26
|
Update of /cvsroot/timewarp/source/twgui In directory sc8-pr-cvs1:/tmp/cvs-serv21362/source/twgui Modified Files: twbutton.cpp twgui.cpp Log Message: Adding VS.NET project file, sources modified a bit to compile with this compiler Index: twbutton.cpp =================================================================== RCS file: /cvsroot/timewarp/source/twgui/twbutton.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** twbutton.cpp 13 Jan 2004 01:15:24 -0000 1.3 --- twbutton.cpp 17 Jan 2004 22:47:23 -0000 1.4 *************** *** 521,525 **** int L = 0; ! int Ltotal = 5 * sqrt( bmpref->w * bmpref->h ); double phase = mainwindow->menu_time * 1E-3 * PI; //offset angle --- 521,525 ---- int L = 0; ! int Ltotal = 5 * sqrt( (double)bmpref->w * bmpref->h ); double phase = mainwindow->menu_time * 1E-3 * PI; //offset angle Index: twgui.cpp =================================================================== RCS file: /cvsroot/timewarp/source/twgui/twgui.cpp,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** twgui.cpp 13 Jan 2004 01:15:24 -0000 1.17 --- twgui.cpp 17 Jan 2004 22:47:23 -0000 1.18 *************** *** 939,943 **** // create the most "optimal" square map (minimum x,y positions means least search trouble (I think)). ! Nx = iround( sqrt(maxitems) ); Ny = maxitems/Nx + 1; --- 939,943 ---- // create the most "optimal" square map (minimum x,y positions means least search trouble (I think)). ! Nx = iround( sqrt((double)maxitems) ); Ny = maxitems/Nx + 1; |
From: <yu...@us...> - 2004-01-17 22:47:26
|
Update of /cvsroot/timewarp/gamedata In directory sc8-pr-cvs1:/tmp/cvs-serv21362/gamedata Modified Files: TestQuest.lua Log Message: Adding VS.NET project file, sources modified a bit to compile with this compiler Index: TestQuest.lua =================================================================== RCS file: /cvsroot/timewarp/gamedata/TestQuest.lua,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** TestQuest.lua 17 Jan 2004 01:56:49 -0000 1.2 --- TestQuest.lua 17 Jan 2004 22:47:23 -0000 1.3 *************** *** 1,19 **** ! Complited = 0; function Process(time, enemy, kills, x, y, res_num1, res_num2, res_str) - --AddObject(); - a = 1; - b = 2; - c = a + b; end ! function GAME_EVENT_SHIP_DIE() DialogStart "gamedata/pkunk-standing.bmp" ! DialogWrite "Somebody is dead now" ! answer = DialogAnswer("It doesn't matter!", ! "bye") DialogEnd() end DialogStart "gamedata/pkunk-standing.bmp" function question1() --- 1,36 ---- ! Complited = 0; -- Quest complitted ! shoscKilled = 1; -- Shofixti Scout you need to kill ! allready_get_reward = 0; function Process(time, enemy, kills, x, y, res_num1, res_num2, res_str) end ! function GAME_EVENT_SHIP_DIE( Type ) ! if Type == "shosc" then shoscKilled = shoscKilled - 1 end ! if shoscLilled == 0 then Complited = 1 end ! end ! ! function GAME_EVENT_VISIT_LOCATION( locationID ) ! if locationID == QuestSourceLocationID then ! if Complited == 1 then return Reward() end ! return HurryLazyPlayer() ! end ! end ! ! function Reward() DialogStart "gamedata/pkunk-standing.bmp" ! DialogWrite "Congratulations, those bastards are all dead now! Take 20 bucks" ! answer = DialogAnswer ( "Thanks!" ) DialogEnd() end + function HurryLazyPlayer() + DialogStart "gamedata/pkunk-standing.bmp" + DialogWrite "Hurry, they are criminals!" + answer = DialogAnswer ( "I am off!!!" ) + DialogEnd() + end + + DialogStart "gamedata/pkunk-standing.bmp" function question1() |
From: <yu...@us...> - 2004-01-17 22:47:26
|
Update of /cvsroot/timewarp/source/newships In directory sc8-pr-cvs1:/tmp/cvs-serv21362/source/newships Modified Files: shpmekpi.cpp shpquawr.cpp shpsefna.cpp Log Message: Adding VS.NET project file, sources modified a bit to compile with this compiler Index: shpmekpi.cpp =================================================================== RCS file: /cvsroot/timewarp/source/newships/shpmekpi.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** shpmekpi.cpp 13 Jan 2004 01:15:28 -0000 1.11 --- shpmekpi.cpp 17 Jan 2004 22:47:23 -0000 1.12 *************** *** 156,160 **** add(new LaserInform(this, angle + da, ! makecol(128,0,64), weaponRange / (1+fabs(i)), weaponDamage, weapon_rate, this, rpos, true)); } --- 156,160 ---- add(new LaserInform(this, angle + da, ! makecol(128,0,64), weaponRange / (1+fabs((double)i)), weaponDamage, weapon_rate, this, rpos, true)); } Index: shpquawr.cpp =================================================================== RCS file: /cvsroot/timewarp/source/newships/shpquawr.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** shpquawr.cpp 13 Jan 2004 01:15:28 -0000 1.11 --- shpquawr.cpp 17 Jan 2004 22:47:23 -0000 1.12 *************** *** 316,322 **** if (d_a > PI) d_a -= PI2; if (d_a > 0) ! angle += (ANGLE_RATIO * aiming + ANGLE_RATIO * dispersion*(-50+random()%101) / sqrt(frame_time)) * frame_time / 100.0; else ! angle -= (ANGLE_RATIO * aiming + ANGLE_RATIO * dispersion*(-50+random()%101) / sqrt(frame_time)) * frame_time / 100.0; if (!target->exists()) target = NULL; return; --- 316,322 ---- if (d_a > PI) d_a -= PI2; if (d_a > 0) ! angle += (ANGLE_RATIO * aiming + ANGLE_RATIO * dispersion*(-50+random()%101) / sqrt((double)frame_time)) * frame_time / 100.0; else ! angle -= (ANGLE_RATIO * aiming + ANGLE_RATIO * dispersion*(-50+random()%101) / sqrt((double)frame_time)) * frame_time / 100.0; if (!target->exists()) target = NULL; return; Index: shpsefna.cpp =================================================================== RCS file: /cvsroot/timewarp/source/newships/shpsefna.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** shpsefna.cpp 13 Jan 2004 01:15:28 -0000 1.11 --- shpsefna.cpp 17 Jan 2004 22:47:23 -0000 1.12 *************** *** 551,555 **** // simulate visibility of a glittering line in the sun ... double a, colscale; ! a = atan2(dy,dx); colscale = fabs(sin(a)); // flat lying = less visible. --- 551,555 ---- // simulate visibility of a glittering line in the sun ... double a, colscale; ! a = atan2((double)dy,(double)dx); colscale = fabs(sin(a)); // flat lying = less visible. |
From: <yu...@us...> - 2004-01-17 22:47:26
|
Update of /cvsroot/timewarp/source/melee In directory sc8-pr-cvs1:/tmp/cvs-serv21362/source/melee Modified Files: mcbodies.cpp mframe.cpp mview.cpp Log Message: Adding VS.NET project file, sources modified a bit to compile with this compiler Index: mcbodies.cpp =================================================================== RCS file: /cvsroot/timewarp/source/melee/mcbodies.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** mcbodies.cpp 13 Jan 2004 01:15:25 -0000 1.8 --- mcbodies.cpp 17 Jan 2004 22:47:22 -0000 1.9 *************** *** 500,504 **** w, h, w, h, ! d + d*fabs(50-(((game->game_time / 10 + layer * 70)) % 100)) / 100.0, seed + layer, aa_mode --- 500,504 ---- w, h, w, h, ! d + d*fabs(50.0-(((game->game_time / 10 + layer * 70)) % 100)) / 100.0, seed + layer, aa_mode *************** *** 515,519 **** w, h, w, h, ! d + d*fabs(50-(((game->game_time / 10 + layer * 70)) % 100)) / 100.0, seed + layer, aa_mode & 0x7fffFFFF --- 515,519 ---- w, h, w, h, ! d + d*fabs(50.0-(((game->game_time / 10 + layer * 70)) % 100)) / 100.0, seed + layer, aa_mode & 0x7fffFFFF Index: mframe.cpp =================================================================== RCS file: /cvsroot/timewarp/source/melee/mframe.cpp,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** mframe.cpp 13 Jan 2004 01:15:25 -0000 1.21 --- mframe.cpp 17 Jan 2004 22:47:23 -0000 1.22 *************** *** 505,509 **** double Presence::get_depth() {STACKTRACE ! return ldexp(_depth, -8); } --- 505,509 ---- double Presence::get_depth() {STACKTRACE ! return ldexp((double)_depth, -8); } *************** *** 1353,1358 **** Vector2 n = item[i]->normal_pos(); ! g += iround(n.x * sqrt(47+i+g)); ! g += iround(n.y * sqrt(71+i+g)); //g += g * item[i]->get_vy() * sqrt(73+i+g/32768.0); //g -= g * item[i]->get_vx() * sqrt(1+i+g/65536.0); --- 1353,1358 ---- Vector2 n = item[i]->normal_pos(); ! g += iround(n.x * sqrt(47.0+i+g)); ! g += iround(n.y * sqrt(71.0+i+g)); //g += g * item[i]->get_vy() * sqrt(73+i+g/32768.0); //g -= g * item[i]->get_vx() * sqrt(1+i+g/65536.0); Index: mview.cpp =================================================================== RCS file: /cvsroot/timewarp/source/melee/mview.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** mview.cpp 13 Jan 2004 01:15:26 -0000 1.13 --- mview.cpp 17 Jan 2004 22:47:23 -0000 1.14 *************** *** 120,124 **** double tz = magnitude(view_size) / 1.41421356237309504880168872; ::space_zoom = tz / camera.z; ! ::space_mip = -log(space_zoom) / log(2); ::space_mip_i = iround_down(::space_mip); ::space_size = view_size * space_zoom; --- 120,124 ---- double tz = magnitude(view_size) / 1.41421356237309504880168872; ::space_zoom = tz / camera.z; ! ::space_mip = -log(space_zoom) / log(2.0); ::space_mip_i = iround_down(::space_mip); ::space_size = view_size * space_zoom; *************** *** 582,586 **** double ref_size = 480; ! n.z = ref_size * pow(2, ceil(log(n.z/ref_size) / log(2))); track(n); return; --- 582,586 ---- double ref_size = 480; ! n.z = ref_size * pow( 2, iround( ceil(log(n.z/ref_size) / log(2.0))) ); track(n); return; |
From: <yu...@us...> - 2004-01-17 22:47:25
|
Update of /cvsroot/timewarp/source/games In directory sc8-pr-cvs1:/tmp/cvs-serv21362/source/games Modified Files: ggob.cpp gplexplr.cpp Log Message: Adding VS.NET project file, sources modified a bit to compile with this compiler Index: ggob.cpp =================================================================== RCS file: /cvsroot/timewarp/source/games/ggob.cpp,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** ggob.cpp 17 Jan 2004 15:42:39 -0000 1.17 --- ggob.cpp 17 Jan 2004 22:47:22 -0000 1.18 *************** *** 1,6 **** ! //#include <stdlib.h> ! //#include <string.h> ! //#include <stdio.h> #include <allegro.h> --- 1,6 ---- ! #include <stdlib.h> ! #include <string.h> ! #include <stdio.h> #include <allegro.h> *************** *** 407,410 **** --- 407,412 ---- EventShipDie esd; + esd.victim = who; + esd.player_killer = get_player(source); gobgame->GenerateEvent(&esd); *************** *** 434,437 **** --- 436,442 ---- GobPlayer *GobGame::get_player(SpaceLocation *what) { STACKTRACE + + if ( what == NULL ) + return NULL; int i; *************** *** 484,488 **** if (e < pow(2.5*base,0.4) - 1) e = random() % num_enemy_types; ! if (e > sqrt(3*base) + 2) e = random() % (e + 1); //if (e > num_enemy_types * 2) e = e % num_enemy_types; --- 489,493 ---- if (e < pow(2.5*base,0.4) - 1) e = random() % num_enemy_types; ! if (e > sqrt( 3.0*base) + 2) e = random() % (e + 1); //if (e > num_enemy_types * 2) e = e % num_enemy_types; Index: gplexplr.cpp =================================================================== RCS file: /cvsroot/timewarp/source/games/gplexplr.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** gplexplr.cpp 13 Jan 2004 01:15:24 -0000 1.10 --- gplexplr.cpp 17 Jan 2004 22:47:22 -0000 1.11 *************** *** 475,479 **** ::space_view_size = view_size; ::space_zoom = 1.0; ! ::space_mip = -log(space_zoom) / log(2); ::space_mip_i = iround_down(::space_mip); ::space_size = view_size * space_zoom; --- 475,479 ---- ::space_view_size = view_size; ::space_zoom = 1.0; ! ::space_mip = -log(space_zoom) / log(2.0); ::space_mip_i = iround_down(::space_mip); ::space_size = view_size * space_zoom; |
From: <yu...@us...> - 2004-01-17 22:47:25
|
Update of /cvsroot/timewarp/source/other In directory sc8-pr-cvs1:/tmp/cvs-serv21362/source/other Modified Files: gevent.cpp gevent.h gquest.cpp Log Message: Adding VS.NET project file, sources modified a bit to compile with this compiler Index: gevent.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gevent.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gevent.cpp 17 Jan 2004 15:42:39 -0000 1.2 --- gevent.cpp 17 Jan 2004 22:47:22 -0000 1.3 *************** *** 13,16 **** --- 13,22 ---- + EventShipDie::EventShipDie() + { + victim = NULL; // ship + player_killer = NULL; + } + unsigned int EventShipDie::GetEventType() { *************** *** 18,21 **** --- 24,28 ---- }; + unsigned int EventShipGetDamage::GetEventType() { Index: gevent.h =================================================================== RCS file: /cvsroot/timewarp/source/other/gevent.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gevent.h 17 Jan 2004 15:42:39 -0000 1.2 --- gevent.h 17 Jan 2004 22:47:22 -0000 1.3 *************** *** 14,17 **** --- 14,18 ---- class Ship; + class GobPlayer; enum EventTypes *************** *** 30,35 **** class EventShipDie : public IEvent { - Ship * s; public: virtual unsigned int GetEventType(); }; --- 31,39 ---- class EventShipDie : public IEvent { public: + EventShipDie(); + + Ship * victim; + GobPlayer * player_killer; virtual unsigned int GetEventType(); }; Index: gquest.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** gquest.cpp 17 Jan 2004 15:42:39 -0000 1.6 --- gquest.cpp 17 Jan 2004 22:47:22 -0000 1.7 *************** *** 111,116 **** // Test Implementation top = lua_gettop(L); ! lua_pushstring(L, "GAME_EVENT_SHIP_DIE"); ! lua_gettable(L, LUA_GLOBALSINDEX); --- 111,116 ---- // Test Implementation top = lua_gettop(L); ! lua_pushstring ( L, "GAME_EVENT_SHIP_DIE" ); ! lua_gettable ( L, LUA_GLOBALSINDEX ); *************** *** 119,123 **** tw_error("Quest script is not contain GAME_EVENT_SHIP_DIE function"); }; ! lua_call(L, 0, 0 ); lua_settop(L, top); break; --- 119,126 ---- tw_error("Quest script is not contain GAME_EVENT_SHIP_DIE function"); }; ! ! lua_pushstring( L, ((EventShipDie*)event)->victim->get_shiptype() -> id ); //reserved ! ! lua_call(L, 1, 0 ); lua_settop(L, top); break; |
From: <yu...@us...> - 2004-01-17 15:42:43
|
Update of /cvsroot/timewarp/source In directory sc8-pr-cvs1:/tmp/cvs-serv27007/source Modified Files: scp.cpp Log Message: Removed tons of warnings for MSVC compiler Index: scp.cpp =================================================================== RCS file: /cvsroot/timewarp/source/scp.cpp,v retrieving revision 1.34 retrieving revision 1.35 diff -C2 -d -r1.34 -r1.35 *** scp.cpp 12 Jan 2004 23:24:51 -0000 1.34 --- scp.cpp 17 Jan 2004 15:42:39 -0000 1.35 *************** *** 24,27 **** --- 24,31 ---- #include <allegro.h> + #ifdef ALLEGRO_MSVC + #pragma warning (disable:4786) + #endif + #ifdef WIN32 #include <allegro/platform/aintwin.h> |
From: <yu...@us...> - 2004-01-17 15:42:43
|
Update of /cvsroot/timewarp/source/other In directory sc8-pr-cvs1:/tmp/cvs-serv27007/source/other Modified Files: gdialog.cpp gevent.cpp gevent.h gquest.cpp gup.cpp Log Message: Removed tons of warnings for MSVC compiler Index: gdialog.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gdialog.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gdialog.cpp 14 Jan 2004 11:12:32 -0000 1.2 --- gdialog.cpp 17 Jan 2004 15:42:39 -0000 1.3 *************** *** 7,10 **** --- 7,14 ---- #include <allegro.h> + #ifdef ALLEGRO_MSVC + #pragma warning (disable:4786) + #endif + #include "gdialog.h" #include "games/ggob.h" Index: gevent.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gevent.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** gevent.cpp 17 Jan 2004 14:55:21 -0000 1.1 --- gevent.cpp 17 Jan 2004 15:42:39 -0000 1.2 *************** *** 1,2 **** --- 1,8 ---- + #include <allegro.h> + + #ifdef ALLEGRO_MSVC + #pragma warning (disable:4786) + #endif + #include "gevent.h" Index: gevent.h =================================================================== RCS file: /cvsroot/timewarp/source/other/gevent.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** gevent.h 17 Jan 2004 14:55:21 -0000 1.1 --- gevent.h 17 Jan 2004 15:42:39 -0000 1.2 *************** *** 13,17 **** - class Ship; --- 13,16 ---- Index: gquest.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** gquest.cpp 17 Jan 2004 14:55:21 -0000 1.5 --- gquest.cpp 17 Jan 2004 15:42:39 -0000 1.6 *************** *** 1,2 **** --- 1,7 ---- + #include <allegro.h> + + #ifdef ALLEGRO_MSVC + #pragma warning (disable:4786) + #endif #include "games/ggob.h" Index: gup.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gup.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** gup.cpp 13 Jan 2004 01:15:25 -0000 1.7 --- gup.cpp 17 Jan 2004 15:42:39 -0000 1.8 *************** *** 1,4 **** --- 1,9 ---- #include <string.h> #include <allegro.h> + + #ifdef ALLEGRO_MSVC + #pragma warning (disable:4786) + #endif + #include "melee.h" REGISTER_FILE |
From: <yu...@us...> - 2004-01-17 15:42:42
|
Update of /cvsroot/timewarp/source/games In directory sc8-pr-cvs1:/tmp/cvs-serv27007/source/games Modified Files: dialog.cpp ggob.cpp Log Message: Removed tons of warnings for MSVC compiler Index: dialog.cpp =================================================================== RCS file: /cvsroot/timewarp/source/games/dialog.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** dialog.cpp 13 Jan 2004 01:15:23 -0000 1.4 --- dialog.cpp 17 Jan 2004 15:42:39 -0000 1.5 *************** *** 8,11 **** --- 8,16 ---- #include <allegro.h> + + #ifdef ALLEGRO_MSVC + #pragma warning (disable:4786) + #endif + #include "dialog.h" #include "util/aautil.h" Index: ggob.cpp =================================================================== RCS file: /cvsroot/timewarp/source/games/ggob.cpp,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** ggob.cpp 17 Jan 2004 01:56:48 -0000 1.16 --- ggob.cpp 17 Jan 2004 15:42:39 -0000 1.17 *************** *** 1,9 **** ! #include <stdlib.h> ! #include <string.h> ! #include <stdio.h> #include <allegro.h> #include "melee.h" REGISTER_FILE --- 1,13 ---- ! //#include <stdlib.h> ! //#include <string.h> ! //#include <stdio.h> #include <allegro.h> + #ifdef ALLEGRO_MSVC + #pragma warning (disable:4786) + #endif + #include "melee.h" REGISTER_FILE |
From: <yu...@us...> - 2004-01-17 14:56:39
|
Update of /cvsroot/timewarp/docs In directory sc8-pr-cvs1:/tmp/cvs-serv19098/docs Modified Files: faq.html Log Message: no message Index: faq.html =================================================================== RCS file: /cvsroot/timewarp/docs/faq.html,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** faq.html 16 Aug 2003 21:43:27 -0000 1.1 --- faq.html 17 Jan 2004 14:56:36 -0000 1.2 *************** *** 134,137 **** --- 134,139 ---- <h2>How to Report Bugs</h2> <pre> + You can use our <a href="http://bugs.cs.iupui.edu/cgi-bin/bugzilla/">Bugzilla Bug-Tracking Systems</a> + If you find a bug not listed here, post to this chat board: http://dynamic.gamespy.com/~starcontrol/boards/timewarp/ |
From: <yu...@us...> - 2004-01-17 14:55:26
|
Update of /cvsroot/timewarp/source/other In directory sc8-pr-cvs1:/tmp/cvs-serv18903 Modified Files: gquest.cpp Added Files: gevent.cpp gevent.h Log Message: Game event fix --- NEW FILE: gevent.cpp --- #include "gevent.h" //#include "games/ggob.h" #include "melee.h" REGISTER_FILE #include "melee/mship.h" unsigned int EventShipDie::GetEventType() { return GAME_EVENT_SHIP_DIE; }; unsigned int EventShipGetDamage::GetEventType() { return GAME_EVENT_SHIP_GET_DAMAGE; } EventListner::EventListner() { } /*! \brief Remove self from various EventHandlers */ EventListner::~EventListner() { for ( EventHandlerList::iterator Ihl = event_handlers.begin(); Ihl != event_handlers.end(); Ihl++) { (*Ihl)->UnRegisterEvent( GAME_EVENT_ALL, this ); } } /*! \brief Used by EventHandler destructor */ void EventListner::RemoveEventHandler( EventHandler * eh ) { eh->UnRegisterEvent ( GAME_EVENT_ALL, this ); event_handlers.erase(eh); } void EventListner::RegisterEvent( int type, EventHandler * eh ) { eh->RegisterEvent ( type, this ); event_handlers.insert( eh ); } EventHandler::~EventHandler() { EventListnersList temp = listners; for (EventListnersList::iterator ill = temp.begin(); ill != temp.end(); ill++) { ill->first->RemoveEventHandler( this ); } } /*! \Trigger event \param event Information about event */ void EventHandler::GenerateEvent ( IEvent* event ) { int type = event->GetEventType(); for ( EventListnersList::iterator ill = listners.begin(); ill != listners.end(); ill++ ) { if ( std::find ( (ill->second).begin(), (ill->second).end(), type ) != (ill->second).end() ) { (ill->first)->ProcessEvent ( event ); } } } /*! \brief Add listner \param type Event type listner want to be get \param listner pointer */ void EventHandler::RegisterEvent ( int type, EventListner * listner ) { std::set<int> s = listners[listner]; s.insert(type); listners.erase(listner); listners[listner] = s; }; /*! \brief Remove listner \param type Event type listner doesn't want to get \param listner pointer */ void EventHandler::UnRegisterEvent ( int type, EventListner * listner ) { std::set<int> s = listners[listner]; if ( type == GAME_EVENT_ALL ) { listners.erase(listner); } else { s.erase( type ); listners.erase(listner); listners[listner] = s; } } --- NEW FILE: gevent.h --- #ifndef __GEVENT_H__ #define __GEVENT_H__ #include <utility> #include <functional> #include <memory> #include <list> #include <string> #include <map> #include <set> #include <iterator> #include <algorithm> class Ship; enum EventTypes { GAME_EVENT_ALL = 0, GAME_EVENT_SHIP_DIE, GAME_EVENT_SHIP_GET_DAMAGE, }; class IEvent { public: virtual unsigned int GetEventType() = 0; }; class EventShipDie : public IEvent { Ship * s; public: virtual unsigned int GetEventType(); }; class EventShipGetDamage: public IEvent { Ship * s; int total; public: virtual unsigned int GetEventType(); }; class EventHandler; typedef std::set<EventHandler*> EventHandlerList; class EventListner { protected: EventHandlerList event_handlers; public: EventListner(); virtual ~EventListner(); virtual void ProcessEvent( IEvent* event ) = 0; void RemoveEventHandler(EventHandler * eh); void RegisterEvent( int type, EventHandler * eh ); }; typedef std::map<EventListner*, std::set<int> > EventListnersList; /*! \brief Gather event from various sources, and pass them to event listrens */ class EventHandler { protected: EventListnersList listners; public: virtual ~EventHandler(); virtual void GenerateEvent( IEvent* event); virtual void RegisterEvent( int type, EventListner * listner ); virtual void UnRegisterEvent (int type, EventListner * listner ); }; #endif // __GEVENT_H__ Index: gquest.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** gquest.cpp 17 Jan 2004 01:56:49 -0000 1.4 --- gquest.cpp 17 Jan 2004 14:55:21 -0000 1.5 *************** *** 27,31 **** lua_dofile(L, szLuaFile); // Register Events ! gobgame->RegisterEvent(GAME_EVENT_SHIP_DIE, this); } --- 27,32 ---- lua_dofile(L, szLuaFile); // Register Events ! ! RegisterEvent(GAME_EVENT_SHIP_DIE, gobgame); } |
From: <yu...@us...> - 2004-01-17 01:56:52
|
Update of /cvsroot/timewarp In directory sc8-pr-cvs1:/tmp/cvs-serv3469 Modified Files: twwin.dsp Log Message: Events support for GOB, VS now generate a lot of warnings, need to get rid |
From: <yu...@us...> - 2004-01-17 01:56:52
|
Update of /cvsroot/timewarp/gamedata In directory sc8-pr-cvs1:/tmp/cvs-serv3469/gamedata Modified Files: TestQuest.lua Log Message: Events support for GOB, VS now generate a lot of warnings, need to get rid Index: TestQuest.lua =================================================================== RCS file: /cvsroot/timewarp/gamedata/TestQuest.lua,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** TestQuest.lua 14 Jan 2004 11:14:22 -0000 1.1 --- TestQuest.lua 17 Jan 2004 01:56:49 -0000 1.2 *************** *** 8,11 **** --- 8,19 ---- end + function GAME_EVENT_SHIP_DIE() + DialogStart "gamedata/pkunk-standing.bmp" + DialogWrite "Somebody is dead now" + answer = DialogAnswer("It doesn't matter!", + "bye") + DialogEnd() + end + DialogStart "gamedata/pkunk-standing.bmp" function question1() |
From: <yu...@us...> - 2004-01-17 01:56:52
|
Update of /cvsroot/timewarp/source/other In directory sc8-pr-cvs1:/tmp/cvs-serv3469/source/other Modified Files: gquest.cpp gquest.h Log Message: Events support for GOB, VS now generate a lot of warnings, need to get rid Index: gquest.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** gquest.cpp 15 Jan 2004 00:10:29 -0000 1.3 --- gquest.cpp 17 Jan 2004 01:56:49 -0000 1.4 *************** *** 26,29 **** --- 26,31 ---- // Load Quest lua_dofile(L, szLuaFile); + // Register Events + gobgame->RegisterEvent(GAME_EVENT_SHIP_DIE, this); } *************** *** 87,93 **** --- 89,126 ---- } lua_settop(L, top); + return; } + void Quest::ProcessEvent ( IEvent* event ) + { + int type = event->GetEventType(); + int top; + switch ( type ) + { + case GAME_EVENT_ALL: + {tw_error ("Process Event failed");} + break; + case GAME_EVENT_SHIP_DIE: + // Test Implementation + top = lua_gettop(L); + lua_pushstring(L, "GAME_EVENT_SHIP_DIE"); + lua_gettable(L, LUA_GLOBALSINDEX); + + + if ( !lua_isfunction(L, -1) ) + { + tw_error("Quest script is not contain GAME_EVENT_SHIP_DIE function"); + }; + lua_call(L, 0, 0 ); + lua_settop(L, top); + break; + case GAME_EVENT_SHIP_GET_DAMAGE: + break; + default: + break; + } + } + int Quest::l_Dialog(lua_State* ls) { *************** *** 139,140 **** --- 172,174 ---- return NOT_IMPLEMENTED; } + Index: gquest.h =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** gquest.h 15 Jan 2004 00:10:29 -0000 1.3 --- gquest.h 17 Jan 2004 01:56:49 -0000 1.4 *************** *** 8,15 **** } class GobPlayer; ! class Quest { bool bExist; --- 8,17 ---- } + #include "gevent.h" + class GobPlayer; ! class Quest: public EventListner { bool bExist; *************** *** 20,29 **** Quest( const char * szLuaFile, GobPlayer * player ); virtual ~Quest(); ! /*! \brief Summon default quest handler ! This function summon in every player think() ! */ ! void Process(); ! bool exist(); ! private: // This is callback functions from Lua quest script /*! \brief On complite quest */ --- 22,35 ---- Quest( const char * szLuaFile, GobPlayer * player ); virtual ~Quest(); ! /*! \brief Summon default quest handler ! This function summon in every player think() ! */ ! void Process(); ! bool exist(); ! ! /*! \brief Process Event */ ! virtual void ProcessEvent( IEvent* event); ! ! private: // This is callback functions from Lua quest script /*! \brief On complite quest */ *************** *** 32,40 **** static int l_AddObject(lua_State* ls); /*! \brief Remove quest object ( ship, starbase ... ) */ ! static int l_RemoveObject(lua_State*ls); }; ! class QuestSource { protected: --- 38,46 ---- static int l_AddObject(lua_State* ls); /*! \brief Remove quest object ( ship, starbase ... ) */ ! static int l_RemoveObject(lua_State*ls); }; ! class QuestSource { protected: *************** *** 55,58 **** --- 61,65 ---- virtual int QuestFailed(Quest* q, GobPlayer* p); virtual int WhenMeet(GobPlayer* p); + }; |
From: <yu...@us...> - 2004-01-17 01:56:52
|
Update of /cvsroot/timewarp/source/games In directory sc8-pr-cvs1:/tmp/cvs-serv3469/source/games Modified Files: ggob.cpp ggob.h Log Message: Events support for GOB, VS now generate a lot of warnings, need to get rid Index: ggob.cpp =================================================================== RCS file: /cvsroot/timewarp/source/games/ggob.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** ggob.cpp 15 Jan 2004 00:10:29 -0000 1.15 --- ggob.cpp 17 Jan 2004 01:56:48 -0000 1.16 *************** *** 402,405 **** --- 402,408 ---- STACKTRACE + EventShipDie esd; + gobgame->GenerateEvent(&esd); + GobPlayer *p = this->get_player(who); Index: ggob.h =================================================================== RCS file: /cvsroot/timewarp/source/games/ggob.h,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** ggob.h 15 Jan 2004 00:10:29 -0000 1.8 --- ggob.h 17 Jan 2004 01:56:49 -0000 1.9 *************** *** 12,15 **** --- 12,16 ---- #include "other/gquest.h" + #include "other/gevent.h" class Upgrade; *************** *** 66,70 **** }; ! class GobGame : public Game { public: --- 67,71 ---- }; ! class GobGame : public Game, public EventHandler { public: |
From: <you...@us...> - 2004-01-15 07:27:38
|
Update of /cvsroot/timewarp/docs In directory sc8-pr-cvs1:/tmp/cvs-serv14733 Added Files: LuaFullGameTheories.txt Log Message: adding some crazy theories on how to write a full game using lua --- NEW FILE: LuaFullGameTheories.txt --- Ok, so there's a couple of approaches to take with this Lua stuff. To discuss: what do we want the game to do? Needed (from the game, not necessarily done in Lua): --- N1. the ability to place planets and stars, and to define their positions, orbits, picture(s), techtonics, weather, bio, energy items, etc N2. Speedy data structures for things like collision detection and gameplay. (TW already does this). This should not be lost if and when a full game is added! N3. N4. There are distinct "Spaces" when the full game is being played. (ie the Sol system is different from the Alpha Centari, even though they are both in Truespace. The point (100,100) in Sol is distinct from the point (100,100) in the Alpha Centari system.) A player should be able to visit one "space," leave to go somewhere else, and the first space should be pretty much the same, but adjusted to show what's changed in the time the player was away. (Do we want a space to N. Minimize the number of libraries used (and their sizes), to maximize the number of platforms TW works on (in terms of file size, memory needed and how difficult it is to get a build working). Assumptions: --- A1. C/C++ is much faster than Lua when doing computational stuff. A2. C++ functions can be called from Lua. Lua functions can be called from C++. A3. Data structures from C++ and Lua can be used in the other language, but it's more of a pain. Both processes involve tricky code that at present, I have a difficult time with. In particular, debugging is difficult, I'll have to find a way to deal with debugging both Lua and C++ simultaneously. Plans: --- P1. Lua Code to have a custom event happen when a ship dies (making up the symbols here): addShip { species = "Ur-quan Kzer-za", shipType = "Dreadnaught", x = 100, y = 100, onDeath = function(killer) { printMessage("I shall be avenged... by these guys!"); addShip{ species="Ur-quan Kzer-za", shipType="Dreadnaught", x = this.x + 100, y = this.y + 100, targetID = killer:getID() } addShip{ species="Ur-quan Kzer-za",shipType="Dreadnaught" } addShip( {} ) } } http://java.sun.com/docs/books/tutorial/uiswing/events/ |
From: <yu...@us...> - 2004-01-15 00:10:32
|
Update of /cvsroot/timewarp/source/other In directory sc8-pr-cvs1:/tmp/cvs-serv10725/source/other Modified Files: gquest.cpp gquest.h Log Message: StarBaseQuestSource Index: gquest.cpp =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gquest.cpp 14 Jan 2004 11:12:32 -0000 1.2 --- gquest.cpp 15 Jan 2004 00:10:29 -0000 1.3 *************** *** 9,12 **** --- 9,13 ---- #define gobgame ((GobGame*)game) + #define NOT_IMPLEMENTED 0 Quest::Quest( const char * szLuaFile, GobPlayer * player ) *************** *** 104,105 **** --- 105,140 ---- return 0; } + + int QuestSource::LoadQuestList ( const char* qlist ) + { + return NOT_IMPLEMENTED; + } + + StarBaseQuestSource::StarBaseQuestSource( const char* qlist ) + { + LoadQuestList( qlist ); + } + + StarBaseQuestSource::~StarBaseQuestSource() + { + } + + int StarBaseQuestSource::GetNextQuest(Quest* q, GobPlayer* p) + { + return NOT_IMPLEMENTED; + } + + int StarBaseQuestSource::QuestSuccess(Quest* q, GobPlayer* p) + { + return NOT_IMPLEMENTED; + } + + int StarBaseQuestSource::QuestFailed(Quest* q, GobPlayer* p) + { + return NOT_IMPLEMENTED; + } + + int StarBaseQuestSource::WhenMeet(GobPlayer* p) + { + return NOT_IMPLEMENTED; + } Index: gquest.h =================================================================== RCS file: /cvsroot/timewarp/source/other/gquest.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gquest.h 14 Jan 2004 11:12:32 -0000 1.2 --- gquest.h 15 Jan 2004 00:10:29 -0000 1.3 *************** *** 36,38 **** --- 36,59 ---- + class QuestSource + { + protected: + virtual int LoadQuestList( const char* qlist ); + public: + virtual int GetNextQuest(Quest* q, GobPlayer* p) = 0; + virtual int QuestSuccess(Quest* q, GobPlayer* p) = 0; + virtual int WhenMeet(GobPlayer* p) = 0; + }; + + class StarBaseQuestSource: public QuestSource + { + public: + StarBaseQuestSource(const char* qlist); + virtual ~StarBaseQuestSource(); + virtual int GetNextQuest(Quest* q, GobPlayer* p); + virtual int QuestSuccess(Quest* q, GobPlayer* p); + virtual int QuestFailed(Quest* q, GobPlayer* p); + virtual int WhenMeet(GobPlayer* p); + }; + #endif // __GQUEST_H__ |
From: <yu...@us...> - 2004-01-15 00:10:32
|
Update of /cvsroot/timewarp/source/games In directory sc8-pr-cvs1:/tmp/cvs-serv10725/source/games Modified Files: ggob.cpp ggob.h Log Message: StarBaseQuestSource Index: ggob.cpp =================================================================== RCS file: /cvsroot/timewarp/source/games/ggob.cpp,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** ggob.cpp 14 Jan 2004 11:12:32 -0000 1.14 --- ggob.cpp 15 Jan 2004 00:10:29 -0000 1.15 *************** *** 304,308 **** add ( p ); ! GobStation *gs = new GobStation(station_sprite, p, builds, background); gs->collide_flag_sameship = ALL_LAYERS; gs->collide_flag_sameteam = ALL_LAYERS; --- 304,309 ---- add ( p ); ! GobStation *gs = new GobStation(station_sprite, p, builds, ! background, "NOT_IMPLEMENTED" ); gs->collide_flag_sameship = ALL_LAYERS; gs->collide_flag_sameteam = ALL_LAYERS; *************** *** 747,758 **** \param background ??? */ ! GobStation::GobStation ( SpaceSprite *pic, SpaceLocation *orbit_me, const char *ship, const char *background) : ! Orbiter(pic, orbit_me, random() % 200 + 500) ! { ! build_type = ship; ! background_pic = background; ! layer = LAYER_CBODIES; ! mass = 99; ! } #define STATION_DIALOG_DEPART 0 --- 748,768 ---- \param background ??? */ ! GobStation::GobStation ( SpaceSprite *pic, SpaceLocation *orbit_me, ! const char *ship, const char *background, ! const char * qlist) : ! Orbiter(pic, orbit_me, random() % 200 + 500) ! { ! build_type = ship; ! background_pic = background; ! layer = LAYER_CBODIES; ! mass = 99; ! ! quest_source = new StarBaseQuestSource( qlist ); ! } ! ! GobStation::~GobStation() ! { ! delete quest_source; ! } #define STATION_DIALOG_DEPART 0 Index: ggob.h =================================================================== RCS file: /cvsroot/timewarp/source/games/ggob.h,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** ggob.h 14 Jan 2004 11:12:32 -0000 1.7 --- ggob.h 15 Jan 2004 00:10:29 -0000 1.8 *************** *** 112,120 **** const char *build_type; const char *background_pic; ! GobStation ( SpaceSprite *pic, SpaceLocation *orbit_me, const char *ship, const char *background); virtual void buy_new_ship_menu(GobPlayer *s) ; virtual void inflict_damage(SpaceObject *other); virtual void station_screen (GobPlayer *s); virtual void upgrade_menu(GobStation *station, GobPlayer *gs) ; }; --- 112,125 ---- const char *build_type; const char *background_pic; ! GobStation ( SpaceSprite *pic, SpaceLocation *orbit_me, ! const char *ship, const char *background, ! const char *qlist ); ! virtual ~GobStation(); virtual void buy_new_ship_menu(GobPlayer *s) ; virtual void inflict_damage(SpaceObject *other); virtual void station_screen (GobPlayer *s); virtual void upgrade_menu(GobStation *station, GobPlayer *gs) ; + + StarBaseQuestSource* quest_source; }; |
From: <yu...@us...> - 2004-01-14 11:15:51
|
Update of /cvsroot/timewarp In directory sc8-pr-cvs1:/tmp/cvs-serv5657 Removed Files: pkunk-standing.bmp Log Message: no message |