HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Replacing "Start position" Town halls

04-21-2003, 08:10 PM#1
Panto
Greets.

I'd like to replace the Town Hall that is created in a race's start position with a different building.

For reasons of the splat, I can't simply edit the town hall to be the building I want.

I tried this trigger to get started, but it didn't work. Can someone set me on a more accurate path?

Quote:
Event: Map Initialization
Conditions: none
Actions: Pick every unit in (Units in (Playable Map Area)) and do (If (((Triggering unit) is A structure) Equal to True) then do (Unit - Replace (Triggering unit) with a Priest using The new unit's default life and mana) else do (Do nothing))

This trigger did nothing, whereas I expected it to replace the town hall with a custom structure.
04-21-2003, 08:46 PM#2
SkylineGT[FB]
i think that u will need to change the town hall model. or make the event to time - time elapses in 0.01 seconds of game time.
04-21-2003, 09:29 PM#3
Panto
This won't be visible to the player at all before it swaps?
04-21-2003, 09:54 PM#4
Panto
Quote:
Event: Map Initialization
Conditions: none
Actions: Pick every unit in (Units in (Playable Map Area)) and do (If (((Triggering unit) is A structure) Equal to True) then do (Unit - Replace (Picked Unit) with a Priest using The new unit's default life and mana) else do (Do nothing))

Aight, I changed the Triggering Unit to Picked unit as above and it helped, but it introduced a few other problems. The results this time were as follows:

The human race player (Player 2, a computer) had his town hall replaced by the custom unit, but it did not generate the 5 peasants for that player. The custom unit that it replaced the town hall with was under my control, when it should have been under the control of Player 2. Player 1 (myself) was undead, and it did not replace my structure at all.

It seems like I must be fundamentally misinterpreting something that's going on here.

EDIT: Incidentally, why does it show everybody on here with my avatar instead of their own?
EDIT 2: If I could change the splat for each race's town hall, I could just modify those instead of replacing them. Is there a place to edit the splat info?
04-21-2003, 11:54 PM#5
Dinadan87
There were actually two instances of Triggering Unit in your action, and you only changed one. Remember you should ONLY use triggering unit when you have an EVENT that refers to a unit.
04-21-2003, 11:58 PM#6
Panto
This is a related trigger situation and it definitely seems like what I have should work. Do point out what I have off if you have a moment to help.
Quote:
Events: Unit - A unit enters (Entire Map)
Conditions: none
Actions: Special Effect - Create a special effect attached to the origin of (Triggering Unit) using blah\blah.mdl
The .mdl for the special effect is correct.
04-22-2003, 12:11 AM#7
Dinadan87
Well perhaps the event never took place. Keep in mind that in order to enter a region, a unit must be OUTSIDE of that region first. I'm not exactly sure if being created in a region count's as entering the region, try attaching a game message to the actions to troubleshoot. If the message is displayed and the effect doe snot show, then your special effect action has a flaw in it. If the message is not displayed, then your event must not have taken place and you should change it to something else.
04-22-2003, 12:44 AM#8
Panto
Excellent suggestion. I may as well begin debugging.
04-22-2003, 05:23 AM#9
rwxr-xr-x
Replace Triggering Unit with Entering Unit. Also, units that are created in a region are considered as entering that region.