Skip to content

Commit

Permalink
rename stuffs
Browse files Browse the repository at this point in the history
  • Loading branch information
CMDR-Bill-Doors committed Sep 21, 2023
1 parent 2043db8 commit f9c91a7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ namespace CombatExtended
{
public class TurretDrawExtension : DefModExtension
{
public GraphicData TurretBottomTexPath;
public GraphicData TurretBottomGraphicData;

public GraphicData TurretTopTexPath;
public GraphicData TurretTopGraphicData;

public List<TurretDrawExtension_BarrelOffsetPair> Barrels = new List<TurretDrawExtension_BarrelOffsetPair>();
}
Expand All @@ -21,6 +21,6 @@ public class TurretDrawExtension_BarrelOffsetPair
{
public Vector2 BarrelOffset;
public Material BarrelMaterial;
public GraphicData BarrelTexPath;
public GraphicData BarrelGraphicData;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -200,14 +200,14 @@ public override void SpawnSetup(Map map, bool respawningAfterLoad) //Add ma
TurretDrawExtension turretDrawExtension = this.def.GetModExtension<TurretDrawExtension>();
if (turretDrawExtension != null)
{
TurretTopBaseMaterial = turretDrawExtension.TurretBottomTexPath.Graphic.MatSingle;
TurretTopTopMaterial = turretDrawExtension.TurretTopTexPath.Graphic.MatSingle;
TurretTopBaseMaterial = turretDrawExtension.TurretBottomGraphicData.Graphic.MatSingle;
TurretTopTopMaterial = turretDrawExtension.TurretTopGraphicData.Graphic.MatSingle;
if (turretDrawExtension.Barrels.Any())
{
foreach (var barrel in turretDrawExtension.Barrels)
{
TurretDrawExtension_BarrelOffsetPair barrelCache = barrel;
barrelCache.BarrelMaterial = barrel.BarrelTexPath.Graphic.MatSingle;
barrelCache.BarrelMaterial = barrel.BarrelGraphicData.Graphic.MatSingle;
BarrelOffsetPairs.Add(barrelCache);
}
}
Expand Down

0 comments on commit f9c91a7

Please sign in to comment.