i'm making a map on H4, and i can't figure out 1 thing in the scripting, I want to make a single placed event that destroys multiple houses, so I made this:
ASK QUESTION:
question: do you want to destroy this village?
if YES: fight 150 peasants, if victorious, delete adventure objects with marker "house1"
if NO: do nothing
and i placed a few bombs with markers "house1".
of course the event deleted the bombs, not the houses they were placed on.
now how do i trigger the bombs instead of deleting them?
EDIT: i tried cutting out the peasants and just destroying the objects, same thing happened.
[H4] newbie map editor help
[H4] newbie map editor help
Last edited by bibo on 03 Mar 2009, 20:46, edited 1 time in total.
The "delete adventure objects" and the bomb setup should be fine.
I think the problem is with the victorious option, but I forgot what the issue was. Either the victorious and defeated brances be turned around (i.e. the 150 peasants are defeated) or the scripts didn't work at all.
I think the problem is with the victorious option, but I forgot what the issue was. Either the victorious and defeated brances be turned around (i.e. the 150 peasants are defeated) or the scripts didn't work at all.
Are you suggesting coconuts migrate?
- Thelonious
- Round Table Knight
- Posts: 1336
- Joined: 06 Jan 2006
- Location: right behind the next one
There was something odd about them. I believe that wimfrits was right; the defeated and victorious were switched so you could also check if it'll work if you switch the events around. But the thing was that there is a better way to check if a army was defeated (and had not just fled) like thus:
Sequence
-Give 1 Ghost to This Army
-Take 1 Ghost to This Army
-Conditional Event
--If
Number of Ghosts in This Army > 1
--Then
This Army was defeated (if the player had fled this option will not be chosen)
--Else
This Army is still out there somewhere so you'd have to check whether they actually beat the peasants or had just fled
So I hope I helped...
Sequence
-Give 1 Ghost to This Army
-Take 1 Ghost to This Army
-Conditional Event
--If
Number of Ghosts in This Army > 1
--Then
This Army was defeated (if the player had fled this option will not be chosen)
--Else
This Army is still out there somewhere so you'd have to check whether they actually beat the peasants or had just fled
So I hope I helped...
Grah!
- Thelonious
- Round Table Knight
- Posts: 1336
- Joined: 06 Jan 2006
- Location: right behind the next one
Have you tried making some text appear under victorious and defeated? Then you know exactly what triggers...
I haven't worked with the editor for some time but a quick search into it made me think:
perhaps you could look at your script and make sure the marker and script have the same name; I make that mistake all the time. The fastet way to check is to give the bomb a name (in your case house1) then go to the script and select that name from the list.
The perculiar thing is that for placed events the golden ball/sausage gives a list of all the placed events scripted in the map properties. (just the other way around)
But then I figured that's the first thing one checks... Have you tried making other bombs and blowing stuff up? If this works then it must be the script...
I haven't worked with the editor for some time but a quick search into it made me think:
perhaps you could look at your script and make sure the marker and script have the same name; I make that mistake all the time. The fastet way to check is to give the bomb a name (in your case house1) then go to the script and select that name from the list.
The perculiar thing is that for placed events the golden ball/sausage gives a list of all the placed events scripted in the map properties. (just the other way around)
But then I figured that's the first thing one checks... Have you tried making other bombs and blowing stuff up? If this works then it must be the script...
Grah!
- Thelonious
- Round Table Knight
- Posts: 1336
- Joined: 06 Jan 2006
- Location: right behind the next one
Who is online
Users browsing this forum: No registered users and 4 guests