- Timestamp:
- Jun 28, 2006, 9:11:54 PM (18 years ago)
- Location:
- branches/single_player_map/src/lib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/single_player_map/src/lib/graphics/importer/bsp_manager.cc
r8865 r8887 968 968 Vector out = dest; 969 969 970 970 971 bool SolidFlag = false; 971 972 bool collision = false; 972 973 Vector position1 = position; … … 998 999 else 999 1000 { 1001 // Init positions and destinations to anything useful! 1000 1002 1001 1003 } … … 1025 1027 this->collPlane->z = 0.0f; 1026 1028 collision = true; 1029 SolidFlag = true; 1027 1030 } else 1028 1031 collision = false; … … 1046 1049 plane* testPlane = this->collPlane; 1047 1050 1051 1052 bool xCollision = false; 1053 bool zCollision = false; 1054 if(!SolidFlag) 1055 { 1048 1056 1049 1057 // 2nd Collision Detection … … 1055 1063 this->checkCollisionRayN(this->root,0.0f,1.0f, &position1, &dest1 ); 1056 1064 out.x = this->outputFraction; 1065 xCollision = true; 1057 1066 //out.z = this->outputFraction; 1058 1067 1068 if(!SolidFlag) 1069 { 1059 1070 1060 1071 // 3rd Collision Detection … … 1067 1078 //out.x = this->outputFraction; 1068 1079 out.z = this->outputFraction; 1069 1070 1080 if(this->outputFraction != 1.0 ) 1081 zCollision = true; 1082 } 1083 } 1071 1084 /* 1072 1085 This is how you would calculate the Coordinates where worldEntity Collided with the BSP world. … … 1082 1095 worldEntity->registerCollision(COLLISION_TYPE_AXIS_Y, this->parent, worldEntity, Vector(testPlane->x, testPlane->y, testPlane->z), out, false); 1083 1096 } 1084 else worldEntity->registerCollision(COLLISION_TYPE_AXIS_Y, this->parent, worldEntity, Vector(0.0, 2.0, 0.0), dest, false); 1097 else 1098 { 1099 if(xCollision || yCollision) 1100 { 1101 1102 worldEntity->registerCollision((xCollision ? COLLISION_TYPE_AXIS_X :0) | (zCollision ? COLLISION_TYPE_AXIS_Z :0) , this->parent, worldEntity, Vector(testPlane->x, testPlane->y, testPlane->z), out, false); 1103 } 1104 1105 } 1106 //else worldEntity->registerCollision(COLLISION_TYPE_AXIS_Y, this->parent, worldEntity, Vector(0.0, 2.0, 0.0), dest, false); 1085 1107 1086 1108 } -
branches/single_player_map/src/lib/shell/shell_command.cc
r8350 r8887 373 373 else 374 374 { 375 delete this->completors[parameter]; 375 if(this->completors[parameter] == NULL) 376 //delete this->completors[parameter]; 376 377 this->completors[parameter] = completorPlugin.clone(); 377 378 }
Note: See TracChangeset
for help on using the changeset viewer.