mirror of
https://github.com/Mezeporta/Erupe.git
synced 2026-03-21 23:22:34 +01:00
feat(diva): implement Diva Defense point accumulation (#168)
RE'd putAdd_ud_point (FUN_114fd490) and putAdd_ud_tactics_point (FUN_114fe9c0) from the ZZ client DLL via Ghidra decompilation. MsgMhfAddUdPoint fields: QuestPoints (sum of 11 category accumulators earned per quest) and BonusPoints (kiju prayer song multiplier extra). MsgMhfAddUdTacticsPoint fields: QuestID and TacticsPoints. Adds diva_points table (migration 0009) for per-character per-event point tracking, with UPSERT-based atomic accumulation in the handler.
This commit is contained in:
10
server/migrations/sql/0009_diva_points.sql
Normal file
10
server/migrations/sql/0009_diva_points.sql
Normal file
@@ -0,0 +1,10 @@
|
||||
-- Track per-character Diva Defense (UD) point accumulation per event.
|
||||
-- Each row records a character's total quest + bonus points for one event.
|
||||
CREATE TABLE IF NOT EXISTS public.diva_points (
|
||||
char_id integer NOT NULL REFERENCES public.characters(id) ON DELETE CASCADE,
|
||||
event_id integer NOT NULL REFERENCES public.events(id) ON DELETE CASCADE,
|
||||
quest_points bigint NOT NULL DEFAULT 0,
|
||||
bonus_points bigint NOT NULL DEFAULT 0,
|
||||
updated_at timestamp with time zone NOT NULL DEFAULT now(),
|
||||
PRIMARY KEY (char_id, event_id)
|
||||
);
|
||||
Reference in New Issue
Block a user