View Single Post
Re: std::fstream Is not writing :(
Old
  (#5)
Lazy
Member
 
Lazy's Avatar
 
Status: Offline
Posts: 236
Join Date: Jan 2004
Location: Toronto, Ontario, Canada
Default Re: std::fstream Is not writing :( - 26-02-2005

1. Yeah, its only that function though all the others are much cleaner.
2. It wasn't always like that, I changed it a while ago just for the hell of it to see if it would work ( bored at the time, and it was late )
3. Hmm, thats new... Thanks for that info.
4. Again, never knew that or have forgotten it since I hadn't used C++ i/o in a long time.
5. Ok
6. That was leftover, I do know that \n is one character I was just accounting for the extra \0 that the compiler adds onto strings.

The code I posted is a total hack I admit, I don't really smooth things out until I know its going to work.

The plugin in general is supposed to detect if the server has crashed and change the map on the next restart.
All it does is checks the content of a file at startup, if its 1 then the server exited cleanly.
If it's 0 that means ServerDeactivate wasn't called and the server must have crashed so it chooses a random map from mapcycle.txt.
  
Reply With Quote