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 / v2 Feature Requests

Author
Message
GarBenjamin
AGK Developer
7
Years of Service
User Offline
Joined: 30th Nov 2016
Location: USA
Posted: 30th Dec 2016 00:21 Edited at: 30th Dec 2016 01:45
@Ortu well cool. I didn't notice that in the docs. Must have missed it. Since the data is inside brackets I am guessing it can span multiple lines. Thanks! I will test it out.

I edited my post to reflect the product already having this.
TI/994a (BASIC) -> C64 (BASIC/PASCAL/ASM/Others) -> Amiga (AMOS/BLITZ/ASM/C/Gamesmith) -> DOS (C/C++/Allegro) -> Windows (C++/C#/Monkey X/GL Basic/Unity/Others)
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 30th Dec 2016 09:14
Quote: "I'd really appreciate the addition, subtraction, multiplication and division shortcuts from C/C++/C#:

var += value (expanded when compiled to var = var + value)
var -= value (expanded when compiled to var = var - value)
var *= value (expanded when compiled to var = var * value)
var /= value (expanded when compiled to var = var / value)"


i suggest that the editor replace it into something that everybody understand because source code exchange.
maybe if you input "a +=" translated direct into "a = a + "
AGK (Steam) V2.0.22 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12)
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 30th Dec 2016 10:27
Quote: "I'd really appreciate the addition, subtraction, multiplication and division shortcuts from C/C++/C#"


It's not an exact match, but in case you haven't found them yet, you have:

inc x,n
dec x,n
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 30th Dec 2016 10:47
Way back when AppGameKit version 1 was just a twinkle in Lee Bambers eye, we had a TGC convention and held a group discussion about what we'd like to see in AGK.
Things that came from that were the removal of spaces within commands (like they are in DBP). So set object position() became SetObjectPosition() - much better!
Square brackets[] to be used for arrays instead of DBPs curved ones() - that gives a clearer differentiation between arrays and functions.
And the use of these shortcut operators was also discussed. Whilst I would love to see them included, it was decided that because AppGameKit (Tier1) was a BASIC language it would be better suited to use inc and dec instead.

A shame, but not an oversight - it was discussed and evaluated before being dismissed.
AGK V2 user - Tier 1 (mostly)
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 30th Dec 2016 11:26
Quote: "Square brackets[] to be used for arrays instead of DBPs curved ones() "

this [] are annoying because i need right alt and 89 keys instead of left shift and 89, so i break my fingers same as {}
i never saw or need this as differentiation between arrays and functions.
most of brackets usage in source code are unnecessary, in case of functions declarations without parameters, or functions call. Sync() why not just Sync ? Print("Hello") = Print "Hello"
this spaces in commands at dbp time i remember too.
AGK (Steam) V2.0.22 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12)
Ortu
DBPro Master
17
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 30th Dec 2016 16:48 Edited at: 30th Dec 2016 16:58
While it takes a minimal amount more typing, it enhances readability greatly, and brings it more in line with just about any other modern language you can name.

Sync without brackets (or anything else) is ambiguous: is it a command? A variable? without familiarity with the native command set it isn't immediately clear. sync () on the other hand explicitly indicates that it is a function, that it *does* something

[] similarly eliminates ambiguity and is standard in virtually all other modern languages.

For a project of any significant size or complexity, readability is far more important than required keystrokes.

I still primarily use dbpro (for 3d stuff anyway), and I've written a preprocessor that allows me to write code using [] array syntax, to compress spaced commands like set object position() into setObjectPosition(), and to add () to commands like sync for these exact reasons.

These changes were excellent advancements in agk over dbpro.
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 30th Dec 2016 18:04
@Ortu
Quote: "Sync without brackets (or anything else) is ambiguous: is it a command? A variable?"

agk did not allow a variable name same as function name.
what should a variable "sync" doing if there is no assignment/operator and it is outside of a condition, for me its pretty clear that is a command, also because knowing the keywords or my own function names or just seeing the source code logic.
modern editors also colorize the type of the word.
in my opinion every needless char disturbs the readability.
today i started a new project and i believe 90% of brackets was unnecessary input.






AGK (Steam) V2.0.22 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12)
Ortu
DBPro Master
17
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 30th Dec 2016 21:35
Everyone has their preferences, but things become a common standard across the majority of languages for a reason. /shrug
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
JohnnyMeek
11
Years of Service
User Offline
Joined: 23rd Apr 2013
Location: Slovenia
Posted: 4th Jan 2017 12:48
Would be great to offer Facebook Gameroom support as an export option. ( Like they have in Unity )
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 9th Jan 2017 09:33
Could we please have alpha levels for EditBox text.

Thanks
AGK V2 user - Tier 1 (mostly)
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 14th Jan 2017 09:10
More 'Windows only' support please.
I'd like better control of the window and would really like to be able to show/hide the mouse pointer and be able change the pointer image.

Thanks
AGK V2 user - Tier 1 (mostly)
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 14th Jan 2017 10:01
@Scraggle
SetRawMouseVisible( 1 )
unitl, you can use any sprite in your game at x,y, for EditBox text if you using it with a font image i think you can set the alpha of the image.
but i agree color should always rgba.
AGK (Steam) V2017.01.09 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12.2)
hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 15th Jan 2017 06:55 Edited at: 15th Jan 2017 06:56
Hello everybody. I haven't used AppGameKit for some time. I have a question.
Do we have Android immersive mode yet? The true fullscreen one that hide the navigation bar?
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 15th Jan 2017 09:03
SetImmersiveMode()
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt
damothegreat
User Banned
Posted: 15th Jan 2017 17:51 Edited at: 15th Jan 2017 18:05
What would be a nice feature is to be able to use Arrays in functions if cant do that already and expand a little on the draw commands. Like



and even better - to be able to FILL it out with a colour

or something along those lines

I think a FILL command can be achievable by working with memblocks - hmmmm something to think about in the future - notjust yet though

but been able to use Arrays diretly on functions would be nice so the code in the snippet would work quiet well

AGK now



Damo
Using Tier 1 AppGameKit V2
Started coding with AMOS
Works with a Lenovo IdeaPad 700, 1TB SSD (Data), 128GB HD (System), 12GB Ram, GeForce Nvdia 950M, Windows 10, 2.3Ghz (Turbo to 3.2ghz when required)
Ortu
DBPro Master
17
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 15th Jan 2017 18:02
Is there a way to call a function by name? If not, it is very handy (callbacks, event handling, scripting)

Like

http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 15th Jan 2017 18:17 Edited at: 15th Jan 2017 18:38
Quote: "What would be a nice feature is to be able to use Arrays in functions"

You can do that already. Just not the way you are doing it.

Try this:


or this:


The second option is considerably faster (3 times faster using the above code) and that is because the polygon isn't passed to the function but referenced by it instead.
AGK V2 user - Tier 1 (mostly)
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 15th Jan 2017 18:18
Quote: "Is there a way to call a function by name?"

Sadly not.
It would be a great feature though.
AGK V2 user - Tier 1 (mostly)
damothegreat
User Banned
Posted: 15th Jan 2017 19:30
Thanks Scraggle - will make things a tad easier in making generalised functions rather than specifically to each app/game
Using Tier 1 AppGameKit V2
Started coding with AMOS
Works with a Lenovo IdeaPad 700, 1TB SSD (Data), 128GB HD (System), 12GB Ram, GeForce Nvdia 950M, Windows 10, 2.3Ghz (Turbo to 3.2ghz when required)
damothegreat
User Banned
Posted: 15th Jan 2017 19:48 Edited at: 15th Jan 2017 19:51
Wow

A Fill technique



Happy days for Quad polygon option

Using Tier 1 AppGameKit V2
Started coding with AMOS
Works with a Lenovo IdeaPad 700, 1TB SSD (Data), 128GB HD (System), 12GB Ram, GeForce Nvdia 950M, Windows 10, 2.3Ghz (Turbo to 3.2ghz when required)
CumQuaT
AGK Master
14
Years of Service
User Offline
Joined: 28th Apr 2010
Location: Tasmania, Australia
Posted: 16th Jan 2017 13:51
I would actually love a means of tweaking and distorting sounds real-time. For example, changing the pitch at which a sound instance plays (without affecting its speed).
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 16th Jan 2017 15:50 Edited at: 16th Jan 2017 16:56
Quote: "changing the pitch at which a sound instance plays (without affecting its speed)."

+1

Also could we have SetTextSnap() that works in much the same way as SetSpriteSnap().

Then we would get ugly text like this:


Thanks
AGK V2 user - Tier 1 (mostly)

Attachments

Login to view attachments
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 16th Jan 2017 21:02
request by user
GetTextHitTest with id = 0 test all text fields
AGK (Steam) V2017.01.09 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12.2)
haliop_New
User Banned
Posted: 18th Jan 2017 13:02
Markus that is exactly what I wanted to write...
this is very frustrating !
Wilf
Valued Member
18
Years of Service
User Offline
Joined: 1st Jun 2006
Location: Gone to Unity.
Posted: 20th Jan 2017 14:46
string GetSkeleton2DBoneName(iSkeleton, BoneID)

Right now we have to use GetSkeleton2DBone( iSkeleton, name ) but its clunky as we have to specify (and know) the name.
Cybermind
Valued Member
21
Years of Service
User Offline
Joined: 28th Nov 2002
Location: Denmark
Posted: 24th Jan 2017 11:37
UDP packets would be really nice. It is hard to make a multiplayer action game without UDP packets.
13/0
SteelPrincess
7
Years of Service
User Offline
Joined: 21st Jan 2017
Location:
Posted: 26th Jan 2017 02:01
Since Facebook now allows direct and free hosting of HTML5 applications on Facebook's own servers and AppGameKit has HTML5 exports, it would be great and logical to have HTML5 Facebook commands that allow us to interact with Facebook and the users using the application.... it's not just for Android and iOS any more.

Pretty please?
janbo
16
Years of Service
User Offline
Joined: 10th Nov 2008
Location: Germany
Posted: 26th Jan 2017 19:00 Edited at: 26th Jan 2017 19:02
+1 for setHTTPHeader() as other also requested it https://forum.thegamecreators.com/thread/212159#msg2534257
Or did someone made http requests using sockets ?

And repair the RecordSound() command !

I wan't speech recognition.
I can receive the recognized text using the curl.exe and a batch file, but thats a bit ugly ...its pretty ugly
I want to record it directly from AppGameKit (preferably directly into a memblock),
then converting it to base64 wraping it into a json formatted string and send it via the inbuilt http commands to the API.

I can use ffmpeg.exe for the recording + sox.exe for the conversion in a better audio file + curl.exe for the HTTP request

Using AGKv2 Tier1
CumQuaT
AGK Master
14
Years of Service
User Offline
Joined: 28th Apr 2010
Location: Tasmania, Australia
Posted: 28th Jan 2017 01:50
Not sure whether this has been asked for yet or not.... In the Synergy editor for DBP there's an option to parse all files in a project upon loading the project. This way, if I right-click->Go to Definition on a function name I don't necessarily have to have that sub-file open in a tab for the IDE to jump over to that function. Currently, as far as I know, AGK2 doesn't have that functionality in there, so if I want to go to a function definition I have to make sure I have that particular sub-file open at the time, which is really just a pesky annoyance more than anything.

I figure if it's easy enough to do I'd love to see it in the next update!
damothegreat
User Banned
Posted: 28th Jan 2017 02:10 Edited at: 28th Jan 2017 02:11
Maybe will it teach us to get a life... Gym, Pub, Nightclub, Rambling etc

No, cause the deep down true programmers love what we do and that's our life x
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 28th Jan 2017 08:48
Quote: "so if I want to go to a function definition I have to make sure I have that particular sub-file open at the time, which is really just a pesky annoyance more than anything."


I agree, but it is also a little more quirky than that. If you have files open from a different project, it will show their functions in the autosense popups.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 28th Jan 2017 20:35 Edited at: 28th Jan 2017 20:36
In unity after create ray cast, you can see it and can better modify it. if TGC add this feature,i'm sure can useful for better control objects.
JohnStabler
AGK Bronze Backer
11
Years of Service
User Offline
Joined: 16th Aug 2013
Location: Cardiff, Wales, UK
Posted: 30th Jan 2017 21:29
Would it be possible to play sprite animations backwards by setting the FPS parameter to a negative value?
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 31st Jan 2017 09:15
Quote: "Would it be possible to play sprite animations backwards by setting the FPS parameter to a negative value?"

You can already do it by setting the end frame lower than the start frame I believe.
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 31st Jan 2017 09:37
Quote: "You can already do it by setting the end frame lower than the start frame I believe."

Sadly not!
That's how it worked in DBP but it doesn't work like that in AGK. A shame - it really should.
I would say this is a valid feature request. It's something that I think is missing that really ought to have been there from day one.
Setting the loop parameter to 2 so that the animation ping-pongs would be nice too
AGK V2 user - Tier 1 (mostly)
CJB
Valued Member
20
Years of Service
User Offline
Joined: 10th Feb 2004
Location: Essex, UK
Posted: 31st Jan 2017 12:13
For my current project, I am using a VPS to capture player activity / keep track of score / progress etc. This uses the uniqiue device ID as primary key, however I'd like to allow a user to play on multiple devices and take their progress with them. I have seen this done on some games (Boom Beach is a good example) by using the Google Game Services gamer ID, so as long as a user is logged into their google play account on a device, they can access their game on that device.

This would be quite simple to implement if we could retrieve the Gamer ID using the Game Centre Services commands. - I appreciate this has been cleverly abstracted so we don't need to worry about player ID's and such, but having the ability to do so would be very handy for this particular scenario. i.e. If a Game Centre Player ID is available, then I store that alongside the existing player's record on my server, making another key when available.

So my request is to add:

String = GetGameCentrePlayerID()

Thanks.





Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 31st Jan 2017 13:29 Edited at: 31st Jan 2017 13:30
@Behdadsoft
Quote: "In unity after create ray cast, you can see it "

until you can use the drawline and commands that calculate the x,y screen position from x,y,z ray start to end
AGK (Steam) V2017.01.09 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12.2)
JohnnyMeek
11
Years of Service
User Offline
Joined: 23rd Apr 2013
Location: Slovenia
Posted: 31st Jan 2017 13:43 Edited at: 31st Jan 2017 13:44
Quote: "For my current project, I am using a VPS to capture player activity / keep track of score / progress etc. This uses the uniqiue device ID as primary key, however I'd like to allow a user to play on multiple devices and take their progress with them. I have seen this done on some games (Boom Beach is a good example) by using the Google Game Services gamer ID, so as long as a user is logged into their google play account on a device, they can access their game on that device. "


I do this is in my latest project, you can login with facebook from any device and all your progress is saved:-

Slot Skilz iOS
Slot Skilz Android

I use PARSE, it's open source and you can host it yourself, or there are lots of 3rd party hosting services. ( I actually use sashido.io )

You can have a custom login, or connect with facebook. I also have leaderboards & push notifications hosted on the same service.
Carharttguy
8
Years of Service
User Offline
Joined: 8th Jul 2016
Location: Belgium
Posted: 31st Jan 2017 14:58
Quote: "Is there a way to call a function by name? If not, it is very handy (callbacks, event handling, scripting)"


Interesting question, why would you need that? I cannot think of a real life situation where I would need that.
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 31st Jan 2017 15:15 Edited at: 31st Jan 2017 15:17
Quote: "hy would you need that? I cannot think of a real life situation where I would need that."

PHP has it, and it is actually quite useful as you can use it to create an in game script engine among other things.
I.E. Read in an external script containing things like spawnNPC( bill, 100.0, 100.0, 100.0 ) You would have in your code an actual spawnNPC function you could call straight from script.
Currently you'd have to have a script parser that reads each line, checks against a bunch of if commands then calls the function like how I do in my script engine. I'd read the line in, extract the first token (spawnNPC) then have an if command for each possible script command.

I have dozens of script commands in my script engine, so my script handling section is very large! Calling functions from String variables would be very usefull
Ortu
DBPro Master
17
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 31st Jan 2017 19:24 Edited at: 31st Jan 2017 20:10
Quote: "Interesting question, why would you need that? I cannot think of a real life situation where I would need that."


It allows for callbacks... call the function stored as a variable when something happens or completes

It let's you pass arbitrary and variable functions as arguments to other functions.

Dbpro has this through matrix1 (as well as calling a function by pointer), there are several basic ways that I use this in Sulium

1) UI event handlers. I layout my UI elements in xml files, the element can declare what function should be called for various events like onClick, onHover.

When the program detects an event on an element, it calls the specified function by name taken from the xml.

This lets me make quite a lot of changes to the ui without having to recompile the program.

The same principal is applied to world/object zone and trigger events. I store level data in sqlite database, this lets me configure and load content dynamically, again allowing a great deal of editing without needing to recompile.

2) setInterval(function, interval, totalticks)

I can set any given function to repeat the given number of times and interval at any time. This is handy for anything from creating complex transitions, to applying character effects and abilities (regeneration, damage over time)

Basically it let's me set up on the fly and/or temporary updates not hard coded into the main loop updates.

3) animation callbacks. By breaking animation down into phases through the use of an 'applied animations queue' I can call handlers to check if a looping animation should continue to loop, when an animation reaches its end or stops looping, I can callback to cleanup functions outside the animation module that need to do things to characters, resolve combat attacks etc. (When an attack animation reaches its peak, I need to resolve a combat hit. The result of the hit/defense/miss may alter the animation queue of both characters involved. Jumping is also fairly complex, Character states need to be managed and synced with animation. )

By passing these functions by name to the animation handler, the animation module remains generic, simple and reusable across projects: nothing in the module is specific to any game, I can drop it into any project and it just works. It can link up to game specific functions as needed by keeping those functions as more abstract arguments.

You can (and I do) set up a work around using select case in a dispatcher function



But you have to remember to register any function that will be called, and it isn't as performant add native support would be
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
MikeMax
AGK Academic Backer
12
Years of Service
User Offline
Joined: 13th Dec 2011
Location: Paris
Posted: 1st Feb 2017 20:30
Hi,

I would like to see a full access to computer storage (read/write). in "AppGameKit" there is "App".... For example, i want to create a 3D Map Editor with full import from OBJ which will determine the MTL File to retrieve, and getting the Textures images. It's problematic to first copy all necessary files into the media folder to use them.

The already integrated folder/files commands are cool ... but it should be cool to have an option to "unlock" the local restriction for theses commands for computers
--------------------------------
Join us on dedicated AppGameKit WeeKChat :
https://week.chat/room/AppGameKit
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 1st Feb 2017 21:17 Edited at: 1st Feb 2017 21:19
You can do this already.

ChooseRawFile() lets the user find a file anywhere on disk
GetDocumentsFolder() can be used to work out the main drive letter as well as where the user folders are
Once you have the drive letter you can use setRawWritePath() and GetFirstFolder() / GetNextFolder() to find any folder on the drive.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 1st Feb 2017 21:18 Edited at: 1st Feb 2017 21:24
Quote: " but it should be cool to have an option to "unlock" the local restriction"

that is a ms os fail sice the beginning.
the user should give the app permissions, not the app or developer itself. ms giving even oneself access without user agreement.
my opinion is that the app should ask (path dialog) for a read/write folder and then just use it.
in your case the agk should accept the file system permissions.
AGK (Steam) V2017.01.09 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12.2)
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 1st Feb 2017 21:21
Quote: "the user should give the app permissions"


But your average user doesn't even know what a permission is, they would have no idea how to set them, or would do it incorrectly.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 1st Feb 2017 21:57
@BatVink
it is very easy to make a select view, app and folder.
ms have a problem with simple tasks.
for very stupid users you can provide a default sharing folder.
this permissions problem is also there for hardware access, windows 10 become a little bit better in this part but it is still badly thought-out/solved.







AGK (Steam) V2017.01.09 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12.2)
Ortu
DBPro Master
17
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 1st Feb 2017 23:09
Quote: "that is a ms os fail sice the beginning.
the user should give the app permissions, not the app or developer itself. ms giving even oneself access without user agreement.
my opinion is that the app should ask (path dialog) for a read/write folder and then just use it.
in your case the agk should accept the file system permissions."


Not sure I follow. When a user runs an app, the app runs with the permissions of that user account. The only restriction that windows imposes is through UAC to protect certain system files and directories. The user has the ability to run the app with elevated permissions if access to these files are needed.

Applications cannot grant themselves additional access that the user account running the application doesn't already have.

Any restriction on agk to using only the media folder is a restriction enforced by agk and has nothing to do with windows.

If agk wanted to allow developers and/or users to access additional locations outside of the app root, it's on agk to do so within the confines of the user's os/fs permissions.

Frankly it would be a nightmare for users to have manage directory permissions on an app by app basis, it can get messy enough managed at a user/usergroup basis.
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
MikeMax
AGK Academic Backer
12
Years of Service
User Offline
Joined: 13th Dec 2011
Location: Paris
Posted: 2nd Feb 2017 07:25 Edited at: 2nd Feb 2017 08:47
Quote: "You can do this already.

ChooseRawFile() lets the user find a file anywhere on disk
GetDocumentsFolder() can be used to work out the main drive letter as well as where the user folders are
Once you have the drive letter you can use setRawWritePath() and GetFirstFolder() / GetNextFolder() to find any folder on the drive."



BatVink,

after having set the documents path (or elsewhere) with the setRawWritePath() command, ChooseRawFile() command will (re)copy the chosen file into it... and it's not the wanted behavior. if i choose an OBJ file, parse it, and retrieve the associated MTL file (along the OBJ file in the same place), i can't get the subfolder selected (if different from the root folder) with the ChooseRawFile() .... even in the documents folder...

edit: after testing a little and playing with SetFolder and setRawWritePath() , it seems the only problem is getting the relative subfolder of the chosen file. the ChooseRawFile() only returns the name of the chosen file, not the full path nor the relative subpath.

Permissions are not a real problem. we know that UAC exists and if we want the app to access special folders, we can start the app with admin rights if needed (like all other applications)

The real solution (only for computers) should be having ChooseRawFile() retrieve the full path and SetFolder working everywhere on disk to gain read access to all the files along the chosen one (for a working LoadImage etc...). Actually , for example , it's not possible to read an arbitrary Image with a specific path outside the "read folder" which is restricted.

To see the problem, the idea is to take myobjtexture.png image along my chosen file myobj.obj outside the read folder or write folder:

1. Choose the myobj.obj file in an arbitrary folder outside the read/write folders (which will copy it in my write folder ... but without his texture file.... obviously)
2. i can't get the texture image aside the OBJ file because i don't know the full path (not retrieved by the ChooseRawFile() command)
3. even if i had the full path and having the correct texture filename, LoadImage is restricted to read/write folders ...
4. so i am disappointed ! :p

--------------------------------
Join us on dedicated AppGameKit WeeKChat :
https://week.chat/room/AppGameKit
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 2nd Feb 2017 07:48 Edited at: 2nd Feb 2017 08:36
Any chance of a SetOrientation() command.
To use purely as a test in windows to simulate putting a device into a particular orientation for when we don't have access to a device or network capable of broadcasting?

[EDIT]
Actually, you can forget this. It's very easy to fake it for testing purposes - which is all it would be need for.

Thanks
AGK V2 user - Tier 1 (mostly)
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 2nd Feb 2017 09:22
@MikeMax, I think the only solution to your problem is to make a custom file chooser. Then you will know everything you need to know.
It's more work, but it would be code you could reuse in any project.

Maybe we should make it the Coding Challenge
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt

Login to post a reply

Server time is: 2024-11-23 17:51:27
Your offset time is: 2024-11-23 17:51:27