COMMITTED: Suspend Minion Patch
Hello, guys. I have the Suspend Minion AA working on my server (refreshed SVN yesterday).
Here's the diff: Code:
Index: zone/AA.h |
DB Code
Code:
mysql> explain suspendedminions; |
Those client messages aren't what is used on Live.
|
client Messages
You're right. I completely made them up so that I had some idea as to what was going on.
Do you have a link to the client messages? Thanks! |
First of all that's pretty hard to read use the code /code blocks to create a field that will preserve tabs.
Also given that the skill requires staying in the current zone I'm not sold that it needs a database entry or calls. It would in fact be both faster computationally and easier to implement if you created an object in the Client class to store the suspended pet I think. Also not a fan of the c style functions but that's more stylistic than anything being wrong with them. |
Suspend Minion Patch
Good catch on the no-zone thing. I thought you were able to zone with it after they changed live to allow you to zone and keep your pet.
I'll rework this sometime in the near future and repost (with /code). Thanks! P.S. I'll do a search on the accepted coding style here in a bit. |
You can zone with a suspended pet, but there's another AA that enables that.
Next time I'm playing Live, I'll try to note down the messages you get from using the AA. |
Suspend Minion
Well, what do you guys think?
I can go ahead and implement suspend minion to use a database for when we can use the "zone with suspended minion" AA. If that's the case, then I just have to do some minor edits before that AA can work. Otherwise, I'll have to rewrite it. However, it would be easier implement Suspend Minion to not use the database and just use a class to store the suspended minion information. I'm more than happy to go either way on this issue. If I don't hear anything, I'll go ahead and start over to use the class idea so that suspended minions are forgotten after zone. |
Don't forget (I think mentioned here or somewhere else) that later AAs allow you to zone/camp with a suspended minion.
|
Tell me what data you need to store for the whole implementation and we can carve out a part of the PP for it so you don't need any DB classes. Much of the PP in the DB is unused anyway.
|
Suspend: Petname tells you, 'By your command, master.' (tell, purple)
Unsuspend: Petname tells you, 'I live again...'(tell, purple) Suspend with a pet already suspended: You cannot have more than one pet at a time. (red, client message) Try to unsuspend a pet that isn't there: no message at all |
Suspend Minion
Essentially, I need a whole pet structure in the PP, if we want to code it to looking to the future.
If we want to wait until we get to that road later, we can just stick with a very suspended minion pet instance and copy over all the data when suspend minion happens. It's up to you. <=0D Assuming we are going to prepare for the future, here's some info: - Pet information is currently stored in the EPP field and is of type ExtendedProfile_Struct, which looks like the following: Code:
struct ExtendedProfile_Struct { Thanks! |
Alright, I now have it exactly how I want it except the pet buffs aren't showing up after the pet is unsuspended.
I do a pet->SendPetBuffsToClient() after I set the buffs back, but I currently have to zone in order to see the pet's buffs. Any ideas? Thanks! |
Here it is!
Okay, so nevermind on the sending pet buffs to client, I was actually doing a GetClient()->SendPetBuffsToClient(), which had no effect.
That's corrected now and I believe this is a good version. Of course, I know you guys will give me some feedback, which is very welcome! There is actually a restriction to where you cannot suspend a pet while it is engaged. Therefore, I took the liberty of creating a general message in red text. If anyone finds that message, please relay that back to me or change it yourself if you have access to the code. Here it is: Code:
Index: zone/AA.h |
Pet attacking while trying to suspend:
Your pet is the focus of something's attention. (color of spells msg set in prefs) Also, I've never seen this message before, because I never try to suspend when in combat. But it also gave me: Your pet must be a peace, first. (color of spells msg set in prefs) I think the last one, pet was agro on the mob, wasn't swinging at that precise second but was instead procing a spell. |
I'll code it to be that if the pet is on any hate list that you can't suspend him.
I could resort to looking to see if he's at the top of the list. Let me know how live works. Thanks so much for doing the homework! |
Here it is!
Okay, so here it is!
Suspend Minion functionality: - Rank 1 = ability to suspend minion WITHOUT spells OR equipment - Rank 2 = ability to suspend minion WITH spells AND equipment Limitations: - Pet must not be fighting something - Pet must not be on any aggro list - Suspended minion will poof upon leaving zone by any means (i.e. zone/log/etc.) - You cannot suspend more than one minion - You cannot unsuspend if you have a pet active. Code:
Index: zone/AA.h |
I recommend using StringIDs, no idea if the messages are in zone/StringIDs.h though, they're simple to add though, just look them up in your EQ root folder in eqstr_us.txt, I think, might be the en one though, I always forget!
|
I can't find any eqstr_us.txt. I found the stringids.h, but have yet to find the file the messages are actually stored in.
|
Quote:
|
Final Code with StringIDs
Code:
Code:
Index: zone/AA.h |
Awesome. :)
Think you could do the next step? Quote:
|
Persistent Minion requires that we store the minion information to the database somewhere in the player profile. There are already some devs working on where that should go in the near future.
I forgot that there are servers that have a max level above PEQ, so I can see where this would benefit players on those servers. But, the good news is it looks like it should be pretty simple to extend once there is some free room in the profile for the suspended minion data. |
Bump.
Are we going to check in this code? Thanks! |
I'll get to it, probably at the weekend when I have more time to test it, unless another Dev has time to do it before then.
|
Code:
//WIP -- brandon I'm taking them out where I can find them, and if I ever get around to posting code standards no names will be in there. Other than that I think it's to the acceptable point now. |
I've committed this in Rev1123.
I put the SuspendedMinion struct into the Player Profile, and also implemented Persistent Minion as it was a simple two line addition to do so. There was an existing method, EntityList::Fighting which appeared to have the same functionality as your HasAggro method, so I used this. Most of the other changes I made were purely cosmetic. I tested it using a Necro ... let me know if I broke anything in the process of committing it. Finally, nice work, thanks for the contribution, I'm sure the classes who can use this AA will appreciate it. |
All times are GMT -4. The time now is 04:41 AM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.