[SSM] Adding Spawnpoints to PCOs
Posted: Sun Nov 21, 2021 5:26 pm
Dear friends,
I've been scrolling through a plethora of interesting server-side modding topics the last few days, like attaching a spawnpoint to a Ho-ha, adding spawnpoints to vehicles, rotating paraspawns etc. This gave me the idea to make plane airspawns for maps that do not really have room for an airfield (take Batte of the Bulge for example), so you can select a spawnpoint and spawn into a plane BF3/BF4 style.
OST.con
OS.con
I managed to get this working without bots without any trouble at all. The spawnpoint moves with the vehicle and others can even mid-air spawn into the SBD without trouble. The spawnpoint had been sourced in first place from the Gato, and later from a Fletcher and both work without any trouble, as can be seen in this video. However, as soon as I try to run this with bots (either COOP on a live server, SP on my own client or on CQ with a bot patch) its just crashes. I know bots can be funky and all, do certain unexpected things and are generally a nightmare code wise, but something like rotating paraspawns works fine, even though the difference is that this spawnpoint has been attached to a PCO and forces the player into the vehicle.
Is there a way to work around this? I'd love to have both bots and plane airspawns working within the same map. Is there a way to make it bot-friendly, or REM them out of certain things so they're only accessible for humans?
I've been scrolling through a plethora of interesting server-side modding topics the last few days, like attaching a spawnpoint to a Ho-ha, adding spawnpoints to vehicles, rotating paraspawns etc. This gave me the idea to make plane airspawns for maps that do not really have room for an airfield (take Batte of the Bulge for example), so you can select a spawnpoint and spawn into a plane BF3/BF4 style.
OST.con
Code: Select all
ObjectTemplate.create ObjectSpawner ShermanSpawner
ObjectTemplate.setObjectTemplate 2 Fletcher
ObjectTemplate.holdObject 1
ObjectTemplate.MinSpawnDelay 2
ObjectTemplate.MaxSpawnDelay 3
ObjectTemplate.SpawnDelayAtStart 0
ObjectTemplate.TimeToLive 4
ObjectTemplate.Distance 4
ObjectTemplate.DamageWhenLost 10
ObjectTemplate.MaxNrOfObjectSpawned 1
ObjectTemplate.Active Fletcher_Entry
ObjectTemplate.setEntryRadius 0
ObjectTemplate.Active FletcherDeckBrowningEntry
ObjectTemplate.setEntryRadius 0
ObjectTemplate.Active Fletcher_EntrySmall
ObjectTemplate.setEntryRadius 0
ObjectTemplate.Active Fletcher
ObjectTemplate.removeTemplate 11
ObjectTemplate.removeTemplate 10
ObjectTemplate.removeTemplate 9
ObjectTemplate.Active FletcherDriverSoldierSpawn
ObjectTemplate.group 68
ObjectTemplate.groupTeam 2
ObjectTemplate.EnableToChangeTeam 0
ObjectTemplate.Active FletcherDriverSoldierSpawn
ObjectTemplate.setEnterOnSpawn 1
ObjectTemplate.setAIEnterOnSpawn 0
ObjectTemplate.setOnlyForHuman 1
ObjectTemplate.Active SBD
ObjectTemplate.addTemplate FletcherDriverSoldierSpawn
ObjectTemplate.setPosition 0/0/0
ObjectTemplate.forwardmod 50
ObjectTemplate.Active Mustang
ObjectTemplate.addTemplate FletcherDriverSoldierSpawn
ObjectTemplate.setPosition 0/0/0
ObjectTemplate.forwardmod 50
Code: Select all
Object.create ShermanSpawner
Object.absolutePosition 891.55/1000.90/404.89
Object.rotation 0/0/0
Object.setTeam 2
Is there a way to work around this? I'd love to have both bots and plane airspawns working within the same map. Is there a way to make it bot-friendly, or REM them out of certain things so they're only accessible for humans?