Custom Map #2943: Runners PAC. By: builder17

Started by AutoPost, December 25, 2015, 12:53:22 PM

Previous topic - Next topic

AutoPost

This topic is for discussion of map #2943: Runners PAC


Author: builder17
Size: 60x60

Desc:
#PAC #1.5 Stronger totems #Maxcreeper400 #Runners

Loren Pechtel

A bit tricky, getting spores in against those PZ beams.

Builder17

Spoiler
I recommend you build first spore tower after you rule all bases with runners.
[close]

Martin Gronsdal

after winning the map I wanted to test something and deletet digitalis. That caused all runners to die. When I remade digitalis the runners didn't start to appear again.

Why?

Builder17

Quote from: Martin Gronsdal on February 12, 2025, 09:52:56 AMafter winning the map I wanted to test something and deletet digitalis. That caused all runners to die. When I remade digitalis the runners didn't start to appear again.

Hi! So what happens is that since you don't need them anymore,
the game replaces runner nest with just a image of one.

It's required for the map to get victory,
this is true for default emitters and spore towers as well.

The code doing it, is located in GameFlow.crpl script and looks like this:

# Need to destroy creeper units to trigger victory.
# Replace them with dummy cores to make this less noticeable.
GetEnemyUnitsInRange(0 0 9999) 0 do
->unit
GetUnitType(<-unit) ->type
"image" <-type concat <-! "" concat ->image
if(<-type "SPORETOWER" eq)
if(GetScriptVar(<-unit 0 "STARTTIME") GetGameTimeFrames gt)
"CustomSporeTower" ->image
endif
endif
# Inhibitor takes all other creeper units with it, so not possible to cover.
if(<-type "INHIBITOR" eq)
Destroy(<-unit 0)
endif
if(<-image "0" neq)
GetUnitAttribute(<-unit CONST_COORDX) ->x
GetUnitAttribute(<-unit CONST_COORDY) ->y
CreateUnit("CRPLCORE" <-x <-y) ->dummyCore
SetUnitAttribute(<-dummyCore CONST_COUNTSFORVICTORY FALSE)
SetImage(<-dummyCore "Main" <-image)
Destroy(<-unit 0)
GetAllUnitsInRange(<-x <-y 0 TRUE) 0 do
if(GetUnitType(dup) "POWERZONE" eq) Destroy(0) else pop endif
loop
endif
loop

Martin Gronsdal