|
|
Vlaad
Admirable
Legendary Hero
ghost of the past
|
posted May 08, 2005 08:00 PM |
|
Edited By: Vlaad on 8 May 2005
|
Quote: The full AI movement control doesn't always work as well as it should (AI receiver). I tried to use it in THUNK to control the THUNK and it didn't work. But the standard patrol radius works fine.
I haven't studied this section much, but I remember I used this simple script in my Gelu's Legacy 2 map:
ZVSE
!?OB65/112/0; hero visits "Outpost" object
!!IF:M^Your troops found the outpost completely destroyed, and the foul stench of the undead was all around you. Silence filled the air, and time stopped. Then you realized it was a trap!^;
Comment: while testing, I noticed the game froze for a moment before the AI took any action, so I included that "feature" in the text message!
!!HE-1:W0; hero must wait for the AI to attack
!!UN: O58/119/0;
!!UN: O59/116/0;
!!UN: O64/118/0;
!!UN: O68/116/0;
delete nearby rocks to free the AI heroes
!!AI:S-1/5/1/65/112/0/5000000/3;
Now, I cannot remember the parameters by heart, but it looks funny. I guess this high number made the AI realize it was reeeeaaaally important to attack!
____________
|
|
numi
Hired Hero
|
posted May 08, 2005 08:04 PM |
|
|
seems to me the easiest way to keep a particular hero or player from attacking another particular hero or player, is to make sure the second player's heroes aren't there. example: at start of the turn of enemy you can hide from, kill all your heroes use HE:K; if you own a town, then you're still in game. just make sure to store which heroes you had and where they were before killing them. at start of your turn on the turn of any player who can see through your 'stealth', return your heroes to field. i think HE can do this. make sure to check the spots you're placing them on for enemy heroes or spawned monsters first. if you don't own a town, use HE; to move your heroes to some isolated place you've built just for this purpose.
hmm... to keep enemies and spawned monsters from being where your hero was, you could use TR to make that square impassable while your hero is 'dead'...
|
|
fnord
Promising
Famous Hero
|
posted May 08, 2005 08:46 PM |
|
Edited By: fnord on 8 May 2005
|
Quote:
Quote: The full AI movement control doesn't always work as well as it should (AI receiver). I tried to use it in THUNK to control the THUNK and it didn't work. But the standard patrol radius works fine.
I haven't studied this section much, but I remember I used this simple script in my Gelu's Legacy 2 map:
ZVSE
!?OB65/112/0; hero visits "Outpost" object
!!IF:M^Your troops found the outpost completely destroyed, and the foul stench of the undead was all around you. Silence filled the air, and time stopped. Then you realized it was a trap!^;
Comment: while testing, I noticed the game froze for a moment before the AI took any action, so I included that "feature" in the text message!
!!HE-1:W0; hero must wait for the AI to attack
!!UN: O58/119/0;
!!UN: O59/116/0;
!!UN: O64/118/0;
!!UN: O68/116/0;
delete nearby rocks to free the AI heroes
!!AI:S-1/5/1/65/112/0/5000000/3;
Now, I cannot remember the parameters by heart, but it looks funny. I guess this high number made the AI realize it was reeeeaaaally important to attack!
Working in the pause is clever. Yes, the AI receiver does work but not always. It depends on the map and situation, and if it's too complex it doesn't seem to work. I think in the case of the THUNK map, the THUNK may have been too powerful to control or something...I'm not really sure but I tried a bunch of stuff and it wouldn't work, despite the AI command working okay on test maps. It's good that you found a use for it in your map.
____________
|
|
fnord
Promising
Famous Hero
|
posted May 08, 2005 08:51 PM |
|
|
Quote: seems to me the easiest way to keep a particular hero or player from attacking another particular hero or player, is to make sure the second player's heroes aren't there. example: at start of the turn of enemy you can hide from, kill all your heroes use HE:K; if you own a town, then you're still in game. just make sure to store which heroes you had and where they were before killing them. at start of your turn on the turn of any player who can see through your 'stealth', return your heroes to field. i think HE can do this. make sure to check the spots you're placing them on for enemy heroes or spawned monsters first. if you don't own a town, use HE; to move your heroes to some isolated place you've built just for this purpose.
hmm... to keep enemies and spawned monsters from being where your hero was, you could use TR to make that square impassable while your hero is 'dead'...
Well...those are definitely alternative ways but I don't think they're the easiest ways. The HO receiver is specifically designed for stopping a hero being attacked, so personally, I think it's still the easiest to use.
Another alternative way would be to change the ownership of a hero so that the AI owns it on its turn, while at the same time giving it a 0 patrol radius. Actually, that might not be so good because then the AI could steal your troops and artifacts. So I guess it's better to stick with HO after all.
____________
|
|
Vlaad
Admirable
Legendary Hero
ghost of the past
|
posted May 08, 2005 10:07 PM |
|
Edited By: Vlaad on 8 May 2005
|
Quote: example: at start of the turn of enemy you can hide from, kill all your heroes use HE:K;...
I tried out your suggestion and it worked, but the problem was all my heroes became undead.
____________
|
|
Vlaad
Admirable
Legendary Hero
ghost of the past
|
posted May 08, 2005 10:09 PM |
|
Edited By: Vlaad on 12 May 2005
|
Just kidding, of course.
Update:
Everything else works fine now, except this script:
Random 8 level dwelling
ZVSE
!?OB34/36/0;
!!HE-1:B2/v44; check class
!!UN&v44=0:I3/3/0/17/80; place dwelling
!!UN&v44=1:I3/3/0/17/80;
!!UN&v44=2:I2/3/0/17/81;
!!UN&v44=3:I2/3/0/17/81;
!!UN&v44=4:I2/3/0/17/82;
!!UN&v44=5:I2/3/0/17/82;
!!UN&v44=6:I2/3/0/17/83;
!!UN&v44=7:I2/3/0/17/83;
!!UN&v44=8:I3/3/0/17/84;
!!UN&v44=9:I3/3/0/17/84;
!!UN&v44=10:I3/3/0/17/85;
!!UN&v44=11:I3/3/0/17/85;
!!UN&v44=12:I3/3/0/17/86;
!!UN&v44=13:I3/3/0/17/86;
!!UN&v44=14:I2/3/0/17/87;
!!UN&v44=15:I2/3/0/17/87;
!!UN&v44=16:I3/3/0/17/88;
!!UN&v44=17:I3/3/0/17/88;
The problem is I always get Portal of Splendor, no matter what class I am.
By the way, how do you make it shorter? I am sure I could combine those lines...
P.S. I had to check the artifact in a different way:
...
!!HE-1:A2/144/0/?v33;
!!IF&v33=1:M^%Z400, you seem to have the Invisible Cloak equipped? Perhaps you are the one we have been waiting for.^;
____________
|
|
fnord
Promising
Famous Hero
|
posted May 12, 2005 09:15 PM |
|
|
Quote:
ZVSE
!?OB34/36/0;
!!HE-1:B2/v44; check class
.
.
.
The problem is I always get Portal of Splendor, no matter what class I am.
You forgot the "?" in the command that checks the class. It should be:
!!HE-1:B2/?v44; check class
Quote:
By the way, how do you make it shorter? I am sure I could combine those lines...
If you divide the class by two and add it to 80, that should work. Try:
!!VRv1:Sv44 :2 +80; [Divide class by 2 and add 80: v1]
!!UN:I3/3/0/17/v1; place dwelling
____________
|
|
Vlaad
Admirable
Legendary Hero
ghost of the past
|
posted May 15, 2005 07:26 PM |
|
|
Quote: You forgot the "?" in the command that checks the class. It should be:
!!HE-1:B2/?v44; check class
I didn't forget it, I didn't even know it should be there . So, I used get/set instead of check syntax, right?
Quote: If you divide the class by two and add it to 80, that should work. Try:
!!VRv1:Sv44 :2 +80; [Divide class by 2 and add 80: v1]
!!UN:I3/3/0/17/v1; place dwelling
Cool.
Everything works fine now. The final version of the stealth script looks like this:
ZVSE
!?OB3/33/0;
!!HE-1:A2/144/0/?v1301; check for the cloak
!!IF&v1301=1:M^%Z400, you seem to have the Invisible Cloak equipped? Perhaps you are the one we have been waiting for.^;
!!IF&v1301=1:Q1/9/4/1^The brethren agree to teach you
{Stealth}
This skill will hide %Z400 from human scouts, but will not work against the infravision of Dark Elves.^;
!!HE-1:N?v66;
!!HOv66&v1301=1:S;
In fact, I might work on it further on some other maps in order to make it work like H4 skill (check for enemy's Scouting etc).
____________
|
|
BIGJOCKER
Responsible
Supreme Hero
Forgotten but not Forsaken
|
posted May 18, 2005 03:20 PM |
|
|
Can enyone make a script which would change an object to a dweling,where would ghosts live...please...
|
|
numi
Hired Hero
|
posted May 18, 2005 06:31 PM |
|
|
it's better to add a real dwelling and use the DW: commands to change what creatures are hireable there. also you'll need to adjust Ghost growth using MA i think. pretty sure ghosts have 0 growth normally.
|
|
Vlaad
Admirable
Legendary Hero
ghost of the past
|
posted May 18, 2005 08:37 PM |
|
Edited By: Vlaad on 18 May 2005
|
Quote: it's better to add a real dwelling and use the DW: commands to change what creatures are hireable there.
Actually, it doesn't matter - both scripts are very easy.
If you want a new function for an already placed object, I'd suggest you delete the old object and place a new one (the same type but with a new function: a Ghost dwelling).
It's even easier to place a completely new object (these are taken from my "Underdogs" map):
ZVSE
!#DWx/y/l:M0/159/8;
ghosts in the wight dwelling at x/y/l
ZVSE
!#UN:Ix/y/l/17/48/63/3/-1;
place a wight dwelling that looks like the "ruins" object at x/y/l
!#DWx/y/l:M0/159/10;
change the monsters for hire to 10 ghosts(159)
(be careful here because the entrances - yellow squares - of the old and new object may not match, so you may need different x values)
!#VRz111:S^Ruins^;
!#HT63/3:T111;
call the new object "Ruins"
Or something different...
ZVSE
!#UN:T4/2/0/159;
!#UN:T4/2/1/159;
ghosts instead of wights and wrights in necropolis
These can be simple triggers, of course:
ZVSE
!?OBx/y/l;
in a story-based scenario, some important object is visited, so that...
!!DWx/y/l:M0/159/10;
...ghosts replace wights in the dwelling at x/y/l
Quote: pretty sure ghosts have 0 growth normally.
I don't think so...
Another topic:
I can easily place a one-way portal exit, but it doesn't seem to work (when the hero enters the entrance, nothing happens). Perhaps the map disables entrances if there are no matching exits day 1 ?
____________
|
|
fnord
Promising
Famous Hero
|
posted May 19, 2005 08:08 AM |
|
|
Quote:
I can easily place a one-way portal exit, but it doesn't seem to work (when the hero enters the entrance, nothing happens). Perhaps the map disables entrances if there are no matching exits day 1 ?
Perhaps. In general we found that you can't add new monoliths with ERM and have them work properly. For example, I think you can add a new two-way monolith and if you enter it you'll appear at one of the others, but you can never reach the new one by entering any other (existing) monolith.
Perhaps the game builds a table of possible monolith exits at map start (before any ERM at all can execute)?
____________
|
|
BIGJOCKER
Responsible
Supreme Hero
Forgotten but not Forsaken
|
posted May 19, 2005 05:41 PM |
|
|
Quote:
ZVSE
!#DWx/y/l:M0/159/8;
ghosts in the wight dwelling at x/y/l
ZVSE
!#UN:Ix/y/l/17/48/63/3/-1;
place a wight dwelling that looks like the "ruins" object at x/y/l
!#DWx/y/l:M0/159/10;
change the monsters for hire to 10 ghosts(159)
(be careful here because the entrances - yellow squares - of the old and new object may not match, so you may need different x values)
!#VRz111:S^Ruins^;
!#HT63/3:T111;
call the new object "Ruins"
These can be simple triggers, of course:
ZVSE
!?OBx/y/l;
in a story-based scenario, some important object is visited, so that...
!!DWx/y/l:M0/159/10;
...ghosts replace wights in the dwelling at x/y/l
These scrips are not working...i don't understand why...everything seems fine...
|
|
numi
Hired Hero
|
posted May 19, 2005 05:52 PM |
|
|
did you remove all the comments, replace the x/y/l with real numbers and add ZVSE to the top of the code?
|
|
numi
Hired Hero
|
posted May 19, 2005 05:56 PM |
|
|
oops. meant have ZVSE only at top. not sure what all ZVSE in middle of script like you have it will do.
|
|
BIGJOCKER
Responsible
Supreme Hero
Forgotten but not Forsaken
|
posted May 19, 2005 10:19 PM |
|
|
Quote: did you remove all the comments, replace the x/y/l with real numbers and add ZVSE to the top of the code?
Yes..i did all that...ant ,but i found where was the problem...i've missed the level coordinate... ...now everything works except this one :
ZVSE
!#UN:Ix/y/l/17/48/63/3/-1;
place a wight dwelling that looks like the "ruins" object at x/y/l
!#DWx/y/l:M0/159/10;
change the monsters for hire to 10 ghosts(159)
(be careful here because the entrances - yellow squares - of the old and new object may not match, so you may need different x values)
!#VRz111:S^Ruins^;
!#HT63/3:T111;
call the new object "Ruins"
|
|
Vlaad
Admirable
Legendary Hero
ghost of the past
|
posted May 20, 2005 12:17 PM |
|
Edited By: Vlaad on 20 May 2005
|
It works like this:
ZVSE
!#UN:I10/10/0/17/74/63/3/-1;
!#DW8/9/0:M0/159/10;
Pay attention to x and y because the squares do not match, so in this case they are 10/10/0 and 8/9/0.
EDIT: Added a picture - the squares you have to be careful are the yellow ones (object entrances) and lower-right corner within the white frame (for placing objects).
____________
|
|
BIGJOCKER
Responsible
Supreme Hero
Forgotten but not Forsaken
|
posted May 20, 2005 01:17 PM |
|
|
Quote: It works like this:
ZVSE
!#UN:I10/10/0/17/74/63/3/-1;
!#DW8/9/0:M0/159/10;
Pay attention to x and y because the squares do not match, so in this case they are 10/10/0 and 8/9/0.
OK...thanx...noe it works...but actually i wanted that i could buy there ghosts weekly (like other creatures in dwelings), not jus one time...
|
|
Vlaad
Admirable
Legendary Hero
ghost of the past
|
posted May 20, 2005 02:48 PM |
|
|
Quote: OK...thanx...now it works...but actually i wanted that i could buy there ghosts weekly (like other creatures in dwelings), not just one time...
But it works that way - I've just checked.
By the way, ghosts' weekly growth seems to be 8.
(If you want more or fewer creatures per week, set their growth.)
____________
|
|
BIGJOCKER
Responsible
Supreme Hero
Forgotten but not Forsaken
|
posted May 21, 2005 11:24 AM |
|
|
Quote:
But it works that way - I've just checked.
By the way, ghosts' weekly growth seems to be 8.
(If you want more or fewer creatures per week, set their growth.)
It's not working to me like that....it works for me only one time....and after one time i even can't get into it..
|
|
|