Chalwk / HALO-SCRIPT-PROJECTS

:white_check_mark: Halo PC|CE - Add-ons for Phasor V2+ and SAPP :new_zealand:
Other
32 stars 13 forks source link

[new] Rank System #103

Closed Chalwk closed 3 years ago

Chalwk commented 4 years ago

Rank System

download link | project tracker

alt text



Description

A fully integrated ranking system for SAPP servers. Players earn credits for killing, scoring and achievements, such as sprees, kill-combos and more! Stats are permanently saved to a database stored in the servers root directory called ranks.json.

Credits vary for individual weapons. For example, you will earn 6 credits for killing someone with the sniper rifle, however, only 4 credits with the plasma pistol.

NOTE: At this time, there is no reward for ranking up beyond just being a FLEX. Rank Specific rewards like a Flak Jacket that can absorb explosion damage will come in a future update so stay tuned!

Additional Support:

This script supports generic zombie mods and it has a built-in t-bagging feature. Players will earn +25cR for infecting a human on zombies, and earn +1cR for t-bagging someone.

COMMANDS:

Command Output
/rank View your rank (or another players rank)
/topplist View a list of the top 10 players

SCORING:

Type Credits
first blood (+30 cR)
t-bag (+1cR)
zombie infect (+25cR)
scoring (+25cR)
killed by server (-0cR)
killed by guardians (-5cR)
suicide (-10cR)
betrayal (-15cR)
spree (+5cR every 5 consecutive kills and +50cR for every 5 kills at or above 50)
kill-combo (+8cR for the first two kills, then cR increases by 2 for every kill after the fact: 8cR, 10cR, 12cR, 14cR)
fall-damage (-3cR)
distance-damage (-4cR)
vehicle-squash ghost (+5cR)
vehicle-squash rocket-hog (+6cR)
vehicle-squash chaingun-hog (+7cR)
vehicle-squash banshee (+8cR)
vehicle-squash scorpion (+10cR)
vehicle-squash gun turret (+1000cR)
ghost bolt (+7cR)
scorpion bullet (+6cR)
warthog bullet (+6cR)
gun turret bolt (+7cR)
banshee bolt (+7cR)
scorpion shell explosion (+10cR)
banshee fuel rod explosion (+10cR)
pistol bullet (+5cR)
shotgun pellet (+6cR)
plasma rifle bolt (+4cR)
needler explosion (+8cR)
plasma pistol bolt (+4cR)
assault rifle bullet (+5cR)
needler impact damage (+4cR)
flamethrower explosion (+5cR)
rocket launcher explosion (+8cR)
needler detonation damage (+3cR)
plasma rifle charged bolt (+4cR)
sniper rifle bullet (+6cR)
plasma cannon explosion (+8cR)
frag grenade explision (+8cR)
plasma grenade attached (+7cR)
plasma grenade explision (+5cR)
flag melee (+5cR)
skull melee (+5cR)
pistol melee (+4cR)
needler melee (+4cR)
shotgun melee (+5cR)
flamethrower melee (+5cR)
sniper rifle melee (+5cR)
plasma rifle melee (+4cR)
plasma pistol melee (+4cR)
assault rifle melee (+4cR)
rocket launcher melee (+10cR)
plasma cannon melee (+10cR)

RANK REQUIREMENTS:

Rank Grade 1 Grade 2 Grade 3 Grade 4
Recruit 0
Apprentice 3000 6000
Private 9000 12000
Corporal 13000 14000
Sergeant 15000 16000 17000 18000
Gunnery Sergeant 19000 20000 21000 22000
Lieutenant 23000 24000 25000 26000
Captain 27000 28000 29000 30000
Major 31000 32000 33000 34000
Commander 35000 36000 37000 38000
Colonel 39000 40000 41000 42000
Brigadier 43000 44000 45000 46000
General 47000 48000 49000 50000
Chalwk commented 3 years ago

[script updated] (version 1.19) A few bug fixes and performance improvements with this update.

Chalwk commented 3 years ago

[script updated] (version 1.20) Bug fixes. Nothing worth mentioning.

Chalwk commented 3 years ago

[script updated] (version 1.21) Important bug-fix preventing the script from wiping data from ranks.json

Chalwk commented 3 years ago

Fixed a minor bug in function SortRanks()

Chalwk commented 3 years ago

Updated just now to fix a bug causing lag due to unnecessary io-operations. Added new settings in the config section of the script:

It's not recommended to save stats to file during player join & quit events as this may cause undesirable (albeit temporary) lag but the option is now there.

    updated_file_database = {
        ["OnGameEnd"] = true,
        ["OnPlayerConnect"] = false,
        ["OnPlayerDisconnect"] = false
    },
github-actions[bot] commented 3 years ago

Stale issue message