Skip to content

sv_neo_restore_... - Give XP/deaths to players, restore from backup#1880

Merged
nullsystem merged 4 commits into
NeotokyoRebuild:masterfrom
nullsystem:GH-1878_GiveXP
Jun 27, 2026
Merged

sv_neo_restore_... - Give XP/deaths to players, restore from backup#1880
nullsystem merged 4 commits into
NeotokyoRebuild:masterfrom
nullsystem:GH-1878_GiveXP

Conversation

@nullsystem

@nullsystem nullsystem commented Mar 21, 2026

Copy link
Copy Markdown
Collaborator

Description

Native implementation of XP/deaths restoration, with an extra to automatically backup and manually restore whole session.

ConVars:

  • sv_neo_restore_xp_death_any_round - Allow setting XP/session anytime
  • sv_neo_restore_session_allow_name_match - Allow name matching
    in session restore

Commands:

  • sv_neo_restore_session - Restore entire session from backup
  • sv_neo_restore_round_number - Force round number
  • sv_neo_restore_rounds_won - Force Jinrai/NSF rounds won
  • sv_neo_restore_team_scores - Force Jinrai/NSF scores
  • sv_neo_restore_xp - Force XP on a player

Removed commands:

  • sv_neo_score_set_[jinrai/nsf] - Replaced by sv_neo_restore_... equivalent

Toolchain

  • Linux GCC Distro Native Arch/GCC 15

Linked Issues

@nullsystem nullsystem force-pushed the GH-1878_GiveXP branch 2 times, most recently from ab33a72 to 5b230b8 Compare March 22, 2026 02:25
@nullsystem nullsystem changed the title [WIP] TODO: .givexp/.givexpall - Give XP to players from authorized spec … sv_neo_force_... - Give XP/deaths to players, restore from backup Mar 22, 2026
@nullsystem nullsystem marked this pull request as ready for review March 22, 2026 02:26
@nullsystem nullsystem marked this pull request as draft March 22, 2026 02:26
@nullsystem nullsystem marked this pull request as ready for review March 22, 2026 02:34
@nullsystem nullsystem changed the title sv_neo_force_... - Give XP/deaths to players, restore from backup sv_neo_restore_... - Give XP/deaths to players, restore from backup Mar 22, 2026
@nullsystem nullsystem marked this pull request as draft March 22, 2026 18:11
@nullsystem nullsystem force-pushed the GH-1878_GiveXP branch 5 times, most recently from d228e68 to 565f240 Compare March 23, 2026 20:38
@nullsystem nullsystem marked this pull request as ready for review March 23, 2026 20:39
@nullsystem nullsystem force-pushed the GH-1878_GiveXP branch 2 times, most recently from 6bff179 to 00bfcda Compare March 23, 2026 20:42
@nullsystem nullsystem requested a review from a team March 23, 2026 20:42
@nullsystem nullsystem force-pushed the GH-1878_GiveXP branch 2 times, most recently from ae245ea to 9851d32 Compare March 23, 2026 22:24
Comment thread src/game/server/neo/neo_player.h Outdated
@sunzenshen sunzenshen requested a review from a team March 24, 2026 07:24
@nullsystem nullsystem requested a review from sunzenshen March 24, 2026 20:27
@Agiel

Agiel commented Mar 24, 2026

Copy link
Copy Markdown
Contributor

We already have commands for setting team score introduced in #1638. Might want to remove those to avoid confusion?

@nullsystem

Copy link
Copy Markdown
Collaborator Author

@Agiel Removed them now: 3419390

Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Comment thread src/game/server/neo/neo_gamerules_restore.cpp Outdated
Native implementation of XP/deaths restoration, with an extra to
automatically backup and manually restore whole session.

ConVars:
* `sv_neo_restore_xp_death_any_round` - Allow setting XP/session anytime
* `sv_neo_restore_session_allow_name_match` - Allow name matching
  in session restore

Commands:
* `sv_neo_restore_session` - Restore entire session from backup
* `sv_neo_restore_round_number` - Force round number
* `sv_neo_restore_rounds_won` - Force Jinrai/NSF rounds won
* `sv_neo_restore_team_scores` - Force Jinrai/NSF scores
* `sv_neo_restore_xp` - Force XP on a player

* fixes NeotokyoRebuild#1878
* Msg with error message -> Warning
* Move functions to NEORules
* Remove some checks
@nullsystem nullsystem requested a review from AdamTadeusz June 20, 2026 11:52
@nullsystem nullsystem added the New Changes for Reviewers New changes has been made. This label is mostly to notify reviewers. label Jun 20, 2026
@nullsystem

Copy link
Copy Markdown
Collaborator Author

Latest code review changes: 83ee375

@nullsystem nullsystem merged commit 796a978 into NeotokyoRebuild:master Jun 27, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

New Changes for Reviewers New changes has been made. This label is mostly to notify reviewers.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Native implemention of giving players XP

5 participants