Skip to content

Commit 95072df

Browse files
committed
A number of places in Lua compared for classname equality against "ACDropship", which is wrong and always yields false.
1 parent f9483a2 commit 95072df

File tree

7 files changed

+37
-37
lines changed

7 files changed

+37
-37
lines changed

Data/Base.rte/Activities/BrainVsBrain.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -625,7 +625,7 @@ function BrainvsBrain:CreateMediumDrop(xPosLZ)
625625
if craftMaxMass < 0 then
626626
craftMaxMass = math.huge;
627627
elseif craftMaxMass < 1 then
628-
if Craft.ClassName == "ACDropship" then
628+
if Craft.ClassName == "ACDropShip" then
629629
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
630630
else
631631
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -685,7 +685,7 @@ function BrainvsBrain:CreateLightDrop(xPosLZ)
685685
if craftMaxMass < 0 then
686686
craftMaxMass = math.huge;
687687
elseif craftMaxMass < 1 then
688-
if Craft.ClassName == "ACDropship" then
688+
if Craft.ClassName == "ACDropShip" then
689689
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
690690
else
691691
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -743,7 +743,7 @@ function BrainvsBrain:CreateScoutDrop(xPosLZ)
743743
if craftMaxMass < 0 then
744744
craftMaxMass = math.huge;
745745
elseif craftMaxMass < 1 then
746-
if Craft.ClassName == "ACDropship" then
746+
if Craft.ClassName == "ACDropShip" then
747747
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
748748
else
749749
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined

Data/Base.rte/Activities/Harvester.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ function Harvester:UpdateActivity()
263263
if shipMaxMass < 0 then
264264
shipMaxMass = math.huge;
265265
elseif shipMaxMass < 1 then
266-
if Craft.ClassName == "ACDropship" then
266+
if Craft.ClassName == "ACDropShip" then
267267
DeleteEntity(ship);
268268
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
269269
else

Data/Base.rte/Activities/Massacre.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ function Massacre:UpdateActivity()
261261
if shipMaxMass < 0 then
262262
shipMaxMass = math.huge;
263263
elseif shipMaxMass < 1 then
264-
if Craft.ClassName == "ACDropship" then
264+
if Craft.ClassName == "ACDropShip" then
265265
DeleteEntity(ship);
266266
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
267267
else

Data/Base.rte/Activities/Siege.lua

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -612,7 +612,7 @@ function Siege:CreateMediumDrop(xPosLZ, techName)
612612
if craftMaxMass < 0 then
613613
craftMaxMass = math.huge;
614614
elseif craftMaxMass < 1 then
615-
if Craft.ClassName == "ACDropship" then
615+
if Craft.ClassName == "ACDropShip" then
616616
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
617617
else
618618
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -666,7 +666,7 @@ function Siege:CreateLightDrop(xPosLZ, techName)
666666
if craftMaxMass < 0 then
667667
craftMaxMass = math.huge;
668668
elseif craftMaxMass < 1 then
669-
if Craft.ClassName == "ACDropship" then
669+
if Craft.ClassName == "ACDropShip" then
670670
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
671671
else
672672
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -718,7 +718,7 @@ function Siege:CreateEngineerDrop(xPosLZ, techName)
718718
if craftMaxMass < 0 then
719719
craftMaxMass = math.huge;
720720
elseif craftMaxMass < 1 then
721-
if Craft.ClassName == "ACDropship" then
721+
if Craft.ClassName == "ACDropShip" then
722722
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
723723
else
724724
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -767,7 +767,7 @@ function Siege:CreateScoutDrop(xPosLZ, techName)
767767
if craftMaxMass < 0 then
768768
craftMaxMass = math.huge;
769769
elseif craftMaxMass < 1 then
770-
if Craft.ClassName == "ACDropship" then
770+
if Craft.ClassName == "ACDropShip" then
771771
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
772772
else
773773
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined

Data/Base.rte/Activities/SkirmishDefense.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -740,7 +740,7 @@ function SkirmishDefense:CreateMediumDrop(xPosLZ, Destination, Team)
740740
if craftMaxMass < 0 then
741741
craftMaxMass = math.huge;
742742
elseif craftMaxMass < 1 then
743-
if Craft.ClassName == "ACDropship" then
743+
if Craft.ClassName == "ACDropShip" then
744744
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
745745
else
746746
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -798,7 +798,7 @@ function SkirmishDefense:CreateLightDrop(xPosLZ, Destination, Team)
798798
if craftMaxMass < 0 then
799799
craftMaxMass = math.huge;
800800
elseif craftMaxMass < 1 then
801-
if Craft.ClassName == "ACDropship" then
801+
if Craft.ClassName == "ACDropShip" then
802802
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
803803
else
804804
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -854,7 +854,7 @@ function SkirmishDefense:CreateScoutDrop(xPosLZ, Destination, Team)
854854
if craftMaxMass < 0 then
855855
craftMaxMass = math.huge;
856856
elseif craftMaxMass < 1 then
857-
if Craft.ClassName == "ACDropship" then
857+
if Craft.ClassName == "ACDropShip" then
858858
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
859859
else
860860
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined

Data/Base.rte/Activities/WaveDefense.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -679,7 +679,7 @@ function WaveDefense:CreateMediumDrop(xPosLZ, Destination)
679679
if craftMaxMass < 0 then
680680
craftMaxMass = math.huge;
681681
elseif craftMaxMass < 1 then
682-
if Craft.ClassName == "ACDropship" then
682+
if Craft.ClassName == "ACDropShip" then
683683
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
684684
else
685685
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -737,7 +737,7 @@ function WaveDefense:CreateLightDrop(xPosLZ, Destination)
737737
if craftMaxMass < 0 then
738738
craftMaxMass = math.huge;
739739
elseif craftMaxMass < 1 then
740-
if Craft.ClassName == "ACDropship" then
740+
if Craft.ClassName == "ACDropShip" then
741741
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
742742
else
743743
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined
@@ -793,7 +793,7 @@ function WaveDefense:CreateScoutDrop(xPosLZ, Destination)
793793
if craftMaxMass < 0 then
794794
craftMaxMass = math.huge;
795795
elseif craftMaxMass < 1 then
796-
if Craft.ClassName == "ACDropship" then
796+
if Craft.ClassName == "ACDropShip" then
797797
Craft = RandomACDropShip("Craft", 0); -- MaxMass not defined
798798
else
799799
Craft = RandomACRocket("Craft", 0); -- MaxMass not defined

Source/Entities/ACDropShip.h

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -80,51 +80,51 @@ namespace RTE {
8080
/// Default is four.
8181
int GetMaxPassengers() const override { return m_MaxPassengers > -1 ? m_MaxPassengers : 4; }
8282

83-
/// Gets the right side thruster of this ACDropship.
84-
/// @return A pointer to the right side thruster of this ACDropship. Ownership is NOT transferred.
83+
/// Gets the right side thruster of this ACDropShip.
84+
/// @return A pointer to the right side thruster of this ACDropShip. Ownership is NOT transferred.
8585
AEmitter* GetRightThruster() const { return m_pRThruster; }
8686

87-
/// Sets the right side thruster for this ACDropship.
87+
/// Sets the right side thruster for this ACDropShip.
8888
/// @param newThruster The new thruster to use.
8989
void SetRightThruster(AEmitter* newThruster);
9090

91-
/// Gets the left side thruster of this ACDropship.
92-
/// @return A pointer to the left side thruster of this ACDropship. Ownership is NOT transferred.
91+
/// Gets the left side thruster of this ACDropShip.
92+
/// @return A pointer to the left side thruster of this ACDropShip. Ownership is NOT transferred.
9393
AEmitter* GetLeftThruster() const { return m_pLThruster; }
9494

95-
/// Sets the left side thruster for this ACDropship.
95+
/// Sets the left side thruster for this ACDropShip.
9696
/// @param newThruster The new thruster to use.
9797
void SetLeftThruster(AEmitter* newThruster);
9898

99-
/// Gets the right side secondary thruster of this ACDropship.
100-
/// @return A pointer to the right side secondary thruster of this ACDropship. Ownership is NOT transferred.
99+
/// Gets the right side secondary thruster of this ACDropShip.
100+
/// @return A pointer to the right side secondary thruster of this ACDropShip. Ownership is NOT transferred.
101101
AEmitter* GetURightThruster() const { return m_pURThruster; }
102102

103-
/// Sets the right side secondary thruster for this ACDropship.
103+
/// Sets the right side secondary thruster for this ACDropShip.
104104
/// @param newThruster The new thruster to use.
105105
void SetURightThruster(AEmitter* newThruster);
106106

107-
/// Gets the left side secondary thruster of this ACDropship.
108-
/// @return A pointer to the left side secondary thruster of this ACDropship. Ownership is NOT transferred.
107+
/// Gets the left side secondary thruster of this ACDropShip.
108+
/// @return A pointer to the left side secondary thruster of this ACDropShip. Ownership is NOT transferred.
109109
AEmitter* GetULeftThruster() const { return m_pULThruster; }
110110

111-
/// Sets the left side secondary thruster for this ACDropship.
111+
/// Sets the left side secondary thruster for this ACDropShip.
112112
/// @param newThruster The new thruster to use.
113113
void SetULeftThruster(AEmitter* newThruster);
114114

115-
/// Gets the left side hatch of this ACDropship.
116-
/// @return A pointer to the left side hatch of this ACDropship. Ownership is NOT transferred.
115+
/// Gets the left side hatch of this ACDropShip.
116+
/// @return A pointer to the left side hatch of this ACDropShip. Ownership is NOT transferred.
117117
Attachable* GetLeftHatch() const { return m_pLHatch; }
118118

119-
/// Sets the left side hatch for this ACDropship.
119+
/// Sets the left side hatch for this ACDropShip.
120120
/// @param newHatch The new hatch to use.
121121
void SetLeftHatch(Attachable* newHatch);
122122

123-
/// Gets the right side hatch of this ACDropship.
124-
/// @return A pointer to the right side hatch of this ACDropship. Ownership is NOT transferred.
123+
/// Gets the right side hatch of this ACDropShip.
124+
/// @return A pointer to the right side hatch of this ACDropShip. Ownership is NOT transferred.
125125
Attachable* GetRightHatch() const { return m_pRHatch; }
126126

127-
/// Sets the right side hatch for this ACDropship.
127+
/// Sets the right side hatch for this ACDropShip.
128128
/// @param newHatch The new hatch to use.
129129
void SetRightHatch(Attachable* newHatch);
130130

@@ -148,12 +148,12 @@ namespace RTE {
148148
/// @return Current lateral control value.
149149
float GetLateralControl() const { return m_LateralControl; }
150150

151-
/// Gets the modifier for height at which this ACDropship should hover above terrain.
152-
/// @return The modifier for height at which this ACDropship should hover above terrain.
151+
/// Gets the modifier for height at which this ACDropShip should hover above terrain.
152+
/// @return The modifier for height at which this ACDropShip should hover above terrain.
153153
float GetHoverHeightModifier() const { return m_HoverHeightModifier; }
154154

155-
/// Sets the modifier for height at which this ACDropship should hover above terrain.
156-
/// @param newHoverHeightModifier The new modifier for height at which this ACDropship should hover above terrain.
155+
/// Sets the modifier for height at which this ACDropShip should hover above terrain.
156+
/// @param newHoverHeightModifier The new modifier for height at which this ACDropShip should hover above terrain.
157157
void SetHoverHeightModifier(float newHoverHeightModifier) { m_HoverHeightModifier = newHoverHeightModifier; }
158158

159159
/// Protected member variable and method declarations

0 commit comments

Comments
 (0)