@Argent77 Thank you so much for the explanations attached. Now to ponder over them for a little bit more...
@kjeron
That is odd. For me, that code duplicates every matching BAM file, replacing the "AX" with "TE" in the filename.
Tried again to make sure I didn't erred somewhere. Still the same effect. Ironically I'm trying this on Win7, where Argent77 successfully replicated your method.
Since this was going to be 3rd thread I was planning to create in IE Help in last 3 days I decided to merge them all together to keep me from spamming whole IE Help board I also want to take an opportunity to thank you folks for all your answers and advices - they're really appreciated!
Right now I have a problem with ADD_CRE_EFFECT macros. I'm trying to add an effect having a spell as a resource (opcode 206), and it looks like WeiDU doesn't accept resource as a text, it keeps asking me for an integer, but what integer could I provide for the spell name?
Here's the code:
COPY_EXISTING_REGEXP GLOB ~.*\.cre~ ~override~
READ_SHORT 0x28 animation
PATCH_IF (animation = 32551) OR (animation = 32553) BEGIN
LAUNCH_PATCH_FUNCTION ADD_CRE_EFFECT
INT_VAR
opcode = 206
target = 1
timing = 1
resource = ~crspl02.spl~
END
END
BUT_ONLY_IF_IT_CHANGES
And here is the relevant part of its debug log:
ERROR: cannot convert crspl02.spl or %crspl02.spl% to an integer
See the INT_VAR is the same thing for the integers... as the resource is a "string variable".
Edited by The Imp, 19 July 2017 - 02:42 PM.
Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit).
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.
The 'Type' field set which 2da file to pick the creatures to summon from. The 2da files are monsumX and anisumX, where X = Type + 1. 0-4 are allied , 5-9 are hostile. The specific 2da files used are:
0 MONSUM01 Monster Summon 1
1 MONSUM02 Monster Summon 2
2 MONSUM03 Monster Summon 3
3 ANISUM01 Animal Summon 1
4 ANISUM02 Animal Summon 2
5 MONSUM01 Monster Summon 1 Hostile
6 MONSUM02 Monster Summon 2 Hostile
7 MONSUM03 Monster Summon 3 Hostile
8 ANISUM01 Animal Summon 1 Hostile
9 ANISUM02 Animal Summon 2 Hostile A custom .2da file can be entered in the resource field.
I'm trying to use that custom 2da option, but got stuck on the issue which is complete stopper: where/how exactly do I put the name of that custom 2da?
I tried to change "from 2da file" field in spmon01.eff from monsum01 to cr2da001 manually by typing it in hex mode of NI (because there's finite list of options when using NI's GUI for editing this field), but found out I don't have enough space to do so as there's only 4 bytes reserved for resource name. When I shortened my 2da name down to cr21 (4 letters) though, I had just the place to squeeze it inside the eff, but much to my surprise the game keep drawing summon subjects from monsum01.2da, not from cr21.2da. I further removed "spmonsum" value from the parameter 2 of the eff (just in case, I have no idea what it does or refers to), but still the same result. Apparently not only eff doesn't recognize my custom 2da, but it also kept somehow it's original ties with monsum01.2da even though I removed its mention.
At this point I'm out of my own ideas and would welcome yours
Add: actually I'm not sure typing my custom 2da name in hex was bound to work in the first place, for 2da resource isn't stored in the eff by its name but rather by associated number instead. For example monsum01 is stored in eff as 0, monsum02 - as 1 and so on. This looks hardcoded. But then again, why does IESDP claims its possible to use custom 2das, surely someone tested it with a success? Perhaps there's mods using such I could learn from?
I tried to change "from 2da file" field in spmon01.eff from monsum01 to cr2da001 manually by typing it in hex mode of NI (because there's finite list of options when using NI's GUI for editing this field)
It would be silly to not have the .2da file you intent to define, to not be in the games override folder when doing so ? Did you not have it there ?
Generally, I would assume the .2da name is in the effects resource 2 field, aka offset 0x0070. At least according to the Near Infinity, with the hexadecimal offsets shown up. (Options -> Show Hex Offsets)
Edited by The Imp, 19 October 2017 - 01:57 PM.
Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit).
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.
Roxanne, if only you would see my posts... but nope.
Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit).
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.
It would be silly to not have the .2da file you intent to define, to not be in the games override folder when doing so ? Did you not have it there ?
Generally, I would assume the .2da name is in the effects resource 2 field, aka offset 0x0070. At least according to the Near Infinity, with the hexadecimal offsets shown up. (Options -> Show Hex Offsets)
Re. having 2da in question in override - of course I do The choice for this field in GUI is actually limited to ten 2da's, it doesn't draw from all 2da's present in override like usual fields do.
Re. resource 2 - tried that, all I've achieved is that the creature summoned now do so without it's summoning animation played, but still it's the creature from monsum01.2da nevertheless.
It would be silly to not have the .2da file you intent to define, to not be in the games override folder when doing so ? Did you not have it there ?
Generally, I would assume the .2da name is in the effects resource 2 field, aka offset 0x0070. At least according to the Near Infinity, with the hexadecimal offsets shown up. (Options -> Show Hex Offsets)
Re. having 2da in question in override - of course I do The choice for this field in GUI is actually limited to ten 2da's, it doesn't draw from all 2da's present in override like usual fields do.
Re. resource 2 - tried that, all I've achieved is that the creature summoned now do so without it's summoning animation played, but still it's the creature from monsum01.2da nevertheless.
Attach files please ... Specifically in a .zip file .. reason being that I could open them.
Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit).
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.
Update: resource 2 (offset 0x0070) is an animation. No wonder animation ceased to play when I crammed resource 2 with my 2da name
Update 2: the reference to 2da is stored within eff 127 as a hex integer from 0 to 9 even though 4 bytes allocated to this reference could fit in something more. Any attempt to write there anything else, from ascii to hex 0A or more, leads to a monsum01 (hex reference 00) being activated or at least that's what it looks like from testing. By now I tend to believe that monsum01 being active for me was not due to me overlooking reference to it somewhere in eff but rather due to it being built-in failsafe in case reference is out of 0 - 9 boundary. I also assume that there should be some 2da-like mapping where monsum01 = 0, monsum02 = 1 and so on. I was unable to find such 2da, so it might be hardcoded. If so, then how is it ever possible to use custom 2da unless map it within exe, and we need Erephine or Ascension64 for that
Still, I am attaching the test files I was working with (in zip ) in hope I've missed something obvious and it is in fact possible to attach custom 2da to opcode 127.
Does IE have out of the box function to summon "up to X HD" monsters at all? Something like opcode 127, but treating number in parameter 1 not like the amount it had to fill from associated 2da, but as a max for RNG picking between 1 and that max? Of course I could emulate it, it's just seem hard to believe that IE doesn't have build in function for, like, "roll 1D6 to determine the total HD of a group summoned", which I understand to be a staple for AD&D.
Well, you can simulate it by setting the effect percentages between 0 and 99. So 1HD monster from 0 to 9, 2HD monster from 10 to 19 and so forth toward to 10HD from 90 to 99 for example.
Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit).
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.
This part was exactly about approach you mentioned, what I wonder is whether such tabletop mechanic was actually omitted in IE or I just don't know something
When exactly does weapon item abilities performs: upon attack (no matter if target was hit or missed) or only upon successful hit? Or it is controlled by some parameter in ability?
When exactly does weapon item abilities performs: upon attack (no matter if target was hit or missed) or only upon successful hit? Or it is controlled by some parameter in ability?
What reference are you trying to use ? Is it "performs: upon attack" or something else, I can't interpreter the exact word(s).
Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit).
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.
What reference are you trying to use ? Is it "performs: upon attack" or something else, I can't interpreter the exact word(s).
I am asking whether opcode attached to the weapon through item ability will be executed each time I attack someone with this weapon or only when I actually hit my target. Say, I want a sword with opcode 13 or 55, and I need to make sure it only insta-kills on successfull blows while doing nothing if I perform an attack but miss the target: is this default behaviour in IE or are there any switches to it?
Does IE have out of the box function to summon "up to X HD" monsters at all? Something like opcode 127, but treating number in parameter 1 not like the amount it had to fill from associated 2da, but as a max for RNG picking between 1 and that max? Of course I could emulate it, it's just seem hard to believe that IE doesn't have build in function for, like, "roll 1D6 to determine the total HD of a group summoned", which I understand to be a staple for AD&D.
In 2E the monster/animal summoning spells were dX creatures of level X, not dX total HD of creatures, so that is what we have, at least in the EE's. The summon opcodes can roll dice(using the dice fields, leave parameter1 at 0) for an amount of creatures, but not for an amount of HD of creatures, by setting the special field to '1'. Opcode 127 can only do this in external EFF files, 331 can do it in EFF's or Spells. I don't know whether or not this works in the original engine for opcode 127.