|
Thread: Programming for WoG/SoD? | This thread is pages long: 1 2 3 · «PREV / NEXT» |
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted August 28, 2009 09:23 PM |
|
|
There is no single command to achieve a script. If you need to script a battle, then you start with !?BA trigger, then need to check which heros are fighting, so you need !!HE receiver. Then you need to check creatures, so you need !!MA receiver. Then you need to set spells/actions, thus you need !!BU or !!BG receivers. That's why it is better to know the whole ERM as an organic thing, and pick from each section the little thing which will be necessary for making the big thing working.
And also to avoid having not doable ideas. It is better to know ERM limits and imagine ideas regardless.
**You can't set zealot to cast a spell, for this you need a creature which already does it, and it needs to be same level spell.
____________
Era II mods and utilities
|
|
GreatEmerald
Hired Hero
|
posted August 28, 2009 10:35 PM |
|
|
Well yes, I see. Though why do I need such a lot of commands? For example, why do I need to check for heroes - if it's a hero vs monster fight, then I won't get much from that?
As for that part... Hmm, that means I'll need to convert a Master Genie to a Zealot? But isn't that basically the same as creating a whole new unit?
Also, how did the WoG team manage to make Santa Gremlins shoot Ice Bolts - spells, instead of physical damage projectiles?
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted August 28, 2009 10:56 PM |
|
|
1)You don't need necessary a lot of commands. But sometimes it will be safe to check if battle is human vs AI, because if AI plays with modified creatures, there are chances that the game crash. AI can't handle a master genie who cast resurrect for example. More you want from a script, more bugs will come from, so you need to imagine and script all the possible issues.
What happens for example if the zealot casts bless on a creature immune to it? You have to script that. What happens if Zealot casts bless on a creature already blessed? You have to script that also. What happens if the Zealot gets morale and already used bless? He can bless again? You have to script that too otherwise the whole forum of players will lynch you.
Just an example.
2)I guess Slava configured gremlins starting with Faeries abilities. Now, how he did it, I have no idea. There is no info about that in ERM
3)If you have specific request regarding WoG mechanics, you'd better address them in WoG team english forums. Here we are all noobs comparing to them.
____________
Era II mods and utilities
|
|
GreatEmerald
Hired Hero
|
posted August 29, 2009 11:55 AM |
|
|
OK, I'll look into that, for now I'll just mod the existing creatures. I've run into a slight issue though. I made Angels cast Dispel after attacking (when debugging I even set that to 100%), however, I rarely see that happening. I fought like 10 battles with them and saw not a single dispel cast, but after that they started behaving as they should. I have no idea why... The code now is:
Quote: ZVSE;
!#UN: P900/1; Stack Experience is enabled
!#UN: P906/1; Stack Experience may not be gained from Battles
!?PI;
!!EA12:B5/0/////////////;
!!EA12:B6/0/////////////;
!!EA12:B7/0/////////////;
!!EA12:B8/0/////////////;
!!EA12:B9/0/////////////;
!!EA12:B10/0/////////////;
!!EA12:B11/0/////////////;
!!EA12:B12/0/////////////;
!!EA12:B5/1/75/35/20/20/20/20/20/20/20/20/20/20/20; Angel/Use/Cast non-DD/Dispel/True everywhere
!!EA12:B6/1/74/15/30/30/30/30/30/30/30/30/30/30/30;Angel Use Cast before attack Magic Arrow At 30%
Is there something wrong here, or is is simply because of the strange nature of the Dispel spell?
|
|
Warmonger
Promising
Legendary Hero
fallen artist
|
posted August 29, 2009 12:02 PM |
|
|
|
GreatEmerald
Hired Hero
|
posted August 29, 2009 01:03 PM |
|
|
Yeap. Actually, when it started working, they cast dispel even on creatures without spells (and on those who have them, of course).
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted August 29, 2009 04:19 PM |
|
|
!!EA12:B6/1/99/78/100/...etc
Dispel is a non-direct damage spell.
Start your B# at B6, not B5. It was an error in my guide. B5 is speed and it will be overwritten by ability, while still working. Only visual problem.
____________
Era II mods and utilities
|
|
GreatEmerald
Hired Hero
|
posted August 30, 2009 03:01 PM |
|
|
Nope, still doesn't work for some reason. The current code is:
Quote: ZVSE;
!#UN: P900/1; Stack Experience is enabled
!#UN: P906/1; Stack Experience may not be gained from Battles
!?PI;
!!EA12:B6/0/////////////;
!!EA12:B7/0/////////////;
!!EA12:B8/0/////////////;
!!EA12:B9/0/////////////;
!!EA12:B10/0/////////////;
!!EA12:B11/0/////////////;
!!EA12:B12/0/////////////;
!!EA12:B6/1/99/35/100/100/100/100/100/100/100/100/100/100/100; Angel/Use/Cast non-DD/Dispel/True everywhere
!!EA12:B7/1/74/15/30/30/30/30/30/30/30/30/30/30/30;Angel Use Cast before attack Magic Arrow At 30%
The strange thing is that I also set Gargoyles to use 99 for their Paralyze ability (33%) and I haven't seen them using the ability since then. Might be just my luck, though.
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted August 30, 2009 03:14 PM |
|
|
I gave you the code:
!!EA12:B6/1/99/78/100/...etc (add 100)
Use it if you want it to work.
____________
Era II mods and utilities
|
|
GreatEmerald
Hired Hero
|
posted August 30, 2009 03:34 PM |
|
|
That works, but it dispels only beneficial spells... Why doesn't the normal dispel ability work?
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted August 30, 2009 03:53 PM |
|
|
|
GreatEmerald
Hired Hero
|
posted August 30, 2009 04:57 PM |
|
|
Because dispelling only beneficial spells is a little too good Dispelling all spells would make it more strategic. But ah well. So, what's the difference between using something like paralyze with 99 (non-direct damage) and 107 (just a spell)?
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted August 30, 2009 05:10 PM |
|
|
In ERM format SE3 paralyze is not listed. If it is not present, that means tests failed using it.
____________
Era II mods and utilities
|
|
GreatEmerald
Hired Hero
|
posted August 30, 2009 07:21 PM |
|
|
It's 74 from the spells menu, and it's not listed because it's a monster-specific spell, I guess, since it works just fine for me (the only strange thing is that paralyzed monsters still retaliate once).
|
|
GreatEmerald
Hired Hero
|
posted September 02, 2009 05:31 PM |
|
|
So, is there a way to extract PCX files from LODs, instead of BMPs? Or extract the mask as a separate file?
Also, what's the modifier and rank values for the Block ability? If I use it as Deflect, it gives me rows of empty space for some reason...
EDIT: Oh, and what do MA AI value (I) and Fight value (F) mean?
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted September 03, 2009 04:33 AM |
|
|
When extracted they become bmp. But you can then convert to anything. Block ability is used in most custom maps, just check the codes. MA value is about how important will become that target for AI. For example if you have peasants and Archangels in your army, AI will attack AA if has a chance to kill them. If you give a higher value to peasants, it will attack peasants first. At least this is how it should do. I have no idea what fight value means.
____________
Era II mods and utilities
|
|
GreatEmerald
Hired Hero
|
posted September 05, 2009 02:21 PM |
|
|
Well, the problem is that BMP is not PCX, even if you convert it back. You can try it for yourself:
1. Extract ZRESBAR from Bitmaps.lod
2. Convert it to PCX
3. Import again
It will become wrongly masked - the bar will have two colours, and some resource icons will be see-through.
Also, what's wrong with this code?
Quote: !!EA36:B9/1/87/53/30/30/30/30/30/30/30/30/30/30/30; Djinni Have Protection from magic At 30%
I'm trying to set up 30% protection from all magic (dwarf type), yet all the fields appear blank where I view the experience sheet...
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted September 05, 2009 05:09 PM |
|
|
Format SE5
Stack Experience Standard Modifiers ($4 for EA:B Command)
+ Add 43
= Set 61
% Percent 37
You confounded immunity with magic resistance.
____________
Era II mods and utilities
|
|
GreatEmerald
Hired Hero
|
posted September 05, 2009 09:25 PM |
|
|
Ah, that's what, thanks! Though for some reason using % doesn't work, only set works.
Is there a way to add the Death Gaze ability to non-Gorgons? Or will I have to create my own Finger of Death spell for that?
|
|
GreatEmerald
Hired Hero
|
posted September 15, 2009 06:00 PM |
|
|
Also, is there a way to cast a blessing on the enemy when shot? I don't really count Frenzy as a blessing, yet the game does... Or will I have to create a curse duplicate of the same spell?
|
|
|