Comments (5)
I will start to check this issue !
So I found AdvanceToLocation
who take a turn. So we could store all first turn of each level and used them when we press "<" with a confirm prompt.
What do you think about this technique ?
from broguece.
I think storage of first turns on each level may not be necessary. How does the implementation of go to next level ('>') work? I think we might be able to define '<' as something like
- save (current depth - 1) to N
- rewind to start of recording
- do '>' max{0, N-1} times
from broguece.
">" implementation is just a "while" until we are to the next level (with some option to fastforwarding) :
pauseState = rogue.playbackPaused; previousDeepestLevel = rogue.deepestLevel; if (!rogue.playbackPaused || unpause()) { if ((unsigned long) rogue.deepestLevel < maxLevelChanges) { displayCenteredAlert(" Loading... "); commitDraws(); rogue.playbackFastForward = true; while ((rogue.deepestLevel <= previousDeepestLevel || !rogue.playbackBetweenTurns) && !rogue.gameHasEnded) { rogue.RNG = RNG_COSMETIC; // dancing terrain colors can't influence recordings nextBrogueEvent(&theEvent, false, true, false); rogue.RNG = RNG_SUBSTANTIVE; executeEvent(&theEvent); } rogue.playbackFastForward = false; rogue.playbackPaused = pauseState; displayLevel(); refreshSideBar(-1, -1, false); updateMessageDisplay(); } else { flashTemporaryAlert(" Already reached deepest depth explored ", 1000); } } rogue.playbackPaused = pauseState;
And the function
BrogueCE/src/brogue/Recordings.c
Line 612 in f3bb9a5
Can we standardize "<" and ">" function with this function (advanceToLocation) ?
- We just need to store an array with the turn number of each start level when we read the recording file (
parseFile
) - When < or > press key : Navigate in the array with
advanceToLocation
It's just an idea, else I can implement your previous suggestion.
from broguece.
When the target location is in the past, advanceToLocation
works in a similar way: by rewinding to the start and fast-forwarding. Because of this, storing any data is unnecessary - instead of fast-forwarding until we hit a certain turn number (advanceToLocation), we just fast-forward until we get to a certain depth. Does that make sense?
from broguece.
Yes, my reflexion was a bit stupid... I will propose you something !
from broguece.
Related Issues (20)
- Unable to build on Win 11 (BUILD.md outdated?) HOT 4
- Allow nearest-neighbor scaling and pixel-perfect window size options HOT 2
- Prompt for weapon degrade confirmation when hallucinating and telepathic
- 1.13 on Windows is falsely flagged as a virus HOT 2
- Goblins don't know how to swim HOT 4
- BrogueCE-1.13-windows HOT 2
- Mirrored totem glyphs block path to rest of level, including downstairs
- When a turret or totem is negated there is no obvious indication of effect
- [Question] What does `pdsMap` mean?
- [Question] How to compile for Miyoo Mini? HOT 2
- Gauging Interest in Controller Support and Potential Pull Request HOT 6
- A dialog should appear if peforming an attack would turn an ally into an enemy
- [Opinion] Eels shouldn't be able to open doors HOT 2
- Auto-ID ring kind if possible
- Rat trap wall broke open a vault HOT 2
- Bloodwort submerged in lava HOT 1
- Fire potion doesnโt ignite door after returning from descent potion
- Grappled, blink away, monster blinks adjacent and immediately grappled again
- Priority issue; goblin tool pile renders over shallow water
- Hunting monster stuck on corner, but easy path to player HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from broguece.