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 / AGK Version 2.0.10

Author
Message
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 13th Jan 2015 11:34
Quote: "What I think AlistairS ment is that RandomSign(Random(0,1)) gives an equal chance for the numbers -1, -0, +0 and +1 to be chosen. -0 = +0 so the number 0 has double the probability of the other numbers. Or am I wrong? "

No, I am wrong. I was not thinking straight. I didn't consider that you could (effectively) have a minus and plus version of zero...

I guess the best way as previously shown would be Random(0,2)-1. Most of the time I am using my technique for applying a random velocity to a particle or something similar so a slightly higher chance of zero is not really a problem when you're talking about figures in their hundreds anyway, but yes I was wrong and AlistairS was right

Maybe I should leave my thinking for the daytime


Using AppGameKit V2 Tier 1
JimHawkins
14
Years of Service
User Offline
Joined: 26th Jul 2009
Location: Hull - UK
Posted: 13th Jan 2015 11:54
You could always call the function twice if the result was zero?

Onwards and sometimes upwards
Ranietz
AGK Gold Backer
19
Years of Service
User Offline
Joined: 2nd Sep 2004
Location: Norway
Posted: 13th Jan 2015 12:11
No worries baxslash. None of us can think straight all the time.
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 13th Jan 2015 13:52
Half the time would be nice


Using AppGameKit V2 Tier 1
AlistairS
11
Years of Service
User Offline
Joined: 28th Apr 2013
Location: U.K.
Posted: 15th Jan 2015 08:59
When I use a DrawBox() call and run the app on my PC I get three horizontal lines running the full width of the box about quarter of the way down. It works fine (no lines) on my Android tablet.

Anyone else get this effect on their desktop?
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 15th Jan 2015 09:31
I have 3 problems with the IDE on Windows (Steam install):
1-Adding new files to the project is forgotten next time I load the project. I have to manually add them to the agk text file.
2-The IDE never remembers what files were open last time.
3-The "Current Project" dropdown has about a thousand copies of the same project. Seems to just keep adding the current project over and over...


Using AppGameKit V2 Tier 1
SoftMotion3D
AGK Developer
18
Years of Service
User Offline
Joined: 24th Aug 2005
Location: Calgary,Alberta
Posted: 15th Jan 2015 20:22
paul would you be able to look at this problem as its hindering my projects aswell.

http://forum.thegamecreators.com/?m=forum_view&t=212835&b=41

Maybe some work was done with strings er something but it has drasticaly increased the time it takes to load a single 3d obj file from the earlier alpha to now. Even v1 is much faster at loading obj files

www.sheldonscreations.com
Impetus73
12
Years of Service
User Offline
Joined: 28th Aug 2011
Location: Volda, Norway
Posted: 15th Jan 2015 20:39 Edited at: 15th Jan 2015 20:41
The drawbox command is relatively useless, as it always produce a native resolution 1 pixel thick line, even if everything else is scaled, like text and sprites... so on high res devices, they gets ultra thin, and on lowres devices they get thick, relative to all the other objects in the AppGameKit universe...

I guess they are only useful for making simple graphics, that you then generate sprites from. I never use them as UI elements in a game.

I also get glitches and missing pixels in the shapes.

It's better to make your own drawbox command, using 4 sprites.

----------------
AGK programmer
Did Amiga / AMOS programming in the 90's.
AlistairS
11
Years of Service
User Offline
Joined: 28th Apr 2013
Location: U.K.
Posted: 16th Jan 2015 08:21
@Impetus73 I appreciate what you are saying about the limitations of DrawBox() but I am not using it to create software, I'm simply trying to do a write up of the command for the next version of Hands On AppGameKit BASIC. And at the moment, I'm getting horizontal lines when I create a filled box, so I was wondering if its something to do with my video card or if everyone else has the same problem when using it on a PC.
Impetus73
12
Years of Service
User Offline
Joined: 28th Aug 2011
Location: Volda, Norway
Posted: 16th Jan 2015 15:16
Do you have an example code, that we can test?

----------------
AGK programmer
Did Amiga / AMOS programming in the 90's.
AlistairS
11
Years of Service
User Offline
Joined: 28th Apr 2013
Location: U.K.
Posted: 16th Jan 2015 18:27
Here's the code that causes problems with DrawBox():
Ranietz
AGK Gold Backer
19
Years of Service
User Offline
Joined: 2nd Sep 2004
Location: Norway
Posted: 16th Jan 2015 18:32 Edited at: 16th Jan 2015 18:43
Quote: "Here's the code that causes problems with DrawBox():"


I also get 3 horisontal lines with that code on windows.

Edit: Using Virtual resolution instead of display aspect seems to work.

Impetus73
12
Years of Service
User Offline
Joined: 28th Aug 2011
Location: Volda, Norway
Posted: 16th Jan 2015 20:07
Works fine on my PC, it's a Windows 8.1 Pro, 8GB, i7-4790@3.60GHz, with NVIDIA GeForce GTX660

----------------
AGK programmer
Did Amiga / AMOS programming in the 90's.
paulrobson
9
Years of Service
User Offline
Joined: 22nd Nov 2014
Location: Norfolk, England
Posted: 16th Jan 2015 21:53
Would it be an idea to make the drawing primitive a triangle ? This is the OpenGL primitive and can be used to make other 2D shapes quickly ?
george++
AGK Tool Maker
16
Years of Service
User Offline
Joined: 13th May 2007
Location: Thessaloniki, Hellas
Posted: 16th Jan 2015 22:26
I have similar issues with the DrawBox() function on my PC.
The lines of the non-filled box are not vertical
I suspect floating point precision issues
AlistairS
11
Years of Service
User Offline
Joined: 28th Apr 2013
Location: U.K.
Posted: 17th Jan 2015 07:34
Thanks to everyone who took the trouble to test the DrawBox()code. Much appreciated.
JimHawkins
14
Years of Service
User Offline
Joined: 26th Jul 2009
Location: Hull - UK
Posted: 17th Jan 2015 09:30
The original is fine on GTX 750. Could be a GPU or driver issue.

Onwards and sometimes upwards
Tone Dialer
Valued Member
18
Years of Service
User Offline
Joined: 17th Oct 2005
Location: England, well a town in it !
Posted: 20th Jan 2015 20:57 Edited at: 20th Jan 2015 21:07
@Paul

The V2.0.10 SeekMusic() command does not seem to work correctly on Android devices, the Relative Mode is acting in the same way as Absolute Mode. Tested on Android 2.3.3 and 4.0.3, however it works as expected in Windows.

Quick piece of test code (requires music.mp3 to be in the media folder)

In the example the Skip Fwd button should skip the music forward 10 seconds from the present position, but under Android it just seeks to start+10 seconds.



Can anyone else confirm this please.

MarcoBruti
12
Years of Service
User Offline
Joined: 20th Nov 2011
Location: Caput Mundi
Posted: 21st Jan 2015 21:49
I see that MTL files are not yet supported. Am I wrong, or do you plan to support it in next versions?
fancy music
14
Years of Service
User Offline
Joined: 27th Sep 2009
Location: in the alpha demo
Posted: 21st Jan 2015 23:46 Edited at: 21st Jan 2015 23:57
i just got agk2 and i was wondering if these methods would still work for publishing on android using tier 1

http://naplandgames.com/agk/agk_android_setup.html

[href] http://forum.thegamecreators.com/?m=forum_view&t=203424&b=46&p=0[/href]

there probably isnt anything wrong with the methods, maybe its just the individual errors that are confusing me.

im getting these 6 errors:

fancy music
14
Years of Service
User Offline
Joined: 27th Sep 2009
Location: in the alpha demo
Posted: 21st Jan 2015 23:54 Edited at: 22nd Jan 2015 01:15
accidental double post, sorry

edit:

wow, i just found out that agk2 can export apk files...
Naphier
13
Years of Service
User Offline
Joined: 2nd Oct 2010
Location: St Petersburg, Florida
Posted: 22nd Jan 2015 01:16
I'm sure they need some updating, but I haven't made many changes to my setup since.
1st - you need google play game services SDK which is available through Eclipse's Android SDK manager. Add that to your Eclipse workspace and it should link to your project. You might have to edit your project properties under the Android section to ensure that "google-play-services_lib" is connected as a library.
2nd - SensorLandscape probably just needs to be sensorLandscape (like the instructions say).
3rd - You need to add the facebook SDK to your Eclipse workspace and ensure it is connected to you game project as a library just like the Google Play Game Services. This is detailed in Step 4 #3 through #5 of the instructions.
Word of warning: Don't use the AGKHelper.java download from my site with AGK2 as Paul has made some significant modifications that won't work with what I have.

paulrobson
9
Years of Service
User Offline
Joined: 22nd Nov 2014
Location: Norfolk, England
Posted: 22nd Jan 2015 09:22
Yes, but you don't need to. You can just export it as an APK from the IDE now. If you have a Mac you can export it as an IPA as well. Much much easier. You only need the Android setup if you are doing Tier 2 programming e.g. C++ coding.

Have a look at http://www.appgamekit.com/documentation/guides.html in the Tier 1 section.
unlikely
12
Years of Service
User Offline
Joined: 5th Mar 2012
Location: Ohio, USA
Posted: 22nd Jan 2015 17:07 Edited at: 22nd Jan 2015 17:08
[EDIT] Realized I was not on the last page when I posted!

Using AppGameKit v2 T1 + T2!
Systems: Primary: Mac OS X 10.10
Secondary: Windows 7
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 27th Jan 2015 22:10
I don't think this has been mentioned, the Tween helper functions (e.g TweenEaseIn1, TweenBounce) aren't recognised by the compiler.

The temporary solution is to use the numeric value instead.

Quidquid latine dictum sit, altum sonatur
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 30th Jan 2015 15:34
I have an IDE bug. I have installed AppGameKit V2 into the following folder:

C:\Program Files (x86)\The Game Creators\AGK2\

The default install location is:

C:\Program Files (x86)\The Game Creators\AGK\

Whenever I close all projects and restart AppGameKit, the Preferences | Build | Path to Compiler resets itself to the default install path.
I have an older version in this location, so it causes a lot of problems if I don't catch it!

Quidquid latine dictum sit, altum sonatur
AlistairS
11
Years of Service
User Offline
Joined: 28th Apr 2013
Location: U.K.
Posted: 31st Jan 2015 14:31
We seem to missing a GetTextAlignment() function to discover the current setting put in place by a previous call to SetTextAlignment().

Login to post a reply

Server time is: 2024-05-02 04:58:21
Your offset time is: 2024-05-02 04:58:21