Skip to content

Commit

Permalink
Merge pull request #51 from StarCoreSE/CTC-Fuckery
Browse files Browse the repository at this point in the history
CTC Radar Added, Treb Changes
  • Loading branch information
wa-la000 authored Aug 29, 2024
2 parents 2bc4017 + 8939abf commit abad089
Show file tree
Hide file tree
Showing 3 changed files with 157 additions and 12 deletions.
131 changes: 124 additions & 7 deletions ModernWarfareGuns/Data/CubeBlocks_Automation.sbc
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,126 @@
<SubtypeId>LargeTurretControlBlock</SubtypeId>
</Id>
<Public>true</Public>
<DisplayName>Turret Controller Block Radar</DisplayName>
<Icon>Textures\GUI\Icons\Cubes\TurretControlBlockSmall.dds</Icon>
<Description>Description_TurretControlBlock</Description>
<CubeSize>Small</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="2" />
<ModelOffset x="0" y="0" z="0" />
<Model>Models\Cubes\Small\TurretControlBlock.mwm</Model>
<Components>
<Component Subtype="InteriorPlate" Count="4" />
<Component Subtype="Construction" Count="10" />
<Component Subtype="Detector" Count="4" />
<Component Subtype="Motor" Count="2" />
<Component Subtype="Display" Count="1" />
<Component Subtype="Computer" Count="10" />
<Component Subtype="SteelPlate" Count="4" />
</Components>
<CriticalComponent Subtype="Computer" Index="0" />
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Cubes\Small\TurretControlBlockConstruction_1.mwm" />
<Model BuildPercentUpperBound="1.00" File="Models\Cubes\Small\TurretControlBlockConstruction_2.mwm" />
</BuildProgressModels>
<MirroringZ>Y</MirroringZ>
<MirroringY>Z</MirroringY>
<EdgeType>Light</EdgeType>
<BuildTimeSeconds>10</BuildTimeSeconds>
<MountPoints>
<MountPoint Side="Bottom" StartX="0" StartY="0" EndX="1" EndY="2" Default="true" />
<MountPoint Side="Front" StartX="0" StartY="0" EndX="1" EndY="1" />
<MountPoint Side="Back" StartX="0" StartY="0" EndX="1" EndY="1" />
<MountPoint Side="Right" StartX="0" StartY="0" EndX="2" EndY="1" />
<MountPoint Side="Left" StartX="0" StartY="0" EndX="2" EndY="1" />
<MountPoint Side="Top" StartX="0" StartY="0" EndX="1" EndY="2" />
</MountPoints>
<ResourceSinkGroup>Utility</ResourceSinkGroup>
<DamageEffectName>Damage_Electrical_Damaged</DamageEffectName>
<DamagedSound>ParticleElectrical</DamagedSound>
<EmissiveColorPreset>Default</EmissiveColorPreset>
<DestroyEffect>BlockDestroyedExplosion_Tiny</DestroyEffect>
<DestroySound>WepSmallWarheadExpl</DestroySound>
<PlayerInputDivider>50</PlayerInputDivider>
<ResourceSinkGroup>Utility</ResourceSinkGroup>
<PowerInputIdle>0.0005</PowerInputIdle>
<PCU>100</PCU>
<MaxRangeMeters>0</MaxRangeMeters>
<IsAirTight>true</IsAirTight>
<ScreenAreas>
<ScreenArea Name="CockpitScreen_01" DisplayName="" TextureResolution="256" ScreenWidth="5" ScreenHeight="4" />
</ScreenAreas>
</Definition>

<Definition xsi:type="MyObjectBuilder_TurretControlBlockDefinition">
<Id>
<TypeId>TurretControlBlock</TypeId>
<SubtypeId>SmallTurretControlBlock</SubtypeId>
</Id>
<Public>true</Public>
<DisplayName>DisplayName_TurretControlBlock</DisplayName>
<Icon>Textures\GUI\Icons\Cubes\TurretControlBlockLarge.dds</Icon>
<Icon>Textures\GUI\Icons\Cubes\TurretControlBlockSmall.dds</Icon>
<Description>Description_TurretControlBlock</Description>
<CubeSize>Large</CubeSize>
<CubeSize>Small</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="2" />
<ModelOffset x="0" y="0" z="0" />
<Model>Models\Cubes\Small\TurretControlBlock.mwm</Model>
<Components>
<Component Subtype="InteriorPlate" Count="4" />
<Component Subtype="Construction" Count="10" />
<Component Subtype="Detector" Count="4" />
<Component Subtype="Motor" Count="2" />
<Component Subtype="Display" Count="1" />
<Component Subtype="Computer" Count="10" />
<Component Subtype="SteelPlate" Count="4" />
</Components>
<CriticalComponent Subtype="Computer" Index="0" />
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Cubes\Small\TurretControlBlockConstruction_1.mwm" />
<Model BuildPercentUpperBound="1.00" File="Models\Cubes\Small\TurretControlBlockConstruction_2.mwm" />
</BuildProgressModels>
<MirroringZ>Y</MirroringZ>
<MirroringY>Z</MirroringY>
<EdgeType>Light</EdgeType>
<BuildTimeSeconds>10</BuildTimeSeconds>
<MountPoints>
<MountPoint Side="Bottom" StartX="0" StartY="0" EndX="1" EndY="2" Default="true" />
<MountPoint Side="Front" StartX="0" StartY="0" EndX="1" EndY="1" />
<MountPoint Side="Back" StartX="0" StartY="0" EndX="1" EndY="1" />
<MountPoint Side="Right" StartX="0" StartY="0" EndX="2" EndY="1" />
<MountPoint Side="Left" StartX="0" StartY="0" EndX="2" EndY="1" />
<MountPoint Side="Top" StartX="0" StartY="0" EndX="1" EndY="2" />
</MountPoints>
<ResourceSinkGroup>Utility</ResourceSinkGroup>
<DamageEffectName>Damage_Electrical_Damaged</DamageEffectName>
<DamagedSound>ParticleElectrical</DamagedSound>
<EmissiveColorPreset>Default</EmissiveColorPreset>
<DestroyEffect>BlockDestroyedExplosion_Tiny</DestroyEffect>
<DestroySound>WepSmallWarheadExpl</DestroySound>
<PlayerInputDivider>50</PlayerInputDivider>
<ResourceSinkGroup>Utility</ResourceSinkGroup>
<PowerInputIdle>0.0005</PowerInputIdle>
<PCU>100</PCU>
<MaxRangeMeters>0</MaxRangeMeters>
<IsAirTight>true</IsAirTight>
<ScreenAreas>
<ScreenArea Name="CockpitScreen_01" DisplayName="" TextureResolution="256" ScreenWidth="5" ScreenHeight="4" />
</ScreenAreas>
</Definition>

<!-- Below is the FREAKZONE, only FREAKS can go below here -->
<!--
<Definition xsi:type="MyObjectBuilder_TurretControlBlockDefinition">
<Id>
<TypeId>TurretControlBlock</TypeId>
<SubtypeId>LargeTurretControlBlockRadar</SubtypeId>
</Id>
<Public>true</Public>
<DisplayName>Turret Control Block Radar</DisplayName>
<Icon>Textures\GUI\Icons\Cubes\TurretControlBlockLarge.dds</Icon>
<Description>A more specialised turret control block that can slave to target locks</Description>
<CubeSize>Small</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="1" />
<ModelOffset x="0" y="0" z="0" />
Expand Down Expand Up @@ -48,7 +164,7 @@
<MountPoint Side="Top" StartX="0" StartY="0.1" EndX="0.1" EndY="0.9" />
<MountPoint Side="Top" StartX="0.9" StartY="0.1" EndX="1" EndY="0.9" />
</MountPoints>
<BlockPairName>TurretControlBlock</BlockPairName>
<BlockPairName>TurretControlBlockRadar</BlockPairName>
<ResourceSinkGroup>Utility</ResourceSinkGroup>
<DamageEffectName>Damage_Electrical_Damaged</DamageEffectName>
<DamagedSound>ParticleElectrical</DamagedSound>
Expand All @@ -67,11 +183,12 @@
<ScreenArea Name="CockpitScreen_04" DisplayName="DisplayName_Screen_BottomRight" TextureResolution="256" ScreenWidth="5" ScreenHeight="8" />
</ScreenAreas>
</Definition>

-->
<!--
<Definition xsi:type="MyObjectBuilder_TurretControlBlockDefinition">
<Id>
<TypeId>TurretControlBlock</TypeId>
<SubtypeId>SmallTurretControlBlock</SubtypeId>
<SubtypeId>SmallTurretControlBlockRadar</SubtypeId>
</Id>
<Public>true</Public>
<DisplayName>DisplayName_TurretControlBlock</DisplayName>
Expand Down Expand Up @@ -108,7 +225,7 @@
<MountPoint Side="Left" StartX="0" StartY="0" EndX="2" EndY="1" />
<MountPoint Side="Top" StartX="0" StartY="0" EndX="1" EndY="2" />
</MountPoints>
<BlockPairName>TurretControlBlock</BlockPairName>
<BlockPairName>TurretControlBlockRadar</BlockPairName>
<ResourceSinkGroup>Utility</ResourceSinkGroup>
<DamageEffectName>Damage_Electrical_Damaged</DamageEffectName>
<DamagedSound>ParticleElectrical</DamagedSound>
Expand All @@ -124,7 +241,7 @@
<ScreenAreas>
<ScreenArea Name="CockpitScreen_01" DisplayName="" TextureResolution="256" ScreenWidth="5" ScreenHeight="4" />
</ScreenAreas>
</Definition>
</Definition>-->

</CubeBlocks>
</Definitions>
36 changes: 32 additions & 4 deletions ModernWarfareGuns/Data/Main Weapons/Trebuchet.sbc
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
<Model>Models\Magazines\GrenadeCrate.mwm</Model>
<PhysicalMaterial>Ammo</PhysicalMaterial>
<Capacity>1</Capacity>
<AmmoDefinitionId Subtype="TrebuchetAmmo" />
<AmmoDefinitionId Subtype="TrebuchetAmmoAlt" />

<MinimumOfferAmount>100</MinimumOfferAmount>
<MaximumOfferAmount>1000</MaximumOfferAmount>
Expand All @@ -99,7 +99,7 @@
<BackkickForce>15000</BackkickForce>
<PhysicalMaterial>MediumShell</PhysicalMaterial>
<ExplosiveDamageMultiplier>1</ExplosiveDamageMultiplier>
<EndOfLifeEffect>Explosion_Warhead_50</EndOfLifeEffect>
<!--<EndOfLifeEffect>Explosion_Warhead_50</EndOfLifeEffect>-->
<DeathMessage>CauseOfDeath_HeavyWeapons</DeathMessage>
</BasicProperties>
<MissileProperties>
Expand All @@ -109,7 +109,7 @@
<MissileAcceleration>0</MissileAcceleration>
<MissileInitialSpeed>100</MissileInitialSpeed>
<MissileSkipAcceleration>false</MissileSkipAcceleration>
<MissileExplosionDamage>500</MissileExplosionDamage>
<MissileExplosionDamage>5000</MissileExplosionDamage>
<MissileHealthPool>500</MissileHealthPool>
<MissileTrailEffect>LargeCalibreGun_Tracer</MissileTrailEffect>
<MissileGravityEnabled>true</MissileGravityEnabled>
Expand All @@ -118,8 +118,36 @@
<MissileMinRicochetProbability>0.25</MissileMinRicochetProbability>
<MissileMaxRicochetProbability>0.85</MissileMaxRicochetProbability>
<MissileRicochetDamage>2000</MissileRicochetDamage>
<ExplosionFlags>APPLY_FORCE_AND_DAMAGE CREATE_DECALS CREATE_SHRAPNELS FORCE_CUSTOM_END_OF_LIFE_EFFECT</ExplosionFlags>
<!--<ExplosionFlags>APPLY_FORCE_AND_DAMAGE CREATE_DECALS CREATE_SHRAPNELS FORCE_CUSTOM_END_OF_LIFE_EFFECT</ExplosionFlags>-->
</MissileProperties>
</Ammo>
<Ammo xsi:type="MyObjectBuilder_MissileAmmoDefinition">
<Id>
<TypeId>AmmoDefinition</TypeId>
<SubtypeId>TrebuchetAmmoAlt</SubtypeId>
</Id>
<BasicProperties>
<DesiredSpeed>100</DesiredSpeed>
<SpeedVariance>0</SpeedVariance>
<MaxTrajectory>3000</MaxTrajectory>
<IsExplosive>true</IsExplosive>
<BackkickForce>15000</BackkickForce>
<PhysicalMaterial>Missile</PhysicalMaterial>
<ExplosiveDamageMultiplier>2</ExplosiveDamageMultiplier>
<DeathMessage>CauseOfDeath_HeavyWeapons</DeathMessage>
</BasicProperties>
<MissileProperties>
<MissileMass>45</MissileMass>
<MissileExplosionRadius>20</MissileExplosionRadius>
<MissileModelName>Models\Weapons\Projectile_Missile.mwm</MissileModelName>
<MissileAcceleration>600</MissileAcceleration>
<MissileInitialSpeed>100</MissileInitialSpeed>
<MissileTrailEffect>LargeCalibreGun_Tracer</MissileTrailEffect>
<MissileSkipAcceleration>false</MissileSkipAcceleration>
<MissileExplosionDamage>1000</MissileExplosionDamage>
<MissileGravityEnabled>true</MissileGravityEnabled>

</MissileProperties>
</Ammo>
</Ammos>
</Definitions>
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public override void UpdateBeforeSimulation()
if (ctc == null || ctc.MarkedForClose)
continue;

if (ctc.AIEnabled)
if (ctc.AIEnabled && !ctc.SlimBlock.BlockDefinition.Id.SubtypeName.Contains("Large"))
ctc.AIEnabled = false;
}
}
Expand Down

0 comments on commit abad089

Please sign in to comment.