Where is the file created by savestate?

yodasvideoarcade

New member
Joined
Nov 26, 2017
Messages
35
I want to access the file that is created by SaveState manually (not from the app) to check some data saved by the game. Where do I find that file on Mac?
 
Last edited:

dawlane

Well-known member
CX Code Contributor
Joined
Jun 21, 2017
Messages
795
If memory serves me right it will be down as a hidden file on Mac's and Linux systems.
First check in your $HOME/Library (it's a hidden folder) it should be in there somewhere. If not it may be in the Application bundle.

Finder will not show hidden files and directories by default, so you will have to open up a terminal and type:
defaults write com.apple.finder AppleShowAllFiles TRUE
killall Finder

There are plenty of tutorials on how to set finder to show hidden files and folders.
 

dawlane

Well-known member
CX Code Contributor
Joined
Jun 21, 2017
Messages
795
.cerberusstate
The location depends on the values set with #GLFW_APP_LABEL and #GLFW_APP_PUBLISHER.
 

yodasvideoarcade

New member
Joined
Nov 26, 2017
Messages
35
I have no idea where this is. Please understand, I'm not using Xcode, and I'm not coding every day. In order to understand this, I need a much more detailed answer, for example a complete file path and a "how to".

What I do is: Write code in Cerberus, hit Compile and Run, and that's it. I don't mess with Xcode, app settings or anything like this, since I don't publish that, I just use it on one computer. So I have no idea about all this. The documentation is very frustrating for me, since it's targeted to someone who already knows all this. There should be at least an example for every function, method etc.
 

dawlane

Well-known member
CX Code Contributor
Joined
Jun 21, 2017
Messages
795
There is no full path to where the save state file is stored. The GLFW desktop target stores the file in the application bundles Resource directory. See Bundle Structures. Other targets store them differently, but still should have the .cerberusstate name. You will find the app bundle in the build/glfw3/xcode/build/{Debug/Release} directory.

The #GLFW_APP_LABEL and #GLFW_APP_PUBLISHER directives are meant to create directories where application data is meant to be stored. Usually this would be in the designated section of the users home directory such as APPDATA or .local/shared
For some reason this hasn't been implemented on MacOS. I would have expected this to be in Library/Application Support.
 

yodasvideoarcade

New member
Joined
Nov 26, 2017
Messages
35
I still can't find it. Why is this so complicated? I just want to write some text in a logfile that I can access later, from outside, and that logfile should be at a place where someone without coding knowledge can access it easily.
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
2,815
What I do is: Write code in Cerberus, hit Compile and Run, and that's it. I don't mess with Xcode, app settings or anything like this, since I don't publish that, I just use it on one computer. So I have no idea about all this. The documentation is very frustrating for me, since it's targeted to someone who already knows all this. There should be at least an example for every function, method etc.

Sorry that CX is to complicated. I suggest you use a different tool then, especially if it is just a hobby and you want to use it only on your own computer.
 

yodasvideoarcade

New member
Joined
Nov 26, 2017
Messages
35
I'm using this since it has been Blitzmax. So of course I don't want to change to a different tool. It has never been neccassary to mess with Xcode or anything like that. It always worked, both for HTML5 and GLFW. And right, the GLFW I use only on stationary computers, not for publishing online or something. But it's not a hobby, it's for business.
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
2,815
I'm using this since it has been Blitzmax. So of course I don't want to change to a different tool.
Monkey X and now Cerberus X has nothing to do with BlitzMax. These are different products from BRL.

It has never been neccassary to mess with Xcode or anything like that.
If you want to look and/or files that are created during the build or after you run your app, you need to dig into the app-bundle at least. and so you need to make yourself familiar with Apples way of doing things. If you just want to run apps, then of course, most will work out of the box.
 
Top Bottom