|
From: <bul...@us...> - 2013-05-28 06:16:51
|
Revision: 22775
http://sourceforge.net/p/bzflag/code/22775
Author: bullet_catcher
Date: 2013-05-28 06:16:49 +0000 (Tue, 28 May 2013)
Log Message:
-----------
Remove "const" from some mesh objects that are modifiable.
Modified Paths:
--------------
trunk/bzflag/include/MeshObstacle.h
trunk/bzflag/src/bzflag/World.cxx
Modified: trunk/bzflag/include/MeshObstacle.h
===================================================================
--- trunk/bzflag/include/MeshObstacle.h 2013-05-28 03:35:53 UTC (rev 22774)
+++ trunk/bzflag/include/MeshObstacle.h 2013-05-28 06:16:49 UTC (rev 22775)
@@ -107,7 +107,7 @@
bool useSmoothBounce() const;
bool noClusters() const;
- const MeshDrawInfo* getDrawInfo() const;
+ MeshDrawInfo* getDrawInfo() const;
void setDrawInfo(MeshDrawInfo*);
int packSize() const;
@@ -223,7 +223,7 @@
return noclusters;
}
-inline const MeshDrawInfo* MeshObstacle::getDrawInfo() const
+inline MeshDrawInfo* MeshObstacle::getDrawInfo() const
{
return drawInfo;
}
Modified: trunk/bzflag/src/bzflag/World.cxx
===================================================================
--- trunk/bzflag/src/bzflag/World.cxx 2013-05-28 03:35:53 UTC (rev 22774)
+++ trunk/bzflag/src/bzflag/World.cxx 2013-05-28 06:16:49 UTC (rev 22775)
@@ -401,7 +401,7 @@
// check mesh faces
for (/* do nothing */; i < olist->count; i++) {
- const Obstacle* obs = olist->list[i];
+ Obstacle* obs = olist->list[i];
const char* type = obs->getType();
if (type == MeshObstacle::getClassName()) {
break;
@@ -419,7 +419,7 @@
}
else {
// add the face to the hitlist
- olist->list[hitCount] = (Obstacle*) obs;
+ olist->list[hitCount] = obs;
hitCount++;
// compute its dot product and stick it in the scratchPad
const float* p = face->getPlane();
@@ -542,7 +542,7 @@
drawInfoArray = new MeshDrawInfo*[count];
drawInfoCount = 0;
for (unsigned int i = 0; i < count; i++) {
- MeshDrawInfo* di = (MeshDrawInfo*) sourceMeshes[i]->getDrawInfo();
+ MeshDrawInfo* di = sourceMeshes[i]->getDrawInfo();
if ((di != NULL) && !di->isCopy()) {
MeshDrawMgr* dm = new MeshDrawMgr(di);
di->setDrawMgr(dm);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|