Join us on Discord!
You can help CodeWalrus stay online by donating here.

Hero Core - Tools

Started by Keoni29, January 01, 2015, 12:12:07 AM

Previous topic - Next topic

0 Members and 3 Guests are viewing this topic.

Keoni29

#15
What kind of undo/redo implementation would suffice? Simple flip-undo or a linear undo stack which holds all changes?

Edit: Cleaned up source and added code summary/index.
If you like my work, why not give me an internet?

Dream of Omnimaga

It doesn't have to hold 9001 changes, but at least 3-5 would be great (unless it doesn't take much RAM then you could add more).
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

aetios

A stack would be ideal. I don't think it'd be much different if it holds 9000 or 2 changes, so make it big :p
ceci n'est pas une signature

Dream of Omnimaga

Quote from: aeTIos on January 05, 2015, 12:08:08 PM
A stack would be ideal. I don't think it'd be much different if it holds 9000 or 2 changes, so make it big :p
i was pointing out because in image editors, one Undo can be worth several MB of RAM. O.O
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Keoni29

I was thinking about an actions stack as well. I want to revert all tile placements in one drag every time you undo, but I would like to have a redo function as well. With a regular stack I cannot do that. I need a stack that can go back without pushing a new value on top.
If you like my work, why not give me an internet?

Keoni29

The commandline options processing works now. I just have to add some more tests for invalid input combinations so the user cannot break the editor :P
If you like my work, why not give me an internet?

Dream of Omnimaga

As long as it doesn't become command-like-only :P (I hate working in command prompt because it takes so long to type anything and batch files are not always an option)
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Keoni29

You only have to specify parameters once. The editor configuration as well as the tilemap are stored in .core files (but not in the exported appvar)
When you load a .core file the editor is automatically configured :)
If you like my work, why not give me an internet?

Dream of Omnimaga

Ah ok that's good then lol. Many command prompt-based softwares won't do that.
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Keoni29

Yes! I got it to build on windows without modifying the source! Setting up a compiler and SDL is a lot more work on windows compared to linux tho O.O

I am still having some issues with loading PNG files and getting the stdout to display in the cmd window instead of writing to a file as well as exporting to appvars. This means I have to figure out what windows is doing differently.
If you like my work, why not give me an internet?

Dream of Omnimaga

Cool to hear. Good luck with the rest. Hopefully you can make this program for multiple OSes without having to work on two different versions simultaneously.
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Keoni29

I just cleaned up my source a bit and I added some checks, so bad user input won't break the editor :P
If you like my work, why not give me an internet?

Dream of Omnimaga

So we can't add 3D to the game? :P
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Keoni29

The user cannot break it. Other coders can. It is open source, so if you want to add a depth axis to it, that is fine with me :P
If you like my work, why not give me an internet?

Dream of Omnimaga

Oh I meant before you improved it to prevent users from breaking it. :P


That said, depth would be interesting for an HP Prime port :P
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Powered by EzPortal