| 263 | } |
| 264 | |
| 265 | void afxPathData::update_derived_values() |
| 266 | { |
| 267 | U32 num_rolls = (rolls != 0) ? num_points : 0; |
| 268 | U32 num_times = (times != 0) ? num_points : 0; |
| 269 | |
| 270 | if (update_points) |
| 271 | { |
| 272 | derive_points_array(); |
| 273 | update_points = false; |
| 274 | } |
| 275 | |
| 276 | if (update_rolls || num_rolls != num_points) |
| 277 | { |
| 278 | derive_rolls_array(); |
| 279 | update_rolls = false; |
| 280 | } |
| 281 | |
| 282 | if (update_times || num_times != num_points) |
| 283 | { |
| 284 | derive_times_array(); |
| 285 | update_times = false; |
| 286 | } |
| 287 | |
| 288 | // CAUTION: The following block of code is fragile and tricky since it depends |
| 289 | // on the underlying structures defined by ImplementEnumType/EndImplementEnumType. |
| 290 | // This done because the enum text is parsed from a longer string. |
| 291 | if (loop_string != ST_NULLSTRING) |
| 292 | { |
| 293 | for (unsigned int i = 0; i < _afxPath3DLoopType::_sEnumTable.getNumValues(); i++) |
| 294 | { |
| 295 | if (dStricmp(_afxPath3DLoopType::_sEnumTable[i].mName, loop_string) == 0) |
| 296 | { |
| 297 | loop_type = _afxPath3DLoopType::_sEnumTable[i].mInt; |
| 298 | break; |
| 299 | } |
| 300 | } |
| 301 | } |
| 302 | else |
| 303 | { |
| 304 | loop_string = _afxPath3DLoopType::_sEnumTable[0].mName; |
| 305 | loop_type = _afxPath3DLoopType::_sEnumTable[0].mInt; |
| 306 | } |
| 307 | } |
| 308 | |
| 309 | bool afxPathData::preload(bool server, String &errorStr) |
| 310 | { |
nothing calls this directly
no test coverage detected