- Timestamp:
- Dec 3, 2005, 2:54:27 PM (19 years ago)
- Location:
- branches/spaceshipcontrol/src
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/spaceshipcontrol/src/lib/event/key_mapper.cc
r5474 r5886 21 21 #include "key_mapper.h" 22 22 23 #include "event_def.h" 24 23 25 #include "globals.h" 24 26 #include "ini_parser.h" 25 27 #include "key_names.h" 26 28 #include "debug.h" 29 27 30 28 31 using namespace std; … … 191 194 { 192 195 if( index[0] == 0) 193 196 { 194 197 *map[i].pValue = index[1]; 195 198 PRINTF(4)("Mapping %s to '%s' (id %i)\n", name, SDLKToKeyname(index[1]), index[1]); 196 199 break; 197 198 else { 200 } 201 else { 199 202 *map[i].pValue = index[1]; 200 203 PRINTF(4)("Mapping %s to '%s' (id %i)\n", name, SDLBToButtonname(index[1]), index[1]); 201 204 break; 202 205 } 203 206 } 204 207 } -
branches/spaceshipcontrol/src/lib/event/key_mapper.h
r5819 r5886 10 10 11 11 #include "base_object.h" 12 #include "event_def.h"12 //#include "event_def.h" 13 13 14 14 class IniParser; … … 66 66 67 67 private: 68 Sint32coord[2]; //!< temp place to save variables in nameToIndex() function68 int coord[2]; //!< temp place to save variables in nameToIndex() function 69 69 }; 70 70 -
branches/spaceshipcontrol/src/story_entities/world.cc
r5881 r5886 362 362 // Create a Player 363 363 this->localPlayer = new Player(); 364 Playable* playable; 364 365 list<BaseObject*>* playableList = ClassList::getList(CL_PLAYABLE); 365 366 if (playableList != NULL) 366 367 { 367 Playable*playable = dynamic_cast<Playable*>(playableList->front());368 playable = dynamic_cast<Playable*>(playableList->front()); 368 369 if (playable != NULL) 369 370 this->localPlayer->setControllable(playable); … … 381 382 382 383 // bind camera 383 //this->localCamera->bind (localPlayer); 384 // this->localPlayer->addChild (this->localCamera); 384 playable->addChild (this->localCamera); 385 385 386 386 387 387 // TrackManager::getInstance()->setBindSlave(env); 388 //PNode* tn = TrackManager::getInstance()->getTrackNode();389 // tn->addChild(this->localPlayer);390 391 //localCamera->setParent(TrackNode::getInstance());388 PNode* tn = TrackManager::getInstance()->getTrackNode(); 389 tn->addChild(playable); 390 391 // //localCamera->setParent(TrackNode::getInstance()); 392 392 // tn->addChild(this->localCamera); 393 //localCamera->lookAt(tn);394 localCamera->setClipRegion(1, 1000 0.0);393 localCamera->lookAt(tn); 394 localCamera->setClipRegion(1, 1000.0); 395 395 // this->localPlayer->setParentMode(PNODE_ALL); 396 396 TrackManager::getInstance()->condition(1, LEFTRIGHT, this->localPlayer); -
branches/spaceshipcontrol/src/world_entities/playable.h
r5878 r5886 43 43 WeaponManager* weaponMan; //!< the weapon manager: managing a list of weapon to wepaon-slot mapping 44 44 std::list<int> events; 45 46 Player* currentPlayer; 45 47 //todo: add a event to id mapping list 46 47 48 48 }; 49 49
Note: See TracChangeset
for help on using the changeset viewer.