Chaosforge Forum

  • April 28, 2024, 10:19
  • Welcome, Guest
Please login or register.



Login with username, password and session length
Pages: [1]

Author Topic: Quicksave protection?  (Read 3071 times)

Omega Tyrant

  • Elder
  • Sergeant
  • *
  • *
  • Offline Offline
  • Posts: 62
    • View Profile
Quicksave protection?
« on: May 01, 2012, 02:06 »

I recently had a A100 run that was going amazingly well. When I was on the 89th floor, about to advance to the 90th while still in perfect shape, my laptop suddenly turned itself off due to low battery, without having gave me the low battery warning beforehand. With no save protection for such circumstances, that run is now gone, with absolutely nothing to show for it.

As such, would it be possible to implement a feature, where if Doom RL is abruptly ended while still in play, the game will do a quicksave of where you were before the game turned off? Seeing such deep runs just vanish like that is discouraging.
« Last Edit: May 01, 2012, 02:14 by Omega Tyrant »
Logged
Badges - [26|26|26|17|5|0]
Medals - 35/43

Kornel Kisielewicz

  • God Hand
  • Apostle
  • *
  • *
  • Offline Offline
  • Posts: 4562
    • View Profile
    • http://chaosforge.org/
Re: Quicksave protection?
« Reply #1 on: May 01, 2012, 08:15 »

Problem is that DoomRL would have no way to detect whether your power went off or you did a force close on it.
Logged
at your service,
Kornel Kisielewicz

Game Hunter

  • Programmer
  • Local Inquisitor
  • Lieutenant General
  • *
  • *
  • Offline Offline
  • Posts: 1044
  • Looks like game to me.
    • View Profile
    • Channel, the Roguelike
Re: Quicksave protection?
« Reply #2 on: May 01, 2012, 10:07 »

Problem is that DoomRL would have no way to detect whether your power went off or you did a force close on it.
I don't know if we need to make that distinction. Obviously if it's an unexpected shutdown (i.e., power outrage without backup) then nothing can be done, but if it's a "this computer's out of power, let's start shutting down" automatic process then it should be able to do an autosave all the same. I also doubt there are enough people who use force-close to restart the game to consider the negative side-effects.

So I guess I don't see any problems with adding it. It'll be more useful once "save anywhere" is implemented, at least.
Logged
I'm just a dude playing a dude disguised as another dude.

Latest LPs: Angband, Delver

Kornel Kisielewicz

  • God Hand
  • Apostle
  • *
  • *
  • Offline Offline
  • Posts: 4562
    • View Profile
    • http://chaosforge.org/
Re: Quicksave protection?
« Reply #3 on: May 01, 2012, 10:11 »

Game Hunter, you didn't get the point :) -- you're about to die? Do a force close and replay the level from the save point. Unless we had save anytime, and the game would save on every move, this would be an exploit to save your character.
Logged
at your service,
Kornel Kisielewicz

Game Hunter

  • Programmer
  • Local Inquisitor
  • Lieutenant General
  • *
  • *
  • Offline Offline
  • Posts: 1044
  • Looks like game to me.
    • View Profile
    • Channel, the Roguelike
Re: Quicksave protection?
« Reply #4 on: May 01, 2012, 11:18 »

Do a force close and replay the level from the save point.
Oh right, derp. Change that "more useful" to "only workable" from the previous post, then!
Logged
I'm just a dude playing a dude disguised as another dude.

Latest LPs: Angband, Delver

thelaptop

  • Chaos Fanatic!
  • Grand Inquisitor
  • Apostle
  • *
  • *
  • Offline Offline
  • Posts: 2530
    • View Profile
Re: Quicksave protection?
« Reply #5 on: May 01, 2012, 11:25 »

How about storing the save file (for the previous level) plus some transaction-log-like thing that stores the current seed and a transaction record of moves taken to replay?  In short, we use save points as a "committed" transaction, and then use redo-logging to recover the lost state for the current level.

Maybe incorporate a query to the OS on how long it has been up compared to some checkpoint in the move transaction log.  =P
Logged
I computed, therefore I was.
Pages: [1]