SCRMaps
/
Sign in

Spawns and waves

Produce enemies on a timer, cap how many, and step the waves up.

5 min read

Attach a create action to the timer and you have a spawn. Two things matter in practice: stopping them piling up forever, and making them get harder over time.

Trigger { -- 필드에 30마리 미만일 때만 생성
	players = {P8},
	conditions = {
		Deaths(P8, AtLeast, 120, "SpawnTimer");
		Command(P8, AtMost, 30, "Zerg Zergling");
	},
	actions = {
		SetDeaths(P8, SetTo, 0, "SpawnTimer");
		CreateUnit(4, "Zerg Zergling", "Spawn Point", P8);
		PreserveTrigger();
	},
}
Command checks how many exist and caps them. Without it the map fills with units the moment nobody is hunting.

For waves, keep the wave number in a counter and give each number its own trigger.

Trigger { -- 5분마다 웨이브 +1
	players = {P8},
	conditions = {
		Deaths(P8, AtLeast, 7200, "WaveTimer");
	},
	actions = {
		SetDeaths(P8, SetTo, 0, "WaveTimer");
		SetDeaths(P8, Add, 1, "Wave");
		DisplayText("\x13\x03다음 웨이브가 시작됩니다");
		PreserveTrigger();
	},
}

Trigger { -- 웨이브 3 이상이면 더 강한 적도 같이
	players = {P8},
	conditions = {
		Deaths(P8, AtLeast, 120, "SpawnTimer");
		Deaths(P8, AtLeast, 3, "Wave");
	},
	actions = {
		CreateUnit(1, "Zerg Hydralisk", "Spawn Point", P8);
		PreserveTrigger();
	},
}

If you need several spawn points, an alternative to copying the trigger per location is to keep one spawn location and move it around with MoveLocation.

Sign in to track your progress