You must be logged in to post messages.
Please login or register

Scenario Design
Moderated by MosheLevi, Mister SCP

Hop to:    
Welcome! You are not logged in. Please Login or Register.847 replies, Sticky
Age of Empires III Heaven » Forums » Scenario Design » Have a Trigger Request? Post it here!
Bottom
Topic Subject:Have a Trigger Request? Post it here!
« Previous Page  1 ··· 10 ··· 20 ··· 30 31 32 33 34  Next Page »
Mister SCP
Scenario Reviewer
posted 05-22-09 02:11 AM EDT (US)         
So you have a trigger request?

You can post it here!

    ------------------------------------------------------------ --------------------

    Hello and welcome to the Trigger Request Thread (TRT). This thread's purpose is only to place trigger requests and discuss them.


    ------------------------------------------------------------ --------------------

    Before posting your request, it's always good to read the so-called FAQ.

    How do I install a trigger?

    When we have finished making your trigger, we'll post the required code here. To install this code you will first of all need to find your way to the AOEž installation folder. C:\Program Files\Microsoft Games\Age of Empires3 by default).
    Now open the trigger folder if you use vanilla -trigger1, if you use TWC -trigger2, and finally if you use TAD go to -trigger3.
    Next, open the file called typetest.xml. The only thing left to do is copy the code at the right position and save. If you requested a condition, then place the line above ,
    if you requested an effect paste it right above . Note the "s" at the end of both tags.

    Notes:

  • When copying the trigger from someone please click first and only then copy the required code.

  • If you're still uncomfortable with installing triggers please backup the original typetest file, i.e. copy the original to another folder.

    How do I uninstall a trigger?
    If a trigger happens to be faulty or if it generates errors you better remove it. Just do as if you were installing a new trigger, but instead of copy-pasting new code, remove the code corresponding with the chosen trigger. Make sure to remove it completely, including the starting < effect > or < condition > tag and the corresponding < /effect > or < /condition > closing tag. Failure to do so properly will cause XML errors in the file making ALL triggers in that file inaccessbile for AoM.


    Help! My triggers have stopped working! If this doesnt help you can send an email including your scenario to mister.scp@gmail.com.


    ------------------------------------------------------------ --------------------

    Recommended Downloads:
    -Advanced Trigger Set
    -My Trigger Set
    -Gunner`s Trigger Set
    -Random22`s Trigger Set
    -Hedanito`s Trigger Set
    -Kolt`S Trigger Set
    -SH Trigger
    -M925's Trigger Set

    ------------------------------------------------------------ --------------------


    Posting a Request

    So you have read the FAQ and want to post a request? OK, go for it, just be sure to use the following format:

    Name - This should be as straightforward as possible. Try to comply with today's standards.Description - Always describe the actions that you want the trigger to perform. An example can be a great help when requesting complex triggers.

    [b]Name[/b]
    [b]Description[/b]
    [b]Params[/b]
    (A List of Params. If you are pretty nice you set them in the context with your request.)


    Unfinished Requests

    -a lot

    Finished Requests
    -even more (list isnt up to date)

    Not Possible:
    -Fixing Modify Protounit
    -Fixing Chat Contain
    -Change name of the protounit which affect also the name when you train it
    ------------------------------------------------------------ --------------------
    Additional: XS - Basics (mostly based on pftq's guide for XS - Effects + Conditions)

    XS - Triggers are a bit different from other triggers, since they use strings instead for e.g. PlayerID, Unit Select...
    The key highlight of these effects/conditions is to allow Unit Selections to be specified by number or QV. This makes great use of the effects which set QV to an OBJECT ID and opens up a whole new world of possibilites.

    This includes all original and new effects/conditions with ALL appliable fields set to use ANY form of data, including but not limited to:
  • -- Quest Var Code: enter trQuestVarGet("QVNAME")
  • -- Player Stats: enter trGetStatValue(PLAYER, STATID_NUMBER) e.g. trGetStatValue(1, 2)-> count "Enemy Units Killed" for Player 1
  • -- Math Operations: (5*PlayerStat) ...allowed are + - * / as Math Operations
  • -- Any XS Code: (just open the typetest.xml and start digging!)

    typical strings: (strings with * have additional informations on the bottom)
  • Amount (of resources), Radius, Headings, Duration, Damage Percent, Count (e.g. in Army Deploy), Rate (e.g. of Construction), Value
  • the table of PlayerID┤s is a string
  • Operators* (don't use any numbers for them!)
  • Center Unit OBJECT ID/Source Unit OBJECT ID/Target Unit OBJECT ID **
  • Unit Type ID /ProtounitID ***



  • *Operators you can use are:
    == equal to
    >= equal to or higher
    <= equal to or lower
    > higher
    < lower
    != is not equal to

  • **The Unit Selections require an OBJECT ID. This is NOT the same as a NAME ID (like in Reyk's triggers). To find an OBJECT ID, use the supplied "QV Set.. OBJECT ID" effects OR select a unit and open the "Object Info" window. Open the Object Debug Info Window if you are using Age of Empires III and the ID is not readily available in the "Object Info".


    The first amount show you the Unit ID, every unit have a unique one. The third amount show you the Unit Type ID/ Protounit ID. Every MercJaeger have the ProtounitID -387-. Note that you can select ALL Units with Unit ID's but not even all with Protounit ID like cinematic blocks.

    1. ***TO USE NAME IDS: If you have the Name ID of a unit, you can convert it to OBJECT ID by using the kbGetBlockID("") function.
    2. ***For string (text) IDs, example: kbGetBlockID("ThisIsMyUnit")
    3. ***For QV, example: kbGetBlockID(""+trQuestVarGet("ThisIsMyQV"))
    4. ***For # NAME ID, example: kbGetBlockID("NUMBER")
      *** Generally, you can use kbGetBlockID(""+ID) for all, except text. As said above, enclose the text entirely with the quotes.


~MisterSCP


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 08-21-2011 @ 03:07 AM).]

AuthorReplies:
Titan Joker
Skirmisher
posted 06-10-13 02:02 PM EDT (US)     776 / 847       
Wow! Thanks for the trick scp! Never tought it could be done that easily without a new trigger.
musketeer925
Skirmisher
posted 06-10-13 02:24 PM EDT (US)     777 / 847       
I didn't know you could define a portrait with those, very cool.
anterior2
Scenario Design Expert
posted 07-03-13 01:49 AM EDT (US)     778 / 847       
Is it possible to maybe set a unique unit ID (like a number or something that identifies one particular unit on the map) and spawn a unit with that unique ID?

And would it be possible to have an 'Is Dead for Unit ID' condition.

This would let us spawn a unit with a unique ID, then detect if it is dead or not, so that we do not have to place the unit in the editor.

StormComing (to me): "Seems like you're way under-ranked"

Check out my series of guides for the scenario editor in the link below! | Best Otto TR score

The definitive collection of my scenarios, along with my scenario editor walkthrough, recorded games, and much much more!
Mister SCP
Scenario Reviewer
posted 07-03-13 02:22 AM EDT (US)     779 / 847       
Army deploy + army is dead is your way to go. Everything were a special unit is required works well with army triggers


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack
anterior2
Scenario Design Expert
posted 07-03-13 02:26 AM EDT (US)     780 / 847       
Yeah but I was thinking it to use it multiple times.

Like:

>Spawn unit
>Unit Dies, triggers effect
>Unit spawns again with the same unique ID
>When that dies trigger the same effect again
>Spawn another unit with same unique ID

etc etc etc


Basically so that an effect can be triggered multiple times by deleting a unit that just keeps re-appearing.

StormComing (to me): "Seems like you're way under-ranked"

Check out my series of guides for the scenario editor in the link below! | Best Otto TR score

The definitive collection of my scenarios, along with my scenario editor walkthrough, recorded games, and much much more!
Mister SCP
Scenario Reviewer
posted 07-03-13 05:01 AM EDT (US)     781 / 847       
Trigger1

Always

Army deploy ( clear existing units =true).
Fire event (Trigger2)

Trigger2:

Army is dead

Fire event (Trigger1)

That should do the job


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack
anterior2
Scenario Design Expert
posted 07-03-13 11:28 PM EDT (US)     782 / 847       
Thanks, I got it working with:

Trigger 1: Active

Conditions: Always

Effects: Army Deploy


Trigger 2: Active, Loop

Conditions: Army is Dead

Effects: Fire Event, Unit Create (so I can see it is working).


With this I managed to get it working where you can delete a 'shop unit' over and over to get 1 Abus Gun each time.

There was a bit of lag though (even in single player), there is like a full second delay between the unit being deleted, the unit being granted, and the army respawning.

StormComing (to me): "Seems like you're way under-ranked"

Check out my series of guides for the scenario editor in the link below! | Best Otto TR score

The definitive collection of my scenarios, along with my scenario editor walkthrough, recorded games, and much much more!
Mister SCP
Scenario Reviewer
posted 07-04-13 00:48 AM EDT (US)     783 / 847       
Maybe you want to increase the priorities!


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack
vincentkaka
Skirmisher
posted 10-18-13 12:05 PM EDT (US)     784 / 847       
I need to know how to change a villagers health lets say the villager has 50 health i want the villager to start with 200 health

then

I want the villager to lose 50 health every minute and if he reaches 0 he dies this has to be continuous nonstop the idea is to survive im making a wilderness survival map

then

I want the villager to gain 1 food for every 5 seconds of berry foraging 5 food every five seconds fishing and 10 food for every 5 seconds hunting

then

I want the villager to gain 1 health for every 1 food collected

whether or not it will be with those exact numbers im not sure but i need to understand how to do the triggers correctly for these concepts
Mister SCP
Scenario Reviewer
posted 10-19-13 04:57 AM EDT (US)     785 / 847       
I need to know how to change a villagers health lets say the villager has 50 health i want the villager to start with 200 health
Modify Protounit
-Settler
-HP
-+150
I want the villager to lose 50 health every minute and if he reaches 0 he dies this has to be continuous nonstop the idea is to survive im making a wilderness survival map
trigger:active, looped
condtion: timer =50 secs
Effect: Damage Units in Area
-Settler
-50
-high number like 1000 for the area
I want the villager to gain 1 food for every 5 seconds of berry foraging 5 food every five seconds fishing and 10 food for every 5 seconds hunting
yo might use some techs to increase the gather rates with the "Set tech status" effect
I want the villager to gain 1 health for every 1 food collected
This is tricky. I would rather recommend to use the damage units in area with a flexible amount

Like:
50-(food/villager count) =damage
One would need to develop a new trigger which would take away the food.

The problem about gaining health is that the real "heal" trigger doesnt work in MP and the MP solution disturbs your unit selection


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack
Seph29
Skirmisher
posted 04-25-14 10:43 AM EDT (US)     786 / 847       
Hi, I was thinking of a trigger to create invisible player-selective gates.. any idea?

[This message has been edited by Seph29 (edited 04-25-2014 @ 10:44 AM).]

Mister SCP
Scenario Reviewer
posted 04-25-14 12:44 PM EDT (US)     787 / 847       
you can turn the gate 180░ in the ground to make it invisible.

http://zippy.gfycat.com/MerryAridAustralianfreshwatercrocodile.webm


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 04-25-2014 @ 03:14 PM).]

Seph29
Skirmisher
posted 04-25-14 04:02 PM EDT (US)     788 / 847       
thank you. that shd work, but i don't have that function in my editor. I tried to look around but couldn't find the download. what is it?

nevermind, I see I can do it doing ctrl+up/down with this mod
http://aoe3.heavengames.com/downloads/showfile.php?fileid=187&ci=4b8480e2d1a66e38f95e5fe5912981fcYToxOntpOjA7YToyOntpOjA7czoxNDoiU2VhcmNoIFJlc3VsdHMiO2k6MTtzOjM2OiJsaXN0ZXIucGhwP3N0YXJ0PTAmYW1wO3NlYXJjaD1yb3RhdGUiO319


But unfortunately, I need these gates to be temporary, and when i change it into a cinematic block and change it back again, they are not turned into the ground anymore...
On the other hand, I've thought I could just convert those gates to Gaia and make every player allied with gaia so It should be like none gate is there, but for some reason units cant get through. Is the same bug from here? http://aoe3.heavengames.com/cgi-bin/forums/display.cgi?action=ct&f=12,38581,,all

Like I said I cant change them to cin block anyway..

Perhaps it would be possible with a custom trigger that hides the gate into the ground again?
I've tried defining position vector and modifying Z value and creating a new unit at that vector, but doesnt work as the gate is created on the surface. Trying to teleport instead causes me triggerlock.


---------


Well, I've given up with that, just made some visible gates.

Would it be possible to have a custom effect like QV set Unit Owner in Area ? It would be really useful to cut the number of triggers I'd need to do.
It should be able to store the Player number of a specific unit type which comes close to a certain center unit. thx a lot

[This message has been edited by Seph29 (edited 04-26-2014 @ 02:11 PM).]

Mister SCP
Scenario Reviewer
posted 04-26-14 03:58 PM EDT (US)     789 / 847       
hm that shouldnt be possible. The doors will behave like Player 1 doors as long as the unit does not change to another one.

Idea 2: what are you trying to do? Are you Making a King of the hill gate? Whicha utomaticly converts?
we have a lot of stuff

Autoconverter (unit works like a herdanimal)
QV set unit count in area
...


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 04-26-2014 @ 04:03 PM).]

Seph29
Skirmisher
posted 04-27-14 05:06 PM EDT (US)     790 / 847       
Kind of, the difference is that only one specific unit type should be able to convert the gate.
i.e., players can use only war dogs to get the gates.
Is there a way to do this with just one trigger per gate?
Mister SCP
Scenario Reviewer
posted 04-30-14 01:07 AM EDT (US)     791 / 847       
sorry for the late reply

#1: Trigger1
Condition Always
Effect
Typeloader 6.0
http://aoe3.heavengames.com/downloads/showfile.php?fileid=2419
Note: Rule of thumb-> all effects and conditions which have this *TL* in the name require the typeloader 6.0 . Pls just use these functions after you have created a trigger with typeloader 6.0 as this one defines a huge bundle of functions (Basic Math, Counting Units, Arrays, functions to work with text,...)

#2 Trigger: Convert_MY_GATE(for each gate one seperate trigger)
Condition: Timer 1-3 secs
Effect
Converter Tool v2 *TL*
http://aoe3.heavengames.com/downloads/showfile.php?fileid=2902&f=2
-you can choose source unit
-maximum unit distance
-which unit type can convert

it will convert the unit to the player with the most units of this type within the range


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 04-30-2014 @ 01:12 AM).]

anterior2
Scenario Design Expert
posted 05-31-14 11:49 PM EDT (US)     792 / 847       
Hi, I am confused about some triggers I have (from the R22 trigger pack). The names are confusing:

"Unforbid and Disable Units For All" and "Forbid and Enable Units For All" sound very contradictory. Can you tell me what they actually do please?
<Effect name="Unforbid and Disable Units For All">
<Param name="ProtoUnit1" dispName="Unit 1" VarType="protounit">default</Param>
<Param name="ProtoUnit2" dispName="Unit 2" VarType="protounit">default</Param>
<Param name="ProtoUnit3" dispName="Unit 3" VarType="protounit">default</Param>
<Param name="ProtoUnit4" dispName="Unit 4" VarType="protounit">default</Param>
<Param name="ProtoUnit5" dispName="Unit 5" VarType="protounit">default</Param>
<Param name="ProtoUnit6" dispName="Unit 6" VarType="protounit">default</Param>
<Param name="ProtoUnit7" dispName="Unit 7" VarType="protounit">default</Param>
<Param name="ProtoUnit8" dispName="Unit 8" VarType="protounit">default</Param>
<Command>trUnforbidProtounit(1, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(1, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(1, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(1, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(1, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(1, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(1, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(1, "%ProtoUnit8%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(2, "%ProtoUnit8%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(3, "%ProtoUnit8%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(4, "%ProtoUnit8%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(5, "%ProtoUnit8%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(6, "%ProtoUnit8%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(7, "%ProtoUnit8%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit1%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit2%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit3%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit4%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit5%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit6%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit7%");</Command>
<Command>trUnforbidProtounit(8, "%ProtoUnit8%");</Command>
</Effect>



and
<Effect name="Forbid and Enable Units For All">
<Param name="ProtoUnit1" dispName="Unit 1" VarType="protounit">default</Param>
<Param name="ProtoUnit2" dispName="Unit 2" VarType="protounit">default</Param>
<Param name="ProtoUnit3" dispName="Unit 3" VarType="protounit">default</Param>
<Param name="ProtoUnit4" dispName="Unit 4" VarType="protounit">default</Param>
<Param name="ProtoUnit5" dispName="Unit 5" VarType="protounit">default</Param>
<Param name="ProtoUnit6" dispName="Unit 6" VarType="protounit">default</Param>
<Param name="ProtoUnit7" dispName="Unit 7" VarType="protounit">default</Param>
<Param name="ProtoUnit8" dispName="Unit 8" VarType="protounit">default</Param>
<Command>trForbidProtounit(1, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(1, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(1, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(1, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(1, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(1, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(1, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(1, "%ProtoUnit8%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(2, "%ProtoUnit8%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(3, "%ProtoUnit8%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(4, "%ProtoUnit8%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(5, "%ProtoUnit8%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(6, "%ProtoUnit8%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(7, "%ProtoUnit8%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit1%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit2%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit3%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit4%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit5%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit6%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit7%");</Command>
<Command>trForbidProtounit(8, "%ProtoUnit8%");</Command>
</Effect>

StormComing (to me): "Seems like you're way under-ranked"

Check out my series of guides for the scenario editor in the link below! | Best Otto TR score

The definitive collection of my scenarios, along with my scenario editor walkthrough, recorded games, and much much more!
Mister SCP
Scenario Reviewer
posted 06-01-14 00:43 AM EDT (US)     793 / 847       
they will forbid OR enable all units you have filled in the parameters for all [players]


Example

trForbidProtounit(1, "%ProtoUnit1%");

where 1 is the PlayerID and %Protounit% is the Placeholder for your custom Protounit. The Placeholders are marked with percent signs and have to be filled in via the parameters by the user of the editor


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 06-01-2014 @ 00:50 AM).]

Seph29
Skirmisher
posted 06-06-14 06:54 PM EDT (US)     794 / 847       
Thank you MisterSCP for my last request. That did the job. I have one more trigger effect I'd like to request. Basically I need a combination of the Unit Create At Protounit and Unit Create Proto QV effects. So, it should just be like the unit create at protounit effect, but with the Object Unit (not the target ) Proto ID specifiable with a QV. Thanks in advance.

Edit: I tried to make it myself. Does it look good? It must be wrong somewhere since it doesnt work..

<Effect name="Unit Create Proto QV At Protounit">
<Param name="PlayerID" varType="string" dispName="Object Player">0</Param>
<Param name="QV1" dispName="Object Unit Proto ID" varType="string">QV1</Param>
<Param name="Heading" varType="string" dispName="Object Heading">0</Param>
<Param name="Target" varType="protounit" dispName="Target Protounit">Villager</Param>
<Param name="PlayerID2" varType="string" dispName="Target Player">0</Param>
<Param name="Condition" varType="bool" dispName="Target Alive/Dead">true</Param>
<Command>for(Qid=1;>0) {}</Command>
<Command>xsSetContextPlayer(%PlayerID2%);</Command>
<Command>kbLookAtAllUnitsOnMap();</Command>
<Command>Qid=kbUnitQueryCreate("QueryProtounit");</Command>
<Command>kbUnitQuerySetPlayerID(Qid, %PlayerID2%, true);</Command>
<Command>kbUnitQuerySetUnitType(Qid, kbGetProtoUnitID("%Target%"));</Command>
<Command>if(%Condition%==true)kbUnitQuerySetState(Qid, 2);</Command>
<Command>else kbUnitQuerySetState(Qid, 4);</Command>
<Command>for(i=kbUnitQueryExecute(Qid)-1;>-1)</Command>
<Command>trUnitCreate(""+kbGetProtoUnitName(trQuestVarGet("%QV1%")), "default", xsVectorGetX(kbUnitGetPosition(kbUnitQueryGetResult(Qid, i))),xsVectorGetY(kbUnitGetPosition(kbUnitQueryGetResult(Qid, i))),xsVectorGetZ(kbUnitGetPosition(kbUnitQueryGetResult(Qid, i))), %Heading%, %PlayerID%);</Command>

</Effect>

btw, what does the "Heading" param do?

[This message has been edited by Seph29 (edited 06-06-2014 @ 08:00 PM).]

Mister SCP
Scenario Reviewer
posted 06-07-14 00:29 AM EDT (US)     795 / 847       
Heading measn inj which angle the spawned unit should look like, but it doesnt work so its a common practice to set it as 0

doesnt this triggerr you posted do the job?


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 06-07-2014 @ 00:46 AM).]

Seph29
Skirmisher
posted 06-07-14 03:01 AM EDT (US)     796 / 847       
Nope, what happens to me is that the scenario fails to load and im sent back to the editor's default blank map.

I can't find out what is wrong....maybe we can rather do it with something army related? Don't know.

[This message has been edited by Seph29 (edited 06-07-2014 @ 11:05 AM).]

Mister SCP
Scenario Reviewer
posted 06-07-14 11:21 AM EDT (US)     797 / 847       
well the maximum that should happen that none of your triggers is working. Can you test it on a blanc scenario (few units on it)


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 06-07-2014 @ 11:22 AM).]

Seph29
Skirmisher
posted 06-07-14 11:59 AM EDT (US)     798 / 847       
I did test it many times also in a new blank map and everytime i tried to use it I had a message saying the scenario failed to load...and then back to the default map. weird...

So I thought of an alternative way:
-create an (empty) army
-use the army deploy and save ids effect
-extract the target position from the array
-use this custom effect to deploy the object unit to the target position

<Effect name="XS - Army Deploy Proto QV Relative to Object (ID)">
<Param name="ID" dispName="Object ID" varType="string">default</Param>
<Param name="SrcArmy" dispName="$$22348$$Army" VarType="group">default</Param>
<Param name="QV1" dispName="QV Proto ID" varType="string">QV1</Param>
<Param name="Count" dispName="$$22435$$Count" varType="string">0</Param>
<Param name="DistX" dispName="Distance X" varType="string">5</Param>
<Param name="DistZ" dispName="Distance Z" varType="string">5</Param>
<Param name="Clear" dispName="$$22464$$Clear Existing Units:" varType="bool">true</Param>
<Command>xsSetContextPlayer(xsVectorGetX(vector(%SrcArmy%,0)));</Command>
<Command>kbLookAtAllUnitsOnMap();</Command>
<Command>trQuestVarSet("OffsetPositionX", xsVectorGetX(kbUnitGetPosition(trQuestVarGet("%ID%"))) + %DistX%);</Command>
<Command>trQuestVarSet("OffsetPositionZ", xsVectorGetZ(kbUnitGetPosition((trQuestVarGet("%ID%"))) + %DistZ%);</Command>
<Command>trArmyDispatch("%SrcArmy%",""+kbGetProtoUnitName(trQuestVarGet("%QV1%")), %Count%, trQuestVarGet("OffsetPositionX"),0,trQuestVarGet("OffsetPositionZ"), 0, %Clear%);</Command>
</Effect>

I believe I made something wrong...the location part i guess.
I tested this with this map: http://www.mediafire.com/download/izyc0u595ac530i/Test_unit_at_protounit.age3scn

Nothing happens for now ^^

[This message has been edited by Seph29 (edited 06-07-2014 @ 12:55 PM).]

Mister SCP
Scenario Reviewer
posted 06-08-14 12:44 PM EDT (US)     799 / 847       
so i tested your first trigger after i did some minor changes and it worked very well

<Effect name="Unit Create Proto QV At Protounit">
<Param name="PlayerID" varType="string" dispName="Object Player">0</Param>
<Param name="QV1" dispName="Object Unit Proto ID" varType="string">QV1</Param>
<Param name="Target" varType="protounit" dispName="Target Protounit">Villager</Param>
<Param name="PlayerID2" varType="string" dispName="Target Player">0</Param>
<Param name="Condition" varType="bool" dispName="Target Alive/Dead">true</Param>
<Command>for(Qid=1;>0) {}</Command>
<Command>xsSetContextPlayer(%PlayerID2%);</Command>
<Command>kbLookAtAllUnitsOnMap();</Command>
<Command>Qid=kbUnitQueryCreate("QueryProtounit");</Command>
<Command>kbUnitQuerySetPlayerID(Qid, %PlayerID2%, true);</Command>
<Command>kbUnitQuerySetUnitType(Qid, kbGetProtoUnitID("%Target%"));</Command>
<Command>if(%Condition%==true)kbUnitQuerySetState(Qid, 2);</Command>
<Command>else kbUnitQuerySetState(Qid, 4);</Command>
<Command>for(i=kbUnitQueryExecute(Qid)-1;>-1)</Command>
<Command>trUnitCreate(""+kbGetProtoUnitName(trQuestVarGet("%QV1%")), "default", xsVectorGetX(kbUnitGetPosition(kbUnitQueryGetResult(Qid, i))),0,xsVectorGetZ(kbUnitGetPosition(kbUnitQueryGetResult(Qid, i))), 0, %PlayerID%);</Command>

</Effect>

The remaining question is your parameter for the QV

How i did the test:
First created some abus guns for player 1;
Then i userd this parameters
-object Player ID =2
-Object Unit ID (QV) = the QV was set to 560 first which means Abusgun
-target Unit: Abus Guns
-target Player: 1
-dead or alive: alive


ESO2 Name:Sir_ConstantinESO Name:Sir_Pacman
Trigger Freak and Modder for AOE3

SCP Editor Tools---my map pack---Some incomplete stuff
My trigger Pack

[This message has been edited by Mister SCP (edited 06-08-2014 @ 12:48 PM).]

Seph29
Skirmisher
posted 06-08-14 03:34 PM EDT (US)     800 / 847       
Weird...I did exactly the same test but I can't get it to work. Now the scenario loads but the trigger fails to create the units...what i get it is just the game being slowed down remarkably.

Here I've uploaded my test map http://www.mediafire.com/download/26vyvfwjr9l6o93/Test_unit_at_protounit.age3scn

Nevermind, I found out the problem. Looks like for my game 560 is not the ID for AbusGun, but rather something invisible or nothing at all. But if i use triggers to get the proto QV it works wonderfully. Thanks again

[This message has been edited by Seph29 (edited 06-08-2014 @ 04:42 PM).]

« Previous Page  1 ··· 10 ··· 20 ··· 30 31 32 33 34  Next Page »
You must be logged in to post messages.
Please login or register

Hop to:    

Age of Empires III Heaven | HeavenGames