Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / AGK2 is missing the GETFILEEXISTS command?

Author
Message
Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 9th Dec 2014 09:01 Edited at: 9th Dec 2014 09:20
Ok, so missing is probably the wrong word - the command does exist but it doesn't behave as expected. The way I would expect it to behave is missing a command.

GetImageExists - Checks to see if an image ID is in use
GetSpriteExists - Checks to see if a sprite ID is in use
GetFileExists -Checks to see if there is a file on the devices storage system with the given filename(!)

There seems to be no way to determine if a file ID is in use.
I would expect GetFileExists to perform that function in line with the sprite and image commands. Perhaps renaming the current command to GetFileNameExists.

I've been away from the TGC community for a while and I'm very new to AppGameKit so help me out here - is there a way to get things like this to the attention of the developer?
Is it Lee or Paul that is dealing with AppGameKit?

[Edit]
On a similar subject: OpenToWrite does not appear to be working.
From the help file: "If the file does not exist it will be created". It doesn't create one for me. I checked to project root folder and the media folder but there is nothing getting created.
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 9th Dec 2014 09:16
normal a file did not stay open,
its just open/read/write/close
this give u a free id, u do not think about if it is free.
id=OpenToRead( szFile )
its valid until u use CloseFile, after close use id=0.
u can wrote at "AGK Version 2.0.10" paul working at v2.

AGK 108 (B)19 + AppGameKit V2 Alpha .. : Windows 8.1 Pro 64 Bit : AMD Radeon R7 265 : Mac mini OS X 10.10 (Yosemite)
=PRoF=
21
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 9th Dec 2014 13:48 Edited at: 9th Dec 2014 13:50
AGK2 saves the files in an odd place, not sure off hand where it is.. *scurries off to check*

C:\Users\your_name\AppData\Local\AGKApps\app_name\media\

Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 9th Dec 2014 13:58
Cheers Prof, that works.

But where does it save the file on a mobile device? Or is that not an option?
=PRoF=
21
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 9th Dec 2014 14:09
It varies depending on version of android I think. It doesn't really matter. Where ever it saves it, You only have to worry about the path inside the media folder (From inside AppGameKit anyway).

You really only get to read and write inside the "sandbox" area with Android and iOS; I believe you can use the Raw file access commands to navigate a proper PC file system (unsure about Mac).

One really disappointing thing with AppGameKit is how limited you are with saving images into the gallery. It could do it last time I checked, but neglected to update the gallery, so your image didn't show up until you restarted the phone. You also had no control over the filename.

Login to post a reply

Server time is: 2024-05-03 14:37:48
Your offset time is: 2024-05-03 14:37:48