feat(economy): add murder/kill ranking system#80
Open
beasleybudda-tech wants to merge 9 commits into
Open
Conversation
added 9 commits
May 25, 2026 14:32
- src/config/ai.js: AI config (model, trigger word) - src/services/aiService.js: OpenAI client (built-in fetch, no deps) - src/services/dispatchService.js: dispatch + scene + chat handler - src/events/messageCreate.js: wire AI handler (leveling untouched) Requires OPENAI_API_KEY env var. No new npm packages.
8 new items: - weed_oz, meth_g, coke_g: consumables boosting work/crime payouts - burner_phone: reduces crime fail rate - drug_stash: permanent +25% drug earnings upgrade - bm_pistol, bm_smg, bm_rifle: robbery boost tiers
- /chopshop: steal NPC cars by tier, deliver for payout, jail risk - /211: armed robbery; payout scales with weapon owned (pistol/SMG/rifle) - /lscm: Los Santos Customs marketplace (list/garage/buy/sell personal cars)
- AI now only responds in #rp-chat (1508419491514679327) and #dispatch (1508529364994883654) - In dispatch channel: always dispatch mode (skips intent classification, saves cost) - In RP channel: classifies scene vs chat - Slash commands gated to #bot-commands (1508530649957400606) - Admin/utility/moderation commands ungated (work anywhere)
…m RP - DISPATCH_PROMPT now uses 11-550 (deal), 11-590 (meth), 11-357 (weed), 11-550C (coke) - Adds drug-spot location pool (Grove St, Strawberry, Sandy Shores, Davis, etc.) - If RP chat mentions drug keywords, an anonymous-tip callout is auto-posted to dispatch channel
- /murder @user: PvP kill attempt with cooldown, success chance based on attacker/victim ranks + killstreak, payouts scale with rank - /killstats [user]: shows rank, kills, deaths, K/D, streak, XP progress bar - /killboard: top 10 killers in the server, ranked by murder XP - 7 rank tiers (Petty Thug -> Legendary Killer) unlocked by murder XP - Bulletproof Vest / Personal Safe inventory items block hits - Failed hits send attacker to the hospital for 30m + medical bill - No DB migration: piggybacks on EconomyDataSchema passthrough
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this adds
A full PvP murder/kill ranking system for the GTA RP economy.
New commands
/murder @user— Attempt to take out a target. Success/failure depends on your rank vs. theirs plus your killstreak. Success pays out cash + steals 10% of their wallet. Failure sends you to the hospital for 30m with a medical bill./killstats [user]— Rank, kills, deaths, K/D, current/best killstreak, XP progress bar to next rank./killboard— Top 10 killers in the server, ranked by murder XP.Rank tiers (unlocked by murder XP)
Mechanics
/rob)bulletproof_vest(new) and existingpersonal_safeblock hits cleanlyData
No DB migration needed —
EconomyDataSchemauses.passthrough(), so new fields (kills,deaths,murderXp,killStreak,bestKillStreak,lastMurder,hospitalizedUntil) attach to the existing economy record.Files
src/utils/murder.js— constants, rank table, success/payout mathsrc/commands/Economy/murder.jssrc/commands/Economy/killstats.jssrc/commands/Economy/killboard.jsCommands auto-load from
src/commands/Economy/viacommandLoader.js— no registration changes required. After deploy, re-sync slash commands so the three new ones appear in Discord.