- Adding (dead) code for Story mode. This is FAR from being ready so it's deactivated in the code. I just don't want to create a branch (I'm lazy) and I'm fed up with synching. My Goal is to have a tutorial ready with this for the release after this one. If you want to test it (Note: the sample story is not interesting at ALL), just look for "Story mode" and uncomment (3 occurrences). PSP Or Linux need additions to the Makefile...
This commit is contained in:
wagic.the.homebrew@gmail.com
2010-02-16 10:55:03 +00:00
parent 8a19b0567b
commit d5be045859
16 changed files with 618 additions and 4 deletions

View File

@@ -246,6 +246,8 @@ void Rules::initPlayers(){
MTGDeck * deck = buildDeck(i);
if (deck) {
p->game->initDeck(deck);
SAFE_DELETE(deck);
p->game->setOwner(p);
}
}
}
@@ -321,7 +323,11 @@ Rules::Rules(string filename){
int Rules::load(string _filename){
char filename[4096];
sprintf(filename, RESPATH"/rules/%s", _filename.c_str());
if (fileExists(_filename.c_str())){
sprintf(filename, "%s", _filename.c_str());
}else{
sprintf(filename, RESPATH"/rules/%s", _filename.c_str());
}
std::ifstream file(filename);
std::string s;