Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
@ivascua
Latest commit ff8237a Feb 8, 2020 History
And when saving, it only saves the player's (x,y) coordinates, health, attack and xp; it does not save the map.

Save by pressing P.
1 contributor

Users who have contributed to this file

#include <iostream>
#include <fstream>
using namespace std;
void saveGame(int x, int y, int health, int attack, int xp){
ofstream f("latestSaveFile.txt");
f << x;
f << ".";
f << y;
f << ".";
f << health;
f << ".";
f << attack;
f << ".";
f << xp;
f.close();
}