RTSUnitData missing addfield.
by Gregory "Centove" McLean · in RTS Starter Kit · 12/04/2004 (7:58 am) · 6 replies
In the RTSUnitData we have the following..
Yet in RTSUnitData::initPersistFields() this is missing, consequently, setting the vision property in the datablock is ignored. Which in the visManager causes grief:
Was always returning 21.0 (ie the default)
Add
To the initPersistFields() and ho ho! Your units aren't blind anymore!
F32 mVision;
Yet in RTSUnitData::initPersistFields() this is missing, consequently, setting the vision property in the datablock is ignored. Which in the visManager causes grief:
F32 targetVision = ((RTSUnitData*)target->getDataBlock())->mVision + target->mNetModifier.mVision;
Was always returning 21.0 (ie the default)
Add
addField("vision", TypeF32, Offset(mVision, RTSUnitData));To the initPersistFields() and ho ho! Your units aren't blind anymore!
#2
12/06/2004 (4:16 pm)
This will help some problems with the visibility manager too. Thanks Gregory, don't know how we let that one slip.
#3
04/25/2006 (9:31 am)
Why has this not been fixed yet???
#4
like file path and name
line number and text sample
and a change to this
so the average person could do this
without possibly editng the wrong line
or worse yet wrong file
but yes this will be nice to add to the VS2005 rebuild of RTS
trying to get everything I can find
through forum post wiki and my own efforts
to make a 100% error free conversion process
and then a fully documented set of instructions
for anyone else to follow for a ver 1.4 RTS kit
05/06/2006 (11:27 pm)
Um nice but could be betterlike file path and name
line number and text sample
and a change to this
so the average person could do this
without possibly editng the wrong line
or worse yet wrong file
but yes this will be nice to add to the VS2005 rebuild of RTS
trying to get everything I can find
through forum post wiki and my own efforts
to make a 100% error free conversion process
and then a fully documented set of instructions
for anyone else to follow for a ver 1.4 RTS kit
#5
11/29/2006 (2:17 pm)
Add it to line 222 in RTSUnit.cc
#6
It's in RTSUnitData::initPersistFields() and you can add it right after the "range" line
12/01/2006 (12:46 pm)
For me it was line 146, so don't trust the line numbers :)It's in RTSUnitData::initPersistFields() and you can add it right after the "range" line
Associate Anthony Rosenbaum