[E] Stop crafting session serverside when finishing last step (#27)

This fixes an exploit where you can craft a prototype for a limited use schematic, but before it finishes you teleport by some means to a different game server to prevent the schematic from decrementing.
This commit is contained in:
Rory King
2022-07-30 11:02:08 -04:00
committed by GitHub
parent ac2b7d70dd
commit 20501250af
@@ -5763,8 +5763,7 @@ static void commandFuncCreatePrototype(const Command&, const NetworkId& actor, c
GameControllerMessageFlags::RELIABLE |
GameControllerMessageFlags::DEST_AUTH_CLIENT);
if (!result)
player->stopCrafting(false);
player->stopCrafting(result);
}
// ----------------------------------------------------------------------
@@ -5795,8 +5794,7 @@ static void commandFuncCreateManfSchematic(const Command&, const NetworkId& acto
GameControllerMessageFlags::RELIABLE |
GameControllerMessageFlags::DEST_AUTH_CLIENT);
if (!result)
player->stopCrafting(false);
player->stopCrafting(result);
}
// ----------------------------------------------------------------------