105 Commits

Author SHA1 Message Date
hg
6acfc41778 Let world handle expedition leader changes
This should eliminate race conditions caused by zones trying to set
a leader when members in different zones quit at the same time

Zone still detects when leader goes offline to trigger a change
since it's easier than having world process expedition member status
updates and perform expedition lookups
2020-12-30 18:47:32 -05:00
hg
0f051b68ae Separate world expedition source files 2020-12-30 18:47:31 -05:00
hg
da5d4b9830 Send all members expedition expire warnings
All expedition members are notified not just those in dz

This will only work if the dz is running. It might make more sense to
move this to client or world processing so members are notified even if
the zone instance isn't running
2020-12-30 18:47:31 -05:00
hg
b965a165b1 Add api to update expedition expire time
Add SetSecondsRemaining method to set expire time on expedition
2020-12-30 18:47:11 -05:00
hg
b377fd183a Add api to add lockout duration
Also supports reducing lockout duration

Add Expedition::AddLockoutDuration

Add Client::AddExpeditionLockoutDuration

Some expeditions require adding to existing lockout durations
during progression. These add the specified seconds to individual
member lockout timers instead of setting a static duration based on
internal expedition lockout like UpdateLockoutDuration.
2020-12-30 18:47:11 -05:00
hg
d61879fd3c Add character id based expedition apis
Add static expedition methods to add or remove character lockouts

Add CreateLockout static helper to ExpeditionLockoutTimer

Refactor existing character lockout removal to allow removal of lockouts
for offline characters (was only used by #dz lockouts remove command)

Fix #dz list member count
2020-12-30 18:47:10 -05:00
hg
184ea679f2 Refactor client cross zone message helpers
Remove extra cross zone message server opcode and struct. Existing
function already exists for normal messages

Group CZClientMessageString struct with other CZ structs
2020-12-30 18:47:09 -05:00
hg
148af3edfc Only delete empty expeditions when the dz is empty
Zones are no longer able to delete expeditions. World now tracks empty
expeditions in cache and only deletes them when it detects an
expedition's dynamic zone instance has no more clients inside.

This fixes an exploit where lockouts couldn't be applied to expeditions
after all members were removed because zones were deleting the expedition
immediately. Clients still inside the dz were able to complete events
before being kicked from the instance while not having an expedition.

Expeditions are no longer purged from database in the world purge
instance timer to avoid a possible race with this new system
2020-12-30 18:47:08 -05:00
hg
dcbcc5a156 Implement world cache to monitor expeditions
This implements a small cache in world to track expedition states.

This fixes expired expeditions being left in zone caches unless the
expedition's dz instance was running to detect it (or unless an
expedition was deleted via a client using /kickplayers). This was also
leaving clients in a ghost expedition that no longer actually existed
2020-12-30 18:47:08 -05:00
hg
3f4ea66ea1 Implement expedition locking
Disables the ability to add new members

Adds Expedition::SetLocked(bool) to quest api

Adds is_locked column to expedition_details db table
2020-12-30 18:47:08 -05:00
hg
5ddb62e275 Make adding replay timers to new members optional
Not all expeditions with a replay timer lockout add it to newly
added members automatically

This adds the Expedition::SetReplayLockoutOnMemberJoin(bool) method
to the quest api so it can be disabled
2020-12-30 18:47:08 -05:00
hg
89c6d1e258 Send expedition re-invite to clients that zone
Moves expedition message handling in world to Expedition method
for messages that need special handling
2020-12-30 18:47:07 -05:00
hg
ef77b28b3f Add #dz lockouts remove command
This allows clearing a character's lockouts

Adds client RemoveAllExpeditionLockouts methods and exposes to lua api
2020-12-30 18:47:07 -05:00
hg
eccc79e4ce Let dz handle client removal timers
Remove all clients inside a dz, not just those assigned to instance
2020-12-30 18:47:07 -05:00
hg
8eef2ae089 Add DynamicZone class for expedition instancing
Add DynamicZone sql table schema

Add DynamicZones logging category

Modify CreateExpedition to take DynamicZone and ExpeditionRequest objects

Implement DynamicZone compass, safereturn, and zone-in coordinates.

Implement live-like DynamicZone instance kick timer for removed members

Implement updating multiple client compasses (supports existing quest compass)

fix: Send client compass update after entering zones to clear existing compass

Implement Client::MovePCDynamicZone to invoke DynamicZoneSwitchListWnd
when entering a zone where client has multiple dynamic zones assigned

Implement OP_DzChooseZoneReply handling

Add Lua api methods for expedition's associated dynamic zone

Add #dz list gm command to list current DynamicZone instances from database
2020-12-30 18:47:07 -05:00
hg
da067be2fa Implement initial expedition system
Add Expeditions logging category

Add handlers for all Dynamic Zone/Expedition related opcodes

Add FormatName string_util function to format character names

Add Zone::IsZone helper method

Add cross zone MessageString support with variable parameters

Add static Client method helpers for cross zone messaging

Add #dz gm command to debug expedition cache for current zone
2020-12-30 18:47:06 -05:00
Akkadius
8647bd73ce Merge remote-tracking branch 'origin' into integration/multi-tenancy-expansions-repository 2020-07-12 16:51:36 -05:00
Alex
c8389bc674 Completely overhaul cross zone and world wide methods in quest API. 2020-07-07 08:02:56 -04:00
Akkadius
b7e2261e16 Merge branch 'master' of https://github.com/EQEmu/Server into integration/multi-tenancy-expansions-repository 2020-07-07 01:32:17 -05:00
Alex
f514dd5b55 Optimize cross-zone utilities and add cross-zone player move utilities to Perl/Lua. 2020-06-29 17:54:30 -04:00
Akkadius
e03ca7f65e Merge branch 'master' of https://github.com/EQEmu/Server into integration/multi-tenancy-expansions-repository 2020-06-29 00:40:27 -05:00
Alex
25c3d3803f Add cross-zone task assign methods to Perl/Lua. 2020-06-27 20:03:06 -04:00
Akkadius
3f62da4573 Merge branch 'master' of https://github.com/EQEmu/Server into integration/multi-tenancy-expansions-repository 2020-05-23 22:33:34 -05:00
KimLS
2fbd5aaccc Rename namespace EQEmu to namespace EQ (so we don't have two similar but different namespaces anymore) 2020-05-17 18:36:06 -07:00
Alex
5f0d3e9026 Add several cross zone methods to Perl/Lua. 2020-05-11 20:10:52 -04:00
Alex
dc9bd031ff
Merge branch 'master' into crosszonesignalplayerbygroupid 2020-05-10 21:00:43 -04:00
Alex
857b24727c Add CrossZoneMessagePlayerByGuildID() to Perl/Lua. 2020-05-10 16:52:33 -04:00
Alex
12c4b20169 Add CrossZoneSignalPlayerByGroupID() to Perl/Lua. 2020-05-09 21:15:34 -04:00
Akkadius
373fb3f0e7 Decouple zone calls, cleanup logic 2020-04-19 04:36:39 -05:00
Akkadius
ca49f3902f Migrate getZoneX calls and npc types calls [skip ci] 2020-03-12 02:27:09 -05:00
Akkadius
3a09197d77 Migrate zone [skip ci] 2020-03-11 03:55:44 -05:00
hg
9689787e56 Remove assignments in conditions 2020-01-29 18:34:33 -05:00
hg
63b8df72b2 Implement consent for group/raid/guild and add Auto Consent support
Refactors consent to be more live accurate

Message sent to owner and receiver for each zone a corpse is in
Corpses now store consent list instead of clients holding corpse list
Consent throttling added
Message strings and colors updated
Removed reporting invalid consent targets
2020-01-27 00:17:15 -05:00
Akkadius
6222132625 More logging cleanup [skip ci] 2019-09-07 02:18:15 -05:00
Akkadius
be291d58b0 Move worldserver logging ot use LogInfo 2019-09-01 22:53:23 -05:00
Akkadius
d3803045bc Add log aliases to make logging much easier to use (All FMT driven) 2019-09-01 20:47:26 -05:00
KimLS
f3255c17da Changes to cle enums, characters will now auto kick on login instead of making you wait at world unless you specifically turn that feature on in the rules. 2019-07-24 19:20:09 -07:00
KimLS
cd32a5a47a Make the reconnect code only trigger when there's actually a client IN ZONE and try to clean up otherwise 2019-07-23 21:59:22 -07:00
regneq
460468224e various changed to chatchannel and using language / language skills derived from takp code. 2019-07-14 20:03:30 -07:00
Uleat
93a0ad2ceb Added command 'profanity' 2019-02-04 07:02:27 -05:00
Uleat
7857bc45fb Excluded runtime modification of expansion-based rules 'World:ExpansionSettings' and 'World:UseClientBasedExpansionSettings' 2019-01-11 05:01:44 -05:00
Trust
f8f1061ced [Queryserv] Dropped Item Logging 2018-07-22 12:39:34 -04:00
KimLS
5060de9b58 Keep alive implemented for world->zone 2018-07-07 22:19:24 -07:00
Uleat
e5e779c064 Updated UCS versioning code - update your *.conf files 2018-03-04 21:38:17 -05:00
Uleat
6c2a8edea6 Added ClientVersion request system to UCS server (needed to fix saylinks) 2018-02-25 21:40:45 -05:00
KimLS
0a8b21d4ab Merge branch 'luamod' 2017-06-19 14:45:08 -07:00
Natedog2012
59ddf507e6 Add CrossZoneSetEntityVariableByClientName 2017-06-12 08:42:14 -07:00
KimLS
31d8336b4b Fix acceptmessages, added exp hooks to luamods 2017-06-10 15:12:31 -07:00
KimLS
281483efc1 Merge of a monster 2017-04-02 20:03:51 -07:00
Akkadius
7aa1d243b0 [Performance] Reworked how all log calls are made in the source, see changelog.txt for more details 2017-04-01 03:51:46 -05:00