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 / Setting up screens

Author
Message
Baldielocks
2
Years of Service
User Offline
Joined: 28th Mar 2017
Location: Grimsby, England
Posted: 9th Nov 2018 12:15
Hi guys, is there anyway I can set up a screen easily . In unity and clickteam fusion you can drag the sprites to where you want them on the set up screen is there any way to do this using APK or do I have to do it the old fashioned way using pen and graph paper and plotting them using code to the right place. Also I know unity is Object orientated so if making a breakout sort of game the bricks are all tested the same. In APK do I have to check each brick individually using a for next loop ? I don`t know unity but my son is making a game using it, explaining it to me and I want to try and do the same in APK. ( as its more like the coding I used to do 40 years ago.) I know collisions are detected in a similar way (GetSpriteCollision) Also if there are say 50 blocks is there a way of knowing when all instances are gone or do I have to count them in a variable ? I don`t know if there is a command for this and I`ve missed when reading the guide.
Thanks in advance, Cheers
Baldielocks
2
Years of Service
User Offline
Joined: 28th Mar 2017
Location: Grimsby, England
Posted: 9th Nov 2018 12:20
Sorry to sound really stupid but how do I access the sprites in the Asset pack.
GarBenjamin
AGK Developer
2
Years of Service
User Offline
Joined: 30th Nov 2016
Location: USA
Posted: 9th Nov 2018 15:16
You can use a tile map to design your levels. Tiled is what I use. Works well. You just need to load that data into an array. You can also just design your levels in code... visually an easy way is to just use lines of strings then parse and convert to integer image references. There is also the GUI-based Placement Editor which although I have never used it should also work for this. Of course, you can also build a very simplistic level editor. Doesn't need bells n whistles just something to let you visually select tiles, place them and save & load that data. Basically there are many options. You choose which is right for you. I think building a simple 2D map / level editor would help you a lot to not only create a tool you can change whenever you need to but also to learn AppGameKit programming.

It's not objects that let Unity do this for you it is the entire framework and model of using component based design. Their internal code calls update on every gameobject. AppGameKit doesn't use that component-based model. Again you can do it however you want here. If you want to do it in a more object oriented way just make a file block.agc that has only the variables and code to manage a single block. Use a TBlock type to define the data properties for a block. Create another file BlockManager.agc or LevelManager.agc whatever and declare an array of the TBlock types. This Block Manager is your main interface in to working with the blocks and will call the functions for an individual block that you write in the Block.agc file. Personally I see that as just an unnecessary level of abstraction and would have the BlocksManager do all of the work right there.

For collisions again you can write a BlockCheckCollision function passing in the spriteid of the ball and then just loop through the array of TBlocks and use GetSpriteCollision api function. More commonly you can just check the map data (from your tile map level editor data) for a collision. Again you can do it however you want to. You have a ton of freedom with AGK.
fubarpk
Moderator
14
Years of Service
User Offline
Joined: 11th Jan 2005
Location: Adelaide
Posted: 9th Nov 2018 21:42 Edited at: 9th Nov 2018 21:45
It hasn't got all the bells and whistles that the agk platform editor has but here is the source to my 2D Platform editor
https://forum.thegamecreators.com/thread/219932

Age3D is a free scene creator for 3D worlds
https://forum.thegamecreators.com/thread/221796

In the AppGameKit Developer the installed packs are under the menu option DLC just click the one you want to find what you are after
these need to be copied to your "projectdirectoriy/media" folders
fubar
Baldielocks
2
Years of Service
User Offline
Joined: 28th Mar 2017
Location: Grimsby, England
Posted: 10th Nov 2018 19:53
thanks for that guys, What do any of you think of the Visual Editor that APK do ?
PartTimeCoder
AGK Tool Maker
4
Years of Service
User Offline
Joined: 9th Mar 2015
Location: Suffolk UK
Posted: 12th Nov 2018 20:29
It would be OK if TGC ever released a bugfix but as it stands its pretty buggy, there was some talk from TGC a while ago saying development had been delayed and it would be revisited soon but I don't feel confident we will see an update in 2018, but yet I do hope to be proved wrong!

Login to post a reply

Server time is: 2019-08-19 08:27:38
Your offset time is: 2019-08-19 08:27:38