Page 1 of 1

Re: Armored soldiers

Posted: Fri Nov 06, 2009 6:28 am
by Apache Thunder
Well you can make special kits that have spawners addTemplated to kitparts. Those spawners could then spawn special PCO objects (with dummy engines and such so you can make them stick to the spawner via holdObject) and have those PCOs absorb a certain amount of direct projectile damage before they die off exposing the soldier. It won't protect you from explosions however. But this is more realistic that way....since body armor doesn't excactly help when a granade blows up right next to you. :P

Re: Armored soldiers

Posted: Fri Nov 06, 2009 12:48 pm
by freddy
one could build a "rechargable" shield!?

Re: Armored soldiers

Posted: Fri Nov 06, 2009 11:33 pm
by LightSpeed///
Apache Thunder wrote:Well you can make special kits that have spawners addTemplated to kitparts. Those spawners could then spawn special PCO objects (with dummy engines and such so you can make them stick to the spawner via holdObject) and have those PCOs absorb a certain amount of direct projectile damage before they die off exposing the soldier. It won't protect you from explosions however. But this is more realistic that way....since body armor doesn't excactly help when a granade blows up right next to you. :P
except for dragon skin
with that stuff on you can lay on a grenade and live, you will have a bruise however

Re: Armored soldiers

Posted: Sat Nov 07, 2009 1:00 am
by Apache Thunder
freddy wrote:one could build a "rechargable" shield!?

Yes. Simply code the spawners to respawn the PCO. You can also attach a health depot that slowly heals it over time. ;)

Re: Armored soldiers

Posted: Wed Jan 04, 2017 4:18 am
by Diamondback
Apache Thunder wrote:Well you can make special kits that have spawners addTemplated to kitparts. Those spawners could then spawn special PCO objects (with dummy engines and such so you can make them stick to the spawner via holdObject) and have those PCOs absorb a certain amount of direct projectile damage before they die off exposing the soldier. It won't protect you from explosions however. But this is more realistic that way....since body armor doesn't excactly help when a granade blows up right next to you. :P
I know this is an old thread, but trying your method doesn't work. When I addTemplate the spawner to the kit part (in my case, US_Hip_Pack), nothing appears. But when I add the PCO itself to it directly, it shows up, but is not destroyable... This is my code, taken from my map's TDM folder OST.con:

ObjectSpawnTemplates.con (relevant code is in red)

ObjectTemplate.create ObjectSpawner hp50spawner
ObjectTemplate.setObjectTemplate 2 healthpack_50
ObjectTemplate.setObjectTemplate 1 healthpack_50
ObjectTemplate.MinSpawnDelay 60
ObjectTemplate.MaxSpawnDelay 80
ObjectTemplate.SpawnDelayAtStart 0
ObjectTemplate.TimeToLive 45
ObjectTemplate.Distance 40
ObjectTemplate.DamageWhenLost 10

ObjectTemplate.create ObjectSpawner sniperspawner
ObjectTemplate.setObjectTemplate 2 germanelite_scout
ObjectTemplate.setObjectTemplate 1 germanelite_scout
ObjectTemplate.MinSpawnDelay 60
ObjectTemplate.MaxSpawnDelay 80
ObjectTemplate.SpawnDelayAtStart 0
ObjectTemplate.TimeToLive 45
ObjectTemplate.Distance 40
ObjectTemplate.DamageWhenLost 10

ObjectTemplate.Active GermanSoldier
ObjectTemplate.AddTemplate hpdestroyer
ObjectTemplate.setPosition 0/0/0

ObjectTemplate.create SupplyDepot hpdestroyer
ObjectTemplate.radius 1
ObjectTemplate.team 0
ObjectTemplate.workOnVehicles 1
ObjectTemplate.workOnSoldiers 0
ObjectTemplate.AddVehicleType healthpack_50 -1 -48 0
ObjectTemplate.AddAmmoType 0 -1 -48 0

ObjectTemplate.Active USSoldier
ObjectTemplate.AddTemplate hpdestroyer
ObjectTemplate.setPosition 0/0/0

ObjectTemplate.Active US_Hip_Pack
ObjectTemplate.AddTemplate armorspawn
ObjectTemplate.setPosition -1.4/0.4/0

ObjectTemplate.create ObjectSpawner armorspawn
ObjectTemplate.setObjectTemplate 2
armor_vest
ObjectTemplate.MinSpawnDelay 25
ObjectTemplate.MaxSpawnDelay 35
ObjectTemplate.SpawnDelayAtStart 0
ObjectTemplate.TimeToLive 60
ObjectTemplate.Distance 0
ObjectTemplate.DamageWhenLost 0
ObjectTemplate.holdObject 1
ObjectTemplate.setTeam 2


The PCO highlighted in blue in the "armorspawn" spawner has the following Objects.con code:

ObjectTemplate.create PlayerControlObject armor_vest
ObjectTemplate.networkableInfo armor_vestBodyInfo
ObjectTemplate.cullRadiusScale 4.0
ObjectTemplate.hasCollisionPhysics 1
ObjectTemplate.geometry briefcase_m1
ObjectTemplate.hasResponsePhysics 1
ObjectTemplate.hasDynamicShadow 1
ObjectTemplate.explosionRadius 0
ObjectTemplate.HasArmor 1
ObjectTemplate.HitPoints 50
ObjectTemplate.MaxHitPoints 50
ObjectTemplate.Material 45
ObjectTemplate.timetoliveafterdeath 0
ObjectTemplate.setVehicleCategory VCLand
ObjectTemplate.setVehicleIcon "Empty.dds"
ObjectTemplate.setMinimapIcon "Empty.dds"
ObjectTemplate.setPcoId 0

Network.con:

NetworkableInfo.createNewInfo armor_vestBodyInfo
NetworkableInfo.setPredictionMode PMLinear