add $meseta command

This commit is contained in:
Martin Michelsen
2023-09-25 21:42:36 -07:00
parent 65f8dea0da
commit 5e14a8449c
3 changed files with 21 additions and 2 deletions
+1
View File
@@ -24,6 +24,7 @@
- Spectator teams
- Spectator teams sometimes stop receiving commands during live battles?
- It may be possible to send spectators back to the waiting room after a non-tournament battle by sending 6xB4x05 with environment 0x19, then 6xB4x3B again; try this
- Add support for recording battles on the proxy server (both in primary and spectator teams)
## PSOBB
+16
View File
@@ -625,6 +625,21 @@ static void server_command_playrec(shared_ptr<Client> c, const std::u16string& a
}
}
static void server_command_meseta(shared_ptr<Client> c, const std::u16string& args) {
check_is_ep3(c, true);
if (!c->options.debug) {
send_text_message(c, u"$C6This command can only\nbe run in debug mode\n(run %sdebug first)");
return;
}
uint32_t amount = stoul(encode_sjis(args), nullptr, 0);
c->license->ep3_current_meseta += amount;
c->license->ep3_total_meseta_earned += amount;
c->license->save();
send_ep3_rank_update(c);
send_text_message_printf(c, "You now have\n$C6%" PRIu32 "$C7 Meseta", c->license->ep3_current_meseta);
}
////////////////////////////////////////////////////////////////////////////////
// Game commands
@@ -1528,6 +1543,7 @@ static const unordered_map<u16string, ChatCommandDefinition> chat_commands({
{u"$ln", {server_command_lobby_type, proxy_command_lobby_type}},
{u"$ep3battledebug", {server_command_enable_ep3_battle_debug_menu, nullptr}},
{u"$maxlevel", {server_command_max_level, nullptr}},
{u"$meseta", {server_command_meseta, nullptr}},
{u"$minlevel", {server_command_min_level, nullptr}},
{u"$next", {server_command_next, proxy_command_next}},
{u"$password", {server_command_password, nullptr}},
+4 -2
View File
@@ -295,8 +295,10 @@
// Winning the final round is worth this much extra Meseta.
"Episode3FinalRoundMesetaBonus": 300,
// If this option is enabled, the jukebox in Episode 3 lobbies does not deduct
// any Meseta when a song is played. The player must still have at least 100
// Meseta to play a song, however.
// any Meseta when a song is played. The check for 100 or more meseta happens
// client-side, however, so even if this option is enabled, the client must
// either have 100 or more Meseta or use the "Jukebox is free" Action Replay
// code to be able to play songs.
"Episode3JukeboxIsFree": false,
// Episode 3 battle behavior flags. When set to zero, battles behave as they