6300 Commits

Author SHA1 Message Date
Chris Miles
ffe4d528e7
[Tasks] Zone Version Matching (#2303) 2022-07-14 02:57:23 -05:00
Chris Miles
ddb5794462
[Zone] Deprecate Zone expansion Field (#2297) 2022-07-14 02:49:35 -05:00
Akkadius
fb2df0e570 [Hotfix] Fix merge issue 2022-07-14 02:32:35 -05:00
Paul Coene
6b5e4afd2d
[DoT Messages] Add DoT messages for mob->PC casts, fixed others to use correct str. (#2289) 2022-07-14 02:23:13 -05:00
Chris Miles
71966c85ca
[Logs] #logs list Improvements (#2302) 2022-07-14 02:19:00 -05:00
hg
f381453dbd
[Tasks] Place task item rewards in free slots (#2300)
Live places item rewards into the first free inventory slot and only
places it on the cursor if inventory is full
2022-07-14 02:16:43 -05:00
hg
792ea1608a
[Tasks] Fix #task command crash on bad input (#2301) 2022-07-14 02:16:31 -05:00
Kinglykrab
849f4e18a5
[Validation] Add Size Validation to #hotfix. (#2304)
* [Validation] Add Size Validation to #hotfix.
- Validates size of shared memory pool versus current count of database so people don't accidentally #hotfix and mess something up.

* Typo.

* Message change.
2022-07-14 02:11:04 -05:00
Chris Miles
dfd8f84cac
[Strings] Refactor Strings Usage (#2305)
* Initial commit checkpoint

* More functions converted

* Commify

* More functions

* Fin

* Sort declarations

* Split functions between files

* Bots

* Update strings.h

* Split

* Revert find replaces

* Repository template

* Money

* Misc function

* Update CMakeLists.txt

* Saylink

* Update strings.cpp

* Swap Strings::Saylink for Saylink::Create since saylink is coupled to zone database

* API casings
2022-07-14 02:10:52 -05:00
hg
44c85a0dd7
[Quest API] Fix missing arg in perl set_proximity (#2291) 2022-07-08 19:05:33 -05:00
Michael Cook (mackal)
8d6fcf2a84
Fix string comparison issues in Client::SendZoneFlagInfo (#2290)
clang complained about these
2022-07-08 00:07:07 -04:00
Chris Miles
eca4eed996
[Logging] Table Injection - Member Variable Cleanup (#2281)
* Logsys member variable cleanup, table injection

* Private member adjustments, OOB checks

* continue
2022-07-06 22:01:47 -05:00
Paul Coene
5c105d7408
[Bug Fix] NPCs were getting weapon proc added twice (#2277) 2022-07-06 21:59:46 -05:00
Kinglykrab
a444857b46
[Quest API] Perl Doors Fix. (#2288) 2022-07-05 16:17:55 -05:00
Kinglykrab
4025b84891
[Quest API] Add missing methods/package.adds to Perl API. (#2287) 2022-07-05 16:07:41 -05:00
Kinglykrab
6d56b5b730
[Bug Fix] Fix Spell Bucket and Spell Global Logic Checks. (#2285)
- Default to true and set to false if they fail the proper check.
2022-07-04 23:28:21 -04:00
hg
44dc9967a3 Add perl SpellFinished overload 2022-07-04 11:19:44 -04:00
hg
7e8a24fcec
[Quest API] Use binding library for perl apis (#2216)
* Add perlbind library

* Convert perl apis to perlbind
2022-07-03 21:33:45 -05:00
Michael
2829d21057
[Cleanup] Update to EQEmu #2253 to clean up message strings (#2279)
Added message string 1393 // You have been summoned!
2022-07-03 18:57:33 -04:00
Quintinon
b5c4357de2
[Bug Fix] Fix miscellaneous memory leaks related to EQApplicationPacket and it's pBuffer (#2262)
* Delete EQApplicationPacket after use

* Correct issue where Creating EQApplicationPackets in zone/mob.cpp may not free pBuffer[]

* Handle freeing pBuffer[] if exists in zone/mob.cpp Create*Packet functions

* Handle freeing pBuffer[] in zone/object.cpp Create*Packet methods

* Delete leaked outapp variables in zone/trading.cpp

* Make CreateHorseSpawnPacket() safer by freeing pBuffer[] before replacing with new[]

* Prevent initial new ServerPacket from being leaked in command_reload

* Free pack after sending in command_setlsinfo

* Delete new NPC in command_viewnpctype after printing stats

* Fix compile error

* Delete EQApplicationPacket after sending in command_kick

* Remove unneeded safe_delete(outapp) after FastQueuePacket and fix minor whitespace issue

* Delete packet after sending in WorldServer::SendReloadTasks

* Cleanup logic and free leaked NPCType in Client::Doppelganger

* Free RespawnOption in Client::HandleRespawnFromHover in 'unexpected rez from hover request' branch

* Free EQApplicationPacket after sending in Bot::ProcessBotInspectionRequest

* Free Bot when returning from failed Bot::Save() in helper_bot_create()

* Initialize variable to nullptr to prevent garbage initial value

* Undo change in other PR
2022-07-02 22:10:51 -05:00
Paul Coene
5c60913583
[Feature] Add humanoid and non-wielded restrictions to pick pocket (#2276)
* Add humanoid and non-wielded restructions to pick pocket

* Use constants for message string and char color

* Fixed more magic #s

* Fix to include valie bodytypes

* Fix incorrect scope of final else

* My extra message was not needed.  Client handles based on packet reply

* Removed string ID I added - issued by client

* Use existing pick pocket reply function / clean up
2022-07-02 22:02:43 -05:00
Quintinon
30f35a920b
[Bug Fix] Handle memory leaks from return value of Client::GetTraderItems() (#2266)
* Move delete of ItemInstance to avoid edge case leaking in ZoneDatabase::LoadWorldContainer()

* Delete ItemInstance after use in Client::Handle_OP_AdventureMerchantPurchase()

* Delete ItemInstance after use in NPC::GetEquipmentMaterial()

* Delete ItemInstance after use in Bot::AddBotItem()

* Delete GetItems_Struct in edge case when !TradeItemsValid in Client::Handle_OP_Trader()

* Move delete GetItems_Struct to handle edge case when Customer is not valid in Client::Trader_EndTrader()
2022-07-02 22:01:42 -05:00
Quintinon
445c94bf4a
[Cleanup] Fix unintended copies in zone/zonedb.cpp by changing auto to auto& (#2271) 2022-07-02 21:57:17 -05:00
Michael
221d173c59
[Feature] Bind Wound and Forage while mounted. (#2257)
During some point in the eras you were not able to Bind Wound or Forage when mounted. I am not sure if Live is still like this, so I added a rule with it disabled by default.
2022-07-02 21:53:15 -05:00
Michael
68d28bcd3e
[Bug Fix] Add required distance to CoTH before aggro wipe (#2253)
* Add required distance to CoTH before aggro wipe

This should fix eqemu/master#2205

* Remove implied this->

* Adjustments to rules per PR discussion.
2022-07-02 21:51:57 -05:00
Kinglykrab
0c01872608
[Bots] Cleanup ^inventoryremove, ^inventorylist, and ^list Commands and bot groups. (#2273)
* [Bots] Cleanup ^inventoryremove, ^inventorylist, and ^list Commands.

* Bot group cleanup, bot group auto spawning.

* Compile fix.

* Require SQL.
2022-07-02 21:46:00 -05:00
Paul Coene
3936b2b882
[Fix] Boats should never get FixZ'd (#2246)
* Boats should never get FixZ'd

* Use member variable to avoid repetitive checks

* Resolve comments from review

* Fix return type
2022-07-02 13:49:45 -05:00
Kinglykrab
15113f4056
[Quest API] Add TrackNPC to Perl/Lua. (#2272)
* [Quest API] Add TrackNPC to Perl/Lua.
- Add quest::tracknpc(entity_id) to Perl.
- Add eq.track_npc(entity_id) to Lua.
- This will allow server operators to arbitrarily Track NPCs for clients with scripts.
- Modified tracking to auto turn off and tell you that you discovered your target if within 10 units, this is to allow scripted Tracking to turn off without the need for the Tracking skill.

* Remove unnecessary DoTracking() call.

* Update client.cpp
2022-06-29 15:29:02 -04:00
hg
16b31c5a3a
[Bug Fix] Fix empty spawned merchants (#2275)
Regression from 763fc823
2022-06-28 09:23:08 -04:00
Kinglykrab
28b07d635a
[Spells] Target's Target Combat Range Rule (#2274) 2022-06-24 19:04:52 -04:00
Quintinon
059a4b7568
[Bug Fix] Delete NpcType Struct returned by Bot::CreateDefaultNPCTypeStructForBot() when unused (#2267) 2022-06-18 16:45:38 -04:00
Quintinon
b9ceba1b1c
[Bug Fix] Free return value of ZoneDatabase::LoadTraderItemWithCharges() (#2264) 2022-06-18 16:44:23 -04:00
Kinglykrab
be00aa1b60
[Loot] Remove unnecessary loot error messages. (#2261)
* [Loot] Remove unnecessary loot error messages.
These messages are only sent when you loot a corpse that is mid-decay (i.e. no items and you go to loot it immediately) or if you try to loot a non-corpse entity.
The ent != 0 shows up a lot if you're trying to loot too quickly and really isn't an error, the server just hasn't caught up to decay the corpse before you try to loot.

* Use preexisting struct.

* Remove newline.

* Update client_packet.cpp
2022-06-12 18:44:16 -04:00
Akkadius
b2658a6cbc [Hotfix] Correct database call to point to the content_db connection 2022-06-12 17:34:51 -05:00
Michael
026133f32a
[Bug Fix] Tradeskill Item 0 Error (#2256)
When trying to fully script a combine so the tradeskill itself does not return an item (Item 0) and handling all items through quests, the source will provide an error regardless that "Item 0 does not exist". This change will move the item summon after the validity check thus preventing the error to the client.
2022-06-10 13:53:30 -04:00
Michael
6d4f22a1c0
[Bug Fix] Tradeskill Autocombine MinSkill (#2260)
* [Bug] Tradeskill Autocombine MinSkill

Require min tradeskill or above for autocombine.

* Syntax fixes
2022-06-10 13:52:31 -04:00
Michael
e75f87a535
[Quest API] Expand SaveGuardSpot (#2258)
* Expand SaveGuardSpot

- Adds
-- mob:saveguardspot()
-- mob:saveguardspot(true)

* Perl Support
Thanks to KinglyKrab for the perl implementation.
2022-06-10 13:52:22 -04:00
Kinglykrab
83e066bffc
[Bug Fix] Stop skill ups on Charmed NPCs. (#2249)
- Clients were capable of leveling up their melee skills on Charmed Mobs according to: https://github.com/EQEmu/Server/issues/2182
2022-06-09 21:08:50 -04:00
Chris Miles
4639405fdf
[Discord Integration] Native Discord Integration (#2140)
* Start of discord integration work

* more testing

* Discord client work

* More discord work

* Cleanup

* Handle retry timer response and max retries

* Update base retry timer

* Move Discord queue handler to UCS, add queuer to own thread

* Post merge

* Send up Zone::SendDiscordMessage

* Start of discord integration work

* more testing

* Discord client work

* More discord work

* Cleanup

* Move Discord queue handler to UCS, add queuer to own thread

* Post merge

* Push up tables

* Quest API stuff.

* Update 2022_05_07_discord_webhooks.sql

* Post merge fixes

* Push up manifest

* Flip logging signs in logic from copy / paste of inverse logic before

* Make sure we add new line to quest api sourced messages

Co-authored-by: Kinglykrab <kinglykrab@gmail.com>
2022-06-09 17:22:23 -05:00
hg
8ef3e87370
[Bug Fix] Fix stack leaks in Lua events #2254
EventItem was leaving the package table on the stack in successful
(non-encounter) calls and only popping the return. All events were
also leaking the full stack on lua_pcall errors. Lua mod callbacks
were popping error returns but leaking the table.
2022-06-09 17:20:35 -05:00
Kinglykrab
8586cdc47e
[Messages] Convert messages from Spells to FocusEffect where necessary. (#2243)
* [Messages] Convert messages from Spells to FocusEffect where necessary.
https://github.com/EQEmu/Server/issues/837 from 2019 notes a couple places that should use Focus Effect chat type instead of Spells chat type.

* Add rule for item cast messages.
2022-06-08 19:09:33 -04:00
Michael Cook (mackal)
63ba5dc3ab
Fix memory leaks found by Quint (#2248) 2022-06-07 23:41:13 -04:00
Michael
fcc7725ca3
[Bug Fix] Bazaar Search MYSQL Error (#2252)
Corrected fields that the bazaar search function is using to prevent mysql error due to non-existant field items.spellid.
2022-06-07 21:21:02 -04:00
Michael
5df6a61c96
[Bug Fix] Hacker_Str was causing sql errors - Non Escaped (#2251)
Processing the hacker_str through EscapeString().
2022-06-07 21:19:24 -04:00
Kinglykrab
fc5105eed7
[Rules] Add Frontal Stun Immunity Rules. (#2217)
* [Rules] Add Frontal Stun Immunity Rules.
- Add Combat:FrontalStunImmunityClasses rule for determining Frontal Stun Immunity by class bitmasks
- Add Combat:FrontalStunImmunityRaces rule for determining Frontal Stun Immunity by race bitmasks
- Add Combat:NPCsUseFrontalStunImmunityClasses rule for determining if NPCs use Frontal Stun Immunity by class bitmasks
- Add Combat:NPCsUseFrontalStunImmunityRaces rule for determining if NPCs uses Frontal Stun Immunity by race bitmasks
- Cleanup GetDefaultGender() as best as possible with the globalload I have.
- Combat:NPCsUseFrontalStunImmunityRaces defaults to true as NPCs currently use Frontal Stun Immunity.
- Added **all** Ogre races to the check for Frontal Stun Immunity.

* Remove other Ogre races.
2022-06-06 22:29:06 -05:00
Quintinon
243fb781e8
[Bug Fix] Fix two invalid data accesses in zone/client.cpp (#2238)
* Correct potential read out of bounds on array in Client::Doppelganger

* Correct potential read out of bounds in Client::ChannelMessageSend

* Corrected logic to not read out of bounds on the lower end.
2022-06-06 22:26:36 -05:00
Kinglykrab
ec4d228dd5
[Bug Fix] Fix issue where #advnpcspawn addspawn does not add spawn sometimes. (#2247)
* [Bug Fix] Fix issue where #advnpcspawn addspawn does not add spawn sometimes.
- Cleanup where std::stoi should be std::stoul.
- Cleanup ShowStats message to show NPC stats at bottom as well.

* Update advnpcspawn.cpp
2022-06-06 22:24:45 -05:00
Michael Cook (mackal)
2910073373
[Memory Leak] Fix leak of CommandRecords in commandlist (#2244)
* Fix leak of CommandRecords in commandlist

Quicker than porting to std::unique_ptr since we do fun stuff with
commandlist ...

* Fix leak so it won't double free

This is fine enough until we rewrite it to be better
2022-06-06 15:21:35 -04:00
Kinglykrab
b4d5e807e3
[Commands] Add BestZ and Region Data to #loc (#2245) 2022-06-05 15:38:51 -04:00
Kinglykrab
8f729fe948
[Rules] Add Rule to Disable NPC Last Names. (#2227)
* [Rules] Add Rule to Disable NPC Last Names.
- Add NPC:DisableLastNames to disable NPC Last Names.
- Fix #npcedit lastname to allow you to use an empty string.

* Cleanup of classes in naming.

* Duplicate.

* Update classes.cpp
2022-06-04 14:01:00 -04:00