I am once again asking for the quote of the month to be changed as it is now a new month - Mjmd

Create an account  

 
"how to mod" questions

(September 20th, 2015, 02:45)Asfex Wrote:
(September 6th, 2015, 17:30)Seravy Wrote: Something slightly more important, as it includes fixing two major spell bugs on Blur :
Blur
Change chance of blocking to 1 in xx, requires the next bugfix to work
9A28E 0A -> xx
Fix "Lost rolls" bug : successful rolls no longer cause skipping another roll.
9A297 3D 0A 00 75 03 FF 4E F8 -> 48 75 05 FF 4E F8 EB 03
Just i try to implement this. This does not work, because "dec ax" does not change flags, next "jnz " is senceless.
You must be more carefull to public fixes like that.Try to test it in a debugger first.

Are you sure about that?

http://www.mathemainzel.info/files/x86asmref.html#dec

Usage
DEC dest
Modifies flags
AF OF PF SF ZF

jnz checks zf and it's included in the list.

I tested it with mov ax,1 for the random generation and it was blocking damage 100% of time, with the amount I set instead (4=25%) it doesn't so it is indeed checking for the value being zero.
Reply

See if you can bring back Guises from v1.1, only implement it correctly this time. It would be a nifty spell. It didn't work because if you moved your mouse over the unit, it showed its true name instead of its guise.
Reply

a question occured to me from the current zitro mod flying units discussion:
is it possible to give units a "can attack flyers" ability that does nothing, or little else? is it possible to give a thrown 0 attack that becomes thrown 1 after lvl up? that would be quite weak for example, but probably sufficient for that purpose.
dance!
Reply

trown 0 attack will hit flyers. i tested this.
Reply

(September 24th, 2015, 09:34)Asfex Wrote: trown 0 attack will hit flyers. i tested this.
can we set it to -1 too? *lol*

a question concerning lairs: i thought/hoped the rewards from lairs would be more in line with the number of monsters in the lair, but from what i read the monsters and rewards are calculated independently (though both using a weak or strong formula depending on lair type). correct?


Seravy Wrote:Note on lairs : With the editor, you can change the value of treasure in lairs in 4 categories „weak/strong“ and „arcanus/myrror|.
Weak lairs use the formula of treasure=random(x)*30 while strong lairs in arcanus use treasure=random(x)*50+250 and strong myrror uses random(x)*100+250 instead, unless you change the hardcoded parts, so select your values accordingly. As you can see, only weak lairs have a chance of landing below the default of minimum 50 treasure value.
the tweaker gives different numbers, for example x * rand() * 10 for weak lairs. does it do something differently?
dance!
Reply

(September 24th, 2015, 17:56)letsdance Wrote:
(September 24th, 2015, 09:34)Asfex Wrote: trown 0 attack will hit flyers. i tested this.
can we set it to -1 too? *lol*

a question concerning lairs: i thought/hoped the rewards from lairs would be more in line with the number of monsters in the lair, but from what i read the monsters and rewards are calculated independently (though both using a weak or strong formula depending on lair type). correct?


Seravy Wrote:Note on lairs : With the editor, you can change the value of treasure in lairs in 4 categories „weak/strong“ and „arcanus/myrror|.
Weak lairs use the formula of treasure=random(x)*30 while strong lairs in arcanus use treasure=random(x)*50+250 and strong myrror uses random(x)*100+250 instead, unless you change the hardcoded parts, so select your values accordingly. As you can see, only weak lairs have a chance of landing below the default of minimum 50 treasure value.
the tweaker gives different numbers, for example x * rand() * 10 for weak lairs. does it do something differently?

That might actually be correct, I changed so much things I don't even remember. Wait, 10? But that's barely 2 War Bears if you roll max...lol

Monsters and treasure actually use the exact same treasure value as far as I remember (or at the very least are closely related). However, in the original version of the game :
-Spell rolls add up so 3x common spells = 1 rare for only 150 points = 2 war bears.
-Items actually don't use the value set for them at all due to a bug, which is fixed in insecticide only I think. So you can get an ultimate item for the minimum points for an item roll.
-Gold and Mana doesn't use the points directly instead it adds a random roll of 10-190 for a fixed 100 points. So you can get 30 gold in a 300 point lair.
-Towers just roll a number 1-4 for spell rarity and have that spell, then if the leftover points are negative they still have the spell anyway
-Monsters are rounded down to the nearest integer amount so if the cheapest monster available is Guardian Spirit for 100, and you have a 90 lair you get no defenders...but can still roll up to 190 gold
and who knows what else I don't even remember.
Reply

i played my mod today and noticed that the easy lairs had pretty cheap items compared to the effort to clear them. for example shadow demon + 5 zombies = mace with destroy value 100. is there any way to change that relation? i guess changing item values could work? but that would also make them cheaper to buy. any way to change that? like a negative charisma bonus for buying items? clearing easy lairs would be more fun if i could get better items. it would also be nice if i could get items with costs 4,000+ from really hard lairs.

does the minimum lair cost also count for both, items and monsters?

edit:
Seravy Wrote:39F33 BB 0A 00 99 F7 FB BA 0A 00 F7 EA 89 46 FA 2B 7E FA → 2B 7E FA BB xx 00 99 F7 FB BA yy 00 F7 EA 89 46 FA
The yy and xx values are the multiplier and divisor for the item value actually added. This makes the game add the item value of floor (Original Roll / xx) * yy but only spend points equal to the original roll.
xx = 1
yy = 2
now all items are only calculated with half their value.
and in the item generation calculations i use half of what i actually want. (standard formula now gives from 600-6000 with 200 increments)
correct?
dance!
Reply

another question... does anyone know where the trait descriptions are stored? the one you get when right-clicking a trait (like artificer).
dance!
Reply

(September 24th, 2015, 20:48)letsdance Wrote: another question... does anyone know where the trait descriptions are stored? the one you get when right-clicking a trait (like artificer).

Everything that shows up by right clicking is in the help.lbx file.
Reply

(February 5th, 2015, 12:20)Asfex Wrote: find programm xck2com, it can apply changes from text file to the wizard.exe, instead to make it via hex editor. You can use programm xcp.exe for this work instead, i put it into one archive of my mod. The txt file to make lighting from fortress is attached.
i edited string copies to the .txt so it's easier to do the changes by hand

.txt   FORTLIG.txt (Size: 4.68 KB / Downloads: 11)
dance!
Reply



Forum Jump: