Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Development

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

Reply
 
Thread Tools Display Modes
  #1  
Old 06-09-2009, 12:24 PM
gaeorn
Developer
 
Join Date: Apr 2009
Location: USA
Posts: 478
Default

Fair enough. You are much more familiar with the code base than I am. As long as it isn't going to cause regular problems in the future, I see no reason not to do it as you suggest.
Reply With Quote
  #2  
Old 06-09-2009, 12:35 PM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

From a database perspective converting either way will only be two easy queries since they are bitmasks. Just let me know what the final decision is, so I can get into PEQ
Reply With Quote
  #3  
Old 06-09-2009, 03:14 PM
gaeorn
Developer
 
Join Date: Apr 2009
Location: USA
Posts: 478
Default

I suspect Trevius is more concerned about others with custom DBs that are not as good at SQL queries. In any case, it's up to him since he's writing the code and I'm still a noob around here
Reply With Quote
  #4  
Old 06-09-2009, 05:12 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

Well, I got the actual slot stuff set in the SoF code last night to allow items set as slot 22 to show up as Power Source in SoF and items with Slot 21 to show up as Ammo like they currently do.

I did a DB check last night on my items table and it looks like they didn't add any new ammo slot items since SoF, because I didn't see anything set to use slot 22 at all. Maybe a fresh PEQ DB would show differently, but I think the last update I did on mine should have included them if there were any.

Basically, this means that only the Power Source items would have to be changed over to use slot 22 to work with the new slot arrangements. I tested it last night and setting them to slot 22 does make them equipable in the latest SVN, so it should be ready for a database change now. I don't think the change is as simple as a single query though, because both Ammo and Power Source items currently in the Database use slot 21. So, I think they have to be changed by hand. I used Navicat last night and sorted my items table by slot and was able to manually change all of the Power Sources from slot 21 to slot 22 very quickly with just copy and paste. There were only 50 or so of them and they were all right next to each other.

I would not advise for anyone to actually put an item into the Power Source slot right now unless they are testing it, because it will definitely delete the item after you do so. This is because I don't have the extra code in place to support the new inventory slot yet, but I will try to work on that further tonight. It will have to be added to be able to save to the database, and to be usable as a clicky if it has a click effect. Also, I noticed that if you set stats on a Power Source item, the client will definitely gain those stats, which means that I will need to add that slot in to calculate the bonuses from it so that the server factors them in properly. That's pretty cool, because I was not aware that Power Sources could actually give stats to the client directly. So, not only could the item be used for an extra clicky slot, but it could also be used for any other stat and probably even worn and focus effects, which is nice.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #5  
Old 06-09-2009, 07:41 PM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

Quote:
Originally Posted by gaeorn View Post
I suspect Trevius is more concerned about others with custom DBs that are not as good at SQL queries. In any case, it's up to him since he's writing the code and I'm still a noob around here
I only replied because Trevius mentioned me by name asking my opinion.

In PEQ's case, the change actually should only take one query with the way you set it up. If I remember from the last time I played around with ammo vs power source items there was a column or two that identified the two right off the bat for me other than slots. I probably should have bumped power slot items when I changed ammo slots to work on Titanium but I didn't think ahead.
Reply With Quote
  #6  
Old 06-09-2009, 09:57 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

Ahh, I see! So, that makes sense why I didn't see anything set to use Slot 22 when I checked my items table after recently updating it to PEQ. I didn't know that you had already done that conversion to make them compatible with Titanium. Good to know

If there is another field to help you identify Power Source items, then that should make it fairly simple. And yes, I was referring directly to Cavedude, because IMO, his database is the most important for current items that would include new stuff like Power Sources. For custom servers, it doesn't really matter much, because if they haven't updated to add in new items from the PEQ DB, then they probably don't have Power Source items in the first place. For custom servers, they would most likely just be creating new items and would then just set them to slot 22 if they wanted them to be usable in the Power Source slot.

It sounds like the DB change should be really quick and simple. I will probably mention the new slot 22 to GeorgeS so he can update his tools to add in the new slot if possible.

Hopefully I can get all or at least most of the new slot stuff worked out tonight so it can be saved in the database and can be handled just like any other worn slot. While I am doing that, I am also going to see if I can get Cursor added to the nukeitem() function so we will finally be able to delete items from player's cursors. I don't know why cursor wasn't added to that long ago, but since I am adding another slot in that for Power Source, I might as well get cursor added in there too.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #7  
Old 06-10-2009, 02:43 AM
gaeorn
Developer
 
Join Date: Apr 2009
Location: USA
Posts: 478
Default

Sorry I wasn't clear in my earlier post. I was merely trying to re-express Trevius' concern over the difficulty some people might have had updating their DBs if slot numbers had changed more radically. I was just stating this because Cavedude's post indicated it would be easy for him to convert either way.

Anyway, if what I was trying to say still isn't clear, just ignore it, lol. It somehow got all convoluted up to the point it almost doesn't make sense to me anymore.

In any case, based on Trevius' expertise with the code, I expect his judgment of which course to take was the best one. I merely was submitting a different point of view in case it had not been considered.
Reply With Quote
  #8  
Old 06-10-2009, 05:24 AM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

LOL, I don't know if "expertise" is the right word for my skill level with the source code :P

I know a ton more about it than I did 10 months ago, but I am still quite a newb at coding. I have simply read over the code repeatedly in almost every spot, so I am fairly familiar with it. The only thing I am getting decent at is understanding packet structures and how all of that stuff works. As for the actual code, I have a very long way to go before I would consider myself an "expert", LOL.

The suggestion you made really is the ideal way to go, but that doesn't mean that it is the best way to go. In the end, I don't think it would really make much of a difference in the long run, so it probably just isn't worth the extra work now.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #9  
Old 06-10-2009, 08:56 AM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

Quote:
Originally Posted by gaeorn View Post
Sorry I wasn't clear in my earlier post. I was merely trying to re-express Trevius' concern over the difficulty some people might have had updating their DBs if slot numbers had changed more radically. I was just stating this because Cavedude's post indicated it would be easy for him to convert either way.
They couldn't have, remember slots are handled by the client. If somebody started changing slot values around the items wouldn't function properly. It will always come down to a single subtraction or addition query of the slot's base binary value. The trick is, as Trevius and I were discussing is figuring out which are ammo and which are power slots (because my dumb ass changed ammo a while back and left power slots alone) but I have that worked out.

At any rate, I'll write a post-it reminding me to fix power slot items in the DB today.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 10:18 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3