Custom Map #302: Siege. By: Decagon

Started by AutoPost, November 06, 2016, 04:00:01 PM

Previous topic - Next topic

AutoPost

This topic is for discussion of map #302: Siege


Author: Decagon
Size: 400x400

Desc:
Pushing further into Redacted Space, the HDF fleet teams up with a Scaffold-class battlestation to siege a hive of Particulate activity in the region. It is up to you to protect the Scaffold from the inevitable counterattack, and destroy the Particulates. MAP RULES: Do not rebuild the Scaffold's parts. If more than three sections are destroyed (legs not included), that's a loss.

GoodMorning

This loss-on-count-of-destruction is surprisingly easy to script, if you ever wish to use something similar without relying entirely on the honour system.
A narrative is a lightly-marked path to another reality.

Keeper Decagon

Quote from: GoodMorning on November 06, 2016, 07:10:34 PM
This loss-on-count-of-destruction is surprisingly easy to script, if you ever wish to use something similar without relying entirely on the honour system.

Oh? I didn't even know that was a thing I could implement. Wouldn't know how to do it, though. :P
"For me, there is no honour or glory. No praise to be had for what I do. I fulfill my purpose for the protection of all... neither of us are going to make it out of here alive." - ?? ??, 145th CE

GoodMorning

#3
It needs a bit of PRPL, but a back-of-the-envelope script:

once
CurrentCoords 2 0 GetAllShipsInRange ->Ships
<-Ships GetListCount 1 eq if
<-Ships[0] ->Ship
else
Self 0 Destroy
endif

-?*Lost not if
0->*Lost
endif

Self ->ThisUnit
<-ThisUnit "main" "NONE" SetImage #Invisible
0 ->ThisUnit.MissionGoal
0 ->ThisUnit.LatheTargets
0 ->ThisUnit.IsEnemy
0 ->ThisUnit.CreateFootprint
endonce

<-Ship.ShipIsDestroyed if
<-*Lost 1 add ->*Lost
<-*Lost 3 gt if
FailMission
endif
Self 0 Destroy
endif

IsEditMode if
"LeftShift" GetKey if
<-*Lost SetText
"R" GetKey if
0 ->*Lost
endif
endif
endif


Broken down, this finds a nearby bridge, and if there is none (or multiple) it self-destructs. It then sets a global counter for ships lost (if this hasn't already been set).

Then, each frame, it checks if the ship is dead. If so, it records that another ship is lost, and if that was one too many, you lose. Whether you lost or not, this unit self-destructs.

Hitting Shift while editing will show the number of ships recorded to have been lost. Shift-R will reset the number to 0. These assume that the input commands haven't changed since CRPL, which I believe to be the case. Also, it may be that -?* should be -*?, I don't quite recall.
A narrative is a lightly-marked path to another reality.

fumbuckle

Nice map, and that script GoodMorning mentioned is very interesting. I didn't have much threat to the station, but if the danger of it being damaged was real, a more difficult map with that rule could be fun.
Spoiler
I used my HQ to take out the bottom emitter before anything else. After the omnis took over the land on the left, I snuck them all across the bottom and onto the planet, and took over most of that while the rest of the fleet took out emitters. Then I charged the enemy stations and won. I don't know if you intended that method, but it was fun nonetheless.
[close]

Keeper Decagon

Quote from: fumbuckle on November 07, 2016, 04:40:41 AM
Nice map, and that script GoodMorning mentioned is very interesting. I didn't have much threat to the station, but if the danger of it being damaged was real, a more difficult map with that rule could be fun.
Spoiler
I used my HQ to take out the bottom emitter before anything else. After the omnis took over the land on the left, I snuck them all across the bottom and onto the planet, and took over most of that while the rest of the fleet took out emitters. Then I charged the enemy stations and won. I don't know if you intended that method, but it was fun nonetheless.
[close]

I might make a harder version of this map if people felt it was a lacking too much threat, but I didn't intend it to be particularly hard. Also
Spoiler
I used to have all the land on the enemy sides (top and bottom lands, and the planet) being mired by enemy Mire Spawners to oppose Omnis, but the lag they produced was unreal, so I removed them in favour of particle-based miring. Only thing is, that can make the map much easier without the direct miring opposition in the beginning. Still, I am not opposed to people finding new and interesting ways to beat my maps, in fact I find it rather cool to see different methods to get around them. :)
[close]

Quote from: GoodMorning on November 06, 2016, 08:14:36 PM
It needs a bit of PRPL, but a back-of-the-envelope script:

once
CurrentCoords 2 0 GetAllShipsInRange ->Ships
<-Ships GetListCount 1 eq if
<-Ships[0] ->Ship
else
Self 0 Destroy
endif

-?*Lost not if
0->*Lost
endif

Self ->ThisUnit
<-ThisUnit "main" "NONE" SetImage #Invisible
0 ->ThisUnit.MissionGoal
0 ->ThisUnit.LatheTargets
0 ->ThisUnit.IsEnemy
0 ->ThisUnit.CreateFootprint
endonce

<-Ship.ShipIsDestroyed if
<-*Lost 1 add ->*Lost
<-*Lost 3 gt if
FailMission
endif
Self 0 Destroy
endif

IsEditMode if
"LeftShift" GetKey if
<-*Lost SetText
"R" GetKey if
0 ->*Lost
endif
endif
endif


Broken down, this finds a nearby bridge, and if there is none (or multiple) it self-destructs. It then sets a global counter for ships lost (if this hasn't already been set).

Then, each frame, it checks if the ship is dead. If so, it records that another ship is lost, and if that was one too many, you lose. Whether you lost or not, this unit self-destructs.

Hitting Shift while editing will show the number of ships recorded to have been lost. Shift-R will reset the number to 0. These assume that the input commands haven't changed since CRPL, which I believe to be the case. Also, it may be that -?* should be -*?, I don't quite recall.

Interesting. I'll have to try that, though wouldn't that include all built ships rather than specific ones, like the station parts? Since losing other ships in this scenario can happen too, and I wouldn't want the mission to fail if the player loses three Frigates rather than three Scaffold sections.
"For me, there is no honour or glory. No praise to be had for what I do. I fulfill my purpose for the protection of all... neither of us are going to make it out of here alive." - ?? ??, 145th CE

4xC

Apart from having very few dischargers from start to finish, I can't say I found the opposition all that hard admittedly.

I did like the fine tuning of moving the RCs just to get both lathes in range of the flip emitters.

Also, I couldn't tell, but do the bigger benign ships spawn at the 10 minute mark or when the upper and lower ship spawners are dead?
C,C,C,C

Keeper Decagon

Quote from: 4xC on November 07, 2016, 10:19:31 AMAlso, I couldn't tell, but do the bigger benign ships spawn at the 10 minute mark or when the upper and lower ship spawners are dead?

Yup, they spawn at around 10 minutes in.
"For me, there is no honour or glory. No praise to be had for what I do. I fulfill my purpose for the protection of all... neither of us are going to make it out of here alive." - ?? ??, 145th CE

GoodMorning

That script tries to find a bridge within two cells of the middle of the Core. Therefore, you will need to place a new Core running the script over each bridge you want to count. This will take a little time, but gives you fine control over which units do/don't count toward this tally.
A narrative is a lightly-marked path to another reality.