p u l s e
  • p u l s e
  • 65% (Friendly)
  • Private Topic Starter
17 years ago
okay, first of all i would like to thank u for all your help on my map, red canal.

Heres problem:

I am trying to make a capture the flag map, where each team must guard their flag. Once their flag is destroyed they lose, so the must protect it with their life. I have tried many things but i cannont transfer statues or flags to a specific team. Even if i could, i can't even make them targetable. Any help would be appreciated.
« p u l s e »
Sponsor
Drummin
17 years ago
You can transform just about any unit to a team. In or order to do so, you need to load AI skirmish scripts into your map. See my "Capture The Hill" tutorial. It has the AI Scripts and might also give you some ideas. I believe the AI will attack a flag or civilian unit if it belongs to an enemy. See if you can make the transfer of ownership to the player and work from there.

I would probably use a script like...

*** IF ***
Player '' starting position is 1 .
*** THEN ***
Unit 'Flag1' is transferred to the command of Player ''
p u l s e
  • p u l s e
  • 65% (Friendly)
  • Private Topic Starter
17 years ago
Okay heres what i have. i am trying to transfer a gla statue to each player. Why won't this work?

*** IF ***
Player '' has units in area 'Transfer Area 1'.
*** THEN ***
Unit 'Flag 1' is transferred to the command of Player ''

« p u l s e »
krit
  • krit
  • 100% (Exalted)
  • Commander in Chief
17 years ago
See Section 2 and Section 4 of my new tutorial. 
UserPostedImage 
Drummin
17 years ago
, if in the PlyrCivilian folder would be player teamcivilian and NOT the Local player.
***
Yes, Krit has some great info regarding making the transfer to the players, so check that out.

I was looking into your idea and found that some units a just not targetable. One unit though that is targetable and would really need to be guarded in a Nuke Test Object.

I put together a two player test map.
You might find some of the scripting helpful.
Note: I've only modified USA for attack priorities and defensive actions.


Download Attachment: UserPostedImage TwoFlagVersion1.zip 
175.08 KB
p u l s e
  • p u l s e
  • 65% (Friendly)
  • Private Topic Starter
17 years ago
thanks krit that actually worked. i was surprised, cause i never saw so many question marks in my life on scripts. and could get your map to load drummin, the scripts wouldnt open. here is my map, i think it turned out pretty good. each person gets one statue, if your statue dies, you lose, or if your destroyed you lose.

Download Attachment: UserPostedImage Protect Your Statue-Mini Map {NotDeadYet}.zip 
16.16 KB
« p u l s e »
krit
  • krit
  • 100% (Exalted)
  • Commander in Chief
17 years ago
You could still add alot more details and map props in there and maybe make the mountain areas impassable because I could simply place a few Tomahawks up there and already completely own one player...

EDIT: Oh, and one problem with your map: Currently, you have fixed Flag 1 to Player 1, this means that if another player starts at Starting Position 1 and destroys Flag 1, Player 1 will be defeated despite not owning the flag. Same applies to Flag 2, Flag 3 and Flag 4, fixed to Player 2, Player 3 and Player 4, respectively.
UserPostedImage 
Drummin
17 years ago
Hello Pulse and Krit,
I took the liberty of fixing the defeat scripts as you had mentioned Krit. It gave me a change to get to understand this type of scripting better.

Download Attachment: UserPostedImage Protect Your Statue-Mini Map1.1 {NotDeadYet}.zip 
16.3 KB
krit
  • krit
  • 100% (Exalted)
  • Commander in Chief
17 years ago
I can't check those scripts right now since I don't have access to WorldBuilder from where I am.

EDIT: Checked it. Yup, that should work correctly for all players.
UserPostedImage