From 96ceb76e46b36dc8d8b550fcc93cfd5da4bc9bad Mon Sep 17 00:00:00 2001 From: Jan Date: Tue, 3 Dec 2019 23:54:02 +0100 Subject: [PATCH] ZoneCode: Change WeaponDef asset to have normal members instead of arrays for graph knots since the ordering of loading needs the array entries separated and the current code generation doesn't allow for that --- src/ZoneCommon/Game/T6/T6_Assets.h | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/ZoneCommon/Game/T6/T6_Assets.h b/src/ZoneCommon/Game/T6/T6_Assets.h index 7d014e08..3afd909e 100644 --- a/src/ZoneCommon/Game/T6/T6_Assets.h +++ b/src/ZoneCommon/Game/T6/T6_Assets.h @@ -4279,9 +4279,17 @@ struct WeaponDef float fAntiQuickScopeSwayFactor; float fightDist; float maxDist; - const char *accuracyGraphName[2]; - vec2_t *accuracyGraphKnots[2]; - vec2_t *originalAccuracyGraphKnots[2]; + //const char *accuracyGraphName[2]; // TODO: Order is accuracyGraphName[0] -> accuracyGraphKnots[0] -> originalAccuracyGraphKnots[0] -> accuracyGraphName[1] -> ... + // Which is currently not possible to do in code generation. Afaik this is the only place where this is the case. + // So might be something to fix but on the other hand it might be too much work for this little inconvenience. + const char *accuracyGraphName0; + const char *accuracyGraphName1; + //vec2_t *accuracyGraphKnots[2]; + vec2_t* accuracyGraphKnots0; + vec2_t* accuracyGraphKnots1; + //vec2_t *originalAccuracyGraphKnots[2]; + vec2_t* originalAccuracyGraphKnots0; + vec2_t* originalAccuracyGraphKnots1; int accuracyGraphKnotCount[2]; int originalAccuracyGraphKnotCount[2]; int iPositionReloadTransTime;