|
|
 |
 |
 |
 |
|
 |
 |
|
 |
 |
|
 |
|
Development::Development Forum for development topics and for those interested in EQEMu development. (Not a support forum) |

04-30-2009, 12:27 AM
|
 |
Demi-God
|
|
Join Date: May 2007
Location: b
Posts: 1,449
|
|
In regards to min/max dmg
Not sure where to put this, but is there any reason mindmg/maxdmg in the database is an int16 versus it being an int32, which is the maximum value for damage?
I'm looking in code at npc.h,
Quote:
int16 max_dmg;
int16 min_dmg;
|
and noticed NPCs and players cannot hit for more than an int16, but damage is clearly an int32, and was wondering if there is any reasoning behind doing this specifically for learning purposes. Also, I noticed haste is an int8 in mob.h, when all of that calculation for haste is done serverside and is actually an sint32 in the structure. I noticed it is sometimes possible to stack haste to over the max value for an int8, and this will break things to all hell.
Is there any reason we do this, though? Or is it safe to change them from int16 and int8 to int32?
|

04-30-2009, 12:33 AM
|
 |
The PEQ Dude
|
|
Join Date: Apr 2003
Location: -
Posts: 1,988
|
|
Why do you need more than 32767 damage?!?!
|

04-30-2009, 12:36 AM
|
 |
Demi-God
|
|
Join Date: May 2007
Location: b
Posts: 1,449
|
|
Quote:
Originally Posted by cavedude
Why do you need more than 32767 damage?!?!
|
Heh, you'd have to ask KingMort on that one. It's his number crunching that I need to balance stuff around :P
But yeah. That's why I need that much damage; to have mobs that can hit slow but hard. When you have players with 180k HP, sometimes 32767 damage doesn't cut it.
It is either that, or we lower the stats on gear again. If it was up to me, I would have MUCH less numbers, something simple like 36.
|

04-30-2009, 12:37 AM
|
Administrator
|
|
Join Date: Sep 2006
Posts: 1,348
|
|
It was probably int16 in the struct at sometime in the past and never updated.
|

04-30-2009, 12:39 AM
|
 |
Demi-God
|
|
Join Date: May 2007
Location: b
Posts: 1,449
|
|
Quote:
Originally Posted by KLS
It was probably int16 in the struct at sometime in the past and never updated.
|
Ah, gotcha. So it is safe to update these to their proper values?
I guess i'll go try it; though I don't have my devenv set up, which is why I made this post. ><
|

04-30-2009, 01:52 AM
|
Administrator
|
|
Join Date: Sep 2006
Posts: 1,348
|
|
Don't see any reason why they couldn't be updated safely.
|

05-03-2009, 09:49 PM
|
 |
Demi-God
|
|
Join Date: May 2007
Location: b
Posts: 1,449
|
|
Quote:
Originally Posted by KLS
Don't see any reason why they couldn't be updated safely.
|
I just updated the value in npc.h and zonedump.h to int32 and I don't have any issues with it. The rest of the source has it listed as int32 already.
Any chance of getting it committed, or is it not needed for any server except my own? :p
|

05-03-2009, 10:15 PM
|
Administrator
|
|
Join Date: Sep 2006
Posts: 1,348
|
|
Throw a diff on submissions and I'll commit it with the rest of this combat stuff I'm finishing up(if no one else does first)
|
 |
|
 |

05-03-2009, 10:54 PM
|
 |
Demi-God
|
|
Join Date: May 2007
Location: b
Posts: 1,449
|
|
Quote:
Originally Posted by KLS
Throw a diff on submissions and I'll commit it with the rest of this combat stuff I'm finishing up(if no one else does first)
|
here you go.
Quote:
Index: npc.h
================================================== =================
--- npc.h (revision 459)
+++ npc.h (working copy)
@@ -324,8 +324,8 @@
void AIDoSpellCast(int8 i, Mob* tar, sint32 mana_cost, int32* oDontDoAgainBefore = 0);
- int16 max_dmg;
- int16 min_dmg;
+ int32 max_dmg;
+ int32 min_dmg;
sint32 accuracy_rating;
//pet crap:
Index: zonedump.h
================================================== =================
--- zonedump.h (revision 459)
+++ zonedump.h (working copy)
@@ -82,8 +82,8 @@
int8 luclinface; // and beard);
int8 beard; // solar: this probably doesn't work right, was missing from here
// int8 aa_title; ////not loaded from DB
- int16 min_dmg;
- int16 max_dmg;
+ int32 min_dmg;
+ int32 max_dmg;
char npc_attacks[30];
// float fixedZ;
int16 d_meele_texture1;
|
|
 |
|
 |

05-04-2009, 01:16 AM
|
Banned
|
|
Join Date: Sep 2006
Posts: 841
|
|
Quote:
Why do you need more than 32767 damage?!?!
|
hehe <3 Cavedude
I sure wish some of you guys would try my server out for more than 5 minutes ... The extreme nature of it is balanced to each raid... All of the custom content / zones have a very big FUN factor.....
The Reason we need that code is because of our players having excess of 200k HP buffed.. and Raid Encounters needing to be more than the last 5 - 6+ years which have only hit for a max of say 32767... X 4....
Now we have a need for Larger , and more hard core encounters..
King
|

05-04-2009, 01:26 AM
|
Administrator
|
|
Join Date: Sep 2006
Posts: 1,348
|
|
I still think you're freaking crazy Mort.
|

05-04-2009, 11:40 AM
|
 |
The PEQ Dude
|
|
Join Date: Apr 2003
Location: -
Posts: 1,988
|
|
I agree with KLS, but you certainly have intrigued me!
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -4. The time now is 02:00 AM.
|
|
 |
|
 |
|
|
|
 |
|
 |
|
 |