Note: The question asks about Minecraft Pi, which apparently isn't just Minecraft on a Raspberry Pi.
Minecraft must be told to
/quit so that it can properly shutdown and save. If you do not properly save the changes to disk, it is unlikely you will be able to recover your world or the changes you made.
Using the Minecraft console, you can issue
/save periodically to make saves to prevent this issue. Alternatively, you can give your account admin/moderator privileges and issue this command from your client. If you put your Minecraft console on a pipe, you can pipe in commands via
# Starting the server each time
tail -f serverpipe | java -Xms1G -Xmx5G -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -jar minecraft_server.1.14.jar nogui
# Running a command and testing
echo "/say Hello, world" > serverpipe
echo "/save" > serverpipe
# Cron entry to save every hour
0 * * * * /bin/echo "/save" /full/path/to/minecraft-1.14/serverpipe
Be warned that if you save, there is no backup of previous saves. This is most important if your server does not use a whitelist, or there is any reason you could be "griefed". If the server automatically saves every hour, it will save, even if someone pours lava all over the world.