RekkasGit / E3Next

10 stars 19 forks source link

Armpet for allservers #222

Closed MetalJacx closed 3 months ago

MetalJacx commented 5 months ago

I believe this allow a pet system for all servers and allow Laz players to continue doing what they are doing without changing anything. I try to easily identify the Laz hardcoded stuff as much as possible and I gave the Laz players the capability to turn the hardcode off in general settings if they eventually want to define their own. Even the none|none should work

This still leverages the same /t charactername armpet function but players now get to specify their identifiers. Since it is flexible, characters seeking their pets getting armed can now use /t charactername armpetlist .

For the summoning of items they are defined as such Summoned Pet Item=SpellName|ItemName|Identifier

Summoned Pet Item=Artifact of Baat|Summoned: Hand of Baat|MHW
Summoned Pet Item=Legendary Toxic Edge Earring|Summoned: Toxic Edge|OHW
Summoned Pet Item=Mask of Mardu|Summoned: Muzzle of Mardu|Focus
Summoned Pet Item=Summon Crystal Belt|Summoned: Crystal Belt|Focus
Summoned Pet Item=Summon Phantom Plate|Phantom Satchel|Armor
Summoned Pet Item=Summon Phantom Plate|Phantom Plate Helm|Armor

Identifiers can be repeated in order to easily create group of items to give out. Such as identifying, as example focus and can be named anything such as. Summoned Pet Item=Summon Phantom Plate|Phantom Plate Helm|bythepowerofgreyskull

Automatically buff pets that are part of the bot network is the same as well. I did add the capability to use , as well since that seems to be the trend with multiple /checkfor| and Ifs|(I actually did the same for chat command , or |.

Pet Weapons=Nemu/OHW|OHW|Armor|Focus
Pet Weapons=Komamura/MHW,Slow,Focus
Pet Weapons=Mayuri/MHW,OHW,Armor,Focus
Pet Weapons=Rangiku/MHW,OHW,Armor,Focus

If an identifier is asked for that doesn't exist the player will recieve a message telling them they do not support and what identifiers they do support.

Added Clean Bags= This is to add bags that you want to delete during the arming process. This players to on other emu where admins may use custom name bags for pet items.

Clean Bags=Phantom Satchel
Clean Bags=Pouch of Quellious

last thing I added was a debug on and off Auto-Pet Debug (On/Off)=(Default off). This will allow the player to see the inter process in console when turned on and should help us troubleshoot if players run into issues.

Auto-Pet Debug (On/Off)=On

Everything else still exist as well such as Auto-Pet Weapons (On/Off)=On Ignore Pet Weapon Requests (On/Off)=Off and Keep Open Inventory Slot (On/Off)=On

Was tested on server EQ.Might. Do not have Mage on Laz to test.

MetalJacx commented 5 months ago

One thing I forgot to mention. I added, public string AdditionalIDsString = string.Empty; This is for summon spells where the pet already has a weapon and so primary doesn't equal 0. So if ever there was a custom pet with a weapon ID you can treat it's primary as 0 and still do auto trade. This value is hidden and has to be manually added to ini, but is Treat WeaponIDs as Empty(##, ##, ##)=.

MetalJacx commented 5 months ago

Did I make this to difficult to review should I have just did one big commit instead of little ones?

RekkasGit commented 5 months ago

I would request jonnyrocket take a look at it as its his area of code. I just work here. :P

jonnyrocket0 commented 5 months ago

I will sometime soon - just haven’t gotten around to it yet Sent from my iPhoneOn Feb 8, 2024, at 2:41 PM, RekkasGit @.***> wrote: I would request jonnyrocket take a look at it as its his area of code. I just work here. :P

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.***>

jonnyrocket0 commented 4 months ago

This feels way more complex than it needs to be. Not a fan of the hardcoding of things based on server name, and it also doesn't allow non max level mages on laz to customize to meet their needs. This should be doable with just a set of config lines like Pet Item=UberWeapon1|UberWeapon1SpellOrItemName Pet Item=PetCloak|PetCloakSpellOrItemName ... Pet Item=PetMuzzle|PetMuzzleSpellOrItemName

If there are any Pet Items defined, then we know to use the generic code, else use the hardcoded laz stuff.

MetalJacx commented 4 months ago

This feels way more complex than it needs to be. Not a fan of the hardcoding of things based on server name, and it also doesn't allow non max level mages on laz to customize to meet their needs. This should be doable with just a set of config lines like Pet Item=UberWeapon1|UberWeapon1SpellOrItemName Pet Item=PetCloak|PetCloakSpellOrItemName ... Pet Item=PetMuzzle|PetMuzzleSpellOrItemName

If there are any Pet Items defined, then we know to use the generic code, else use the hardcoded laz stuff.

Yeah I didn't want to hardcode based on server name but there was the conversation we had in E3N discord about backwards compatibility. I wasn't sure how to keep the Laz's identifiers(fire|slow|etc) without screwing up someone else who may use those identifiers on another emu for different items and then they would try to summon no existing items. So when on Laz it just takes what was in the old code and imports it into the SPI dictionary, so technically new items can be used with what players on Laz are already using today it is not one or the other. The hardcode can be turned off in general settings. I think I forgot to mention this is my description LoadKeyData("Misc", "Lazuras Mage Import (On/Off)", parsedData, ref LazurasMageImport); .

I am not sure what you mean by this "doesn't allow non max level mages on laz to customize to meet their needs", as Summoned Pet Item= is very generic(no level or spell/item requirements) and is still usable on Laz whether hardcode is turned on or not.

Just wanted to add that we wanted to keep the same request structure which is why it is Summoned Pet Item=SpellName|SummonedItem|Identifier. So that custom items can be leverage in the request armpet command.

MetalJacx commented 4 months ago

I was also thinking on this "If there are any Pet Items defined, then we know to use the generic code, else use the hardcoded laz stuff." which is doable but what if laz adds more or different items in the future, I think we would then have to hardcode those items then into e3, because if someone then used the generic code to use new items it would turn all the laz items off....hmmm.

MetalJacx commented 4 months ago

@jonnyrocket0 made the change so if empty it will leverage what laz has configured but as soon as summoned pet item is populated laz items/identifiers no longer used. image Ini switching between commented and non commented section. During testing i changed none to an item i could cast on might since I do not have mage on laz.

[Magician]
Auto-Pet Weapons (On/Off)=On
Auto-Pet Debug (On/Off)=On
Ignore Pet Weapon Requests (On/Off)=Off
Keep Open Inventory Slot (On/Off)=Off
Pet Weapons=Nemu/none
Summoned Pet Item=
Clean Bags=

; Auto-Pet Weapons (On/Off)=On
; Auto-Pet Debug (On/Off)=On
; Ignore Pet Weapon Requests (On/Off)=Off
; Pet Weapons=Nemu/OHW|OHW|Armor|Focus
; Pet Weapons=Komamura/MHW,Slow,Focus
; Pet Weapons=Mayuri/MHW,OHW,Armor,Focus
; Pet Weapons=Rangiku/MHW,OHW,Armor,Focus
; Summoned Pet Item=Artifact of Baat|Summoned: Hand of Baat|MHW
; Summoned Pet Item=Legendary Toxic Edge Earring|Summoned: Toxic Edge|OHW
; Summoned Pet Item=Mask of Mardu|Summoned: Muzzle of Mardu|Focus
; Summoned Pet Item=Summon Crystal Belt|Summoned: Crystal Belt|Focus
; Summoned Pet Item=Summon Phantom Plate|Phantom Satchel|Armor
; Summoned Pet Item=Summon Phantom Plate|Phantom Plate Helm|Armor
; Summoned Pet Item=
; Clean Bags=Phantom Satchel
; Clean Bags=Pouch of Quellious
; Keep Open Inventory Slot (On/Off)=On
MetalJacx commented 3 months ago

All my testing I realize was done with spell gems already mem or instant cast time. There is something that is breaking when needing to mem. Just going to close this request.