HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Need help with an LOTR style map

02-08-2005, 05:21 AM#1
Assassin974
alright i know this may sound really noobish to sum of you but its been very long since i used a map editor.

If you know how LOTR maps work then you know that you must create castles to spawn men. Unlike SC i cant seem to find a condition that says sumthing like "If Player cammands <X> amount of <unit>" then i put my Actions. I need to be able to increase the spawn amount every time i build a castle so if anyone has any tips pls respond.
02-08-2005, 06:32 AM#2
D0nk1ckh0t
Code:
(Number of units in (Units owned by Temp_Player of type Castle)) Greater than or equal to 3


This condition is an Integer comparison. Change Temp_Player to the player you need, and Castle to unit type you need.

However, you must be aware that creating a Unit Group (Units owned by Temp_Player of type Castle) and not removing it will cause a memory leak. Try viewing the tutorials section of the forum for info on memleaks.
02-08-2005, 08:54 PM#3
ThyFlame
Quote:
Originally Posted by D0nk1ckh0t
Code:
(Number of units in (Units owned by Temp_Player of type Castle)) Greater than or equal to 3


This condition is an Integer comparison. Change Temp_Player to the player you need, and Castle to unit type you need.

However, you must be aware that creating a Unit Group (Units owned by Temp_Player of type Castle) and not removing it will cause a memory leak. Try viewing the tutorials section of the forum for info on memleaks.


Memory leaks aren't as disasterous as you seem to believe. He'll be fine making it without plugging them. He can always go back and fix it after he learns more about map making.
02-09-2005, 03:45 AM#4
Assassin974
cool thanks a lot guys
02-10-2005, 02:21 PM#5
D0nk1ckh0t
Well, when you create lots of units like as in LotR maps, that can result in a game crash on some low-mem systems (tested on 512mb RAM and a lot of points/units leaked). So I guess it's better to worry of leaks, at least for the overall performance. And if you start fixing them before you finished your big project, it takes less time afterwards.