LAST EDITED ON 06-03-02 AT 03:15 AM (PDT)
Edit: Heh, the tables did not come out well. Sorry for that, not sure how to do it.OK, here is some info. Please note that this is just for the actual functions setting up the properties. This time around I didn’t went through the functions that pick the actual properties at random and such although it is not THAT hard to find. They are typically located at the end of the monster code section in d2game. Just check around the functions that use the tables I mention below and look for random number generation
Here are a few tables I extracted, just to make it easier for you. Don’t bother with the header text, it is just something my program write so that I know what it is, the interesting thing is the address for the location of the table if you wish to find it and/or change things. I include all the tables here to make it easier for you
Tabell v3.10 by Pedro Faria Fri May 24 18:27:59 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd03230 (1875915312)
Offset: d3230 (864816)
0 10
1 24
2 25
3 26
4 27
5 5
This table just lists the 5 different champion properties. For a champion, the game picks one of them at random and add to the list of boss properties (the game will later on go through that list and add the properties by calling correct functions). The last 5 is just the number telling how many different possibilities there is. It is probably one array in memory having the boss property and then a variable that will end up with the size. If I programmed it I will probably have something like:
static const int champprops<> = {10,24,25,26,27}
static const int nbrofchampprops = sizeof(champprops)/sizeof(nbrofchampprops<0>)
or something like that, the numbers should of course be some type of constants assigned the numbers, but you get the idea. Could be done differently to I suppose.
Tabell v3.10 by Pedro Faria Fri May 24 18:14:16 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd03248 (1875915336)
Offset: d3248 (864840)
0 30 31 ffffffff
1 32 33 ffffffff
2 34 35 ffffffff
3 36 37 38
4 39 3a 3b
This is a table used to pick a random magic damage property for one of the boss abilities. It is used as parameters to a generic function that will basically take the physical damage and then set the stats of the two first parameters (which would be like min fire damage and max fire damage and so on) and as a parameter there will be a multiplier as well. The third parameter is a stat that will get a duration parameter (it adds 40 frames to it). I just added this table for completeness.
Tabell v3.10 by Pedro Faria Fri May 24 18:25:30 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd0a650 (1875945040)
Offset: da650 (894544)
0 1
1 0
2 0
3 0
4 0
5 1
6 1
7 1
8 1
9 1
10 0
11 0
12 0
13 0
14 0
15 0
16 1
17 1
18 1
19 0
20 0
21 0
22 0
23 0
24 1
25 1
26 1
27 1
28 1
29 1
30 1
31 0
32 0
33 0
34 0
35 0
36 1
37 1
38 1
39 1
40 0
41 0
42 0
43 0
To be honest, not sure what this table was for, I think it might be the one used to pick random boss properties. There are 44 of them (0 to 43) although some are not used. Anyway, if you run across the table in the code, you now know at least what the table look like. Note that in ALL tables, all values are in hex except the first column which is just a general index number that is not part of the table but added by my program to keep count, sorry for not having it in hex too.
Tabell v3.10 by Pedro Faria Fri May 24 17:47:27 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd0a700 (1875945216)
Offset: da700 (894720)
0 0 2 62
1 0 1 66
2 0 0 6c
3 0 1 72
4 0 2 7b
5 0 2 7a
6 14 2 76
7 3e7 2 67
This is your aura table. It has three columns, the first lists the level a monster needs to be to be able to gain the aura, the next column is a shift value for the level. 0 means the aura will be of monster level, 1 that it will be mlvl/2, a 2 that it will be mlvl/4 and so on. I think there is a minimum value of 1, but check the code to be sure. The last column is the skill number (as found in skills.txt). The game pick one of them at random. As can be seen the first 6 always are available and the 7th only from level 20 and up, the last one is never available since it is set to level 999.
Tabell v3.10 by Pedro Faria Fri May 24 17:34:41 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd0a760 (1875945312)
Offset: da760 (894816)
0 0
1 6fc61850
2 6fc618b0
3 0
4 6fc61900
5 0
6 0
7 0
8 6fc61b50
9 6fc61b50
10 0
11 0
12 6fcbe250
13 0
14 0
15 0
16 6fc61940
17 6fc61b50
18 6fc61b50
19 0
20 0
21 0
22 0
23 6fc61b50
24 0
25 6fc61b50
26 6fc61d70
27 6fc61b50
28 6fc61b50
29 0
30 6fc61db0
31 0
32 0
33 0
34 0
35 0
36 6fc61990
37 6fc619f0
38 6fc61a40
39 6fc61ad0
40 0
41 6fc61b20
42 0
43 0
This is pointers to each boss ability and handle the setting of the ability for the ability. Note that some of the properties is added through a later table, not sure of the exact difference and so on though.
Some notes, property 1 is a general boss property added to all bosses and champions, didn’t check it out this time, it seems to handle coordinates and such.
Property 2 is also a boss property that increases the HP (*2,*4 and *8 depending on if it is a boss, champion or minion).It also sets regeneration to 0 for bosses/champion. It adds 3 to the monster level and multiplies the exp by 5.
The 5 champion abilities mentioned above will all except one decrease the monster level by 1 and multiply the exp by 3/5 so we get the normal boss stats. They do some other additions too that is part of the champion stats although some of it is done through a later table. As you can see the champion functions are entry 16 for the "normal" champion and entry 36-39 for the "new" ones.
Some notes on some of the other properties:
5 and 6 are the extra strong/fast (don’t remember which one is which).
7 is cursed
8 CFL resistance +40
9 F resistance +75 that is fire enchanted and so on, you should figure it out) I give the stats changes here
10 upon death a poison cloud skill is set of
12 empty really
17 L resistance +75
18 C resistance +75
23 Pois resistance +75
25 M resistance +75
27 CFL resistance +20 (if below 75)
28 DR*2, phys resistance +50
30 Aura
As can be seen almost all resistance stuff is done in the same function. It will check for the actual boss ability number and assign according to that, see the actual function.
Tabell v3.10 by Pedro Faria Fri May 24 18:30:20 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd0a80c (1875945484)
Offset: da80c (894988)
0 0
1 6fc61e70
2 6fc61e80
3 6fc61e90
4 6fc61ea0
5 6fc61ed0
6 6fc61ee0
7 6fc61f00
8 6fc61f10
9 6fc61f20
10 6fc61f30
11 6fc61f60
12 6fc61f70
13 6fc61fd0
I have really no idea what this was.
Tabell v3.10 by Pedro Faria Fri May 24 18:18:01 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd0a844 (1875945540)
Offset: da844 (895044)
0 0 0 0 0 0 0
1 0 0 0 0 0 0
2 0 0 0 0 0 0
3 0 0 0 0 0 0
4 0 0 0 0 0 0
5 6fc61fe0 0 0 0 0 6fc621a0
6 0 6fc621c0 0 0 0 0
7 0 0 0 6fc62270 0 0
8 0 0 0 0 0 0
9 6fc62350 6fc62370 6fc623a0 0 0 6fc62470
10 0 6fc634f0 6fc62b30 0 0 0
11 0 0 0 0 0 0
12 0 0 0 0 0 0
13 0 0 0 0 0 0
14 6fc637f0 0 0 0 0 0
15 0 6fc62b70 0 0 0 0
16 6fc625a0 6fc626b0 0 0 0 6fc62700
17 6fc62910 6fc634c0 6fc62930 0 6fc62a70 6fc62a90
18 6fc62ab0 6fc634f0 6fc62ad0 0 0 6fc62b10
19 6fc62c30 0 0 0 0 6fc62d00
20 0 6fc62e00 6fc62e20 0 0 0
21 0 0 6fc63760 0 0 0
22 0 6fc63170 0 0 0 0
23 6fc63220 0 0 0 0 6fc63310
24 0 0 0 6fc62ff0 0 0
25 6fc62f10 0 0 0 0 6fc62f30
26 0 0 0 0 0 0
27 6fc62f50 0 0 0 0 6fc62fa0
28 0 0 0 0 0 0
29 0 0 0 0 0 6fc63330
30 0 0 0 0 0 0
31 0 6fc634f0 6fc62490 0 0 0
32 0 6fc634f0 6fc639a0 0 0 0
33 0 6fc63a40 6fc63ab0 0 0 0
34 0 6fc63520 6fc635c0 0 0 0
35 0 6fc63740 0 0 0 0
36 6fc62720 6fc62760 0 0 0 6fc62720
37 0 6fc627b0 0 0 0 0
38 0 0 0 0 0 0
39 6fc62800 0 0 0 0 6fc62800
40 0 6fc63be0 0 0 0 0
41 0 0 6fc63c10 0 0 0
42 0 6fc634f0 6fc62510 0 0 0
The other main ability adder. Again it holds one row for each ability. Hmm, only 42 entries, not sure about the 43 entry above, could be I forget it for this table or that the previous table ended at 42 and the value for 43 was not part of the table, sorry, don’t remember which.
There are 5 columns and from the little notes I have, the first 2 seems to be used upon creation in some way. The third seems to have code for "upon hit"/"upon death" since it do stuff the monster should do when dead or hit. Not sure how the game decide if the monster is dead though. The fourth column seems to have code for when the monster MAKES a hit. The last column usually have code that is more or less the same as for the first 2 columns. I think I saw references to items in those code though, not sure really. Didn’t look that much into it.
Tabell v3.10 by Pedro Faria Fri May 24 18:35:46 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd0ac4c (1875946572)
Offset: dac4c (896076)
0 43
1 43
2 43
3 43
Have forgot this one, I think it is actually two tables with two values (43 both) each. Stat 43 is velocitypercent so could have something to do with that. I think the game picked one of the one entry (thus 43 always) a random or something.
Tabell v3.10 by Pedro Faria Fri May 24 18:34:26 2002
Source: d2game.dll Size: 1028146
Target: slask.txt
Position: 6fd0ac5c (1875946588)
Offset: dac5c (896092)
0 0
1 0
2 0
3 0
4 0
5 1
6 2
7 3
8 4
9 5
10 0
11 0
12 0
13 0
14 0
15 0
16 0
17 6
18 7
19 0
20 0
21 0
22 0
23 0
24 0
25 8
26 a
27 9
28 b
29 c
30 d
31 0
32 0
33 0
34 0
35 0
36 0
37 0
38 0
39 0
40 0
41 0
42 0
One more of the tables I didn’t got around to check this time. I think it had something to do with picking random attributes or something for a boss.
I have not gone through any of the actual code sections here but I think the above is a good start and with that knowledge you can probably look at them yourself and understand most of it. If not, feel free to ask.