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 / Placement editor

Author
Message
The Zoq2
14
Years of Service
User Offline
Joined: 4th Nov 2009
Location: Linköping, Sweden
Posted: 24th Nov 2011 21:42
Hi, I have purchased AppGameKit and have had it since release, It's working great but I can't find the placement editor anywhere. I looked in the IDE/Utilities folder but it isn't there... I would realy like to try that thool
Digital Awakening
AGK Developer
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 24th Nov 2011 21:59
It's in my IDE/Utilities folder, do you have the latest version?

The Zoq2
14
Years of Service
User Offline
Joined: 4th Nov 2009
Location: Linköping, Sweden
Posted: 24th Nov 2011 22:21
Yes I just upgraded to 1065, Atleast I think I did, do you have to completley unistall the previous version or is the "repair" feature enough?
Digital Awakening
AGK Developer
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 24th Nov 2011 22:27
I did a complete uninstall myself, didn't try the repair.

Marl
12
Years of Service
User Offline
Joined: 19th Nov 2011
Location: Bradford, UK
Posted: 24th Nov 2011 22:49
You need to uninstall.

Repair just repairs using the old source - as I found out when it complained that the (out of date by two versions) source files had been removed.

I'm hoping they'll start update patches soon as it takes an age to uninstall / reinstall on my system.

But it is Windslows
Digital Awakening
AGK Developer
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 25th Nov 2011 00:22
At least 1065 installs much faster than the previous versions I've tried. Haven't tried uninstalling it but I bet that's faster too. The file size of the installer is much smaller now.

The Zoq2
14
Years of Service
User Offline
Joined: 4th Nov 2009
Location: Linköping, Sweden
Posted: 25th Nov 2011 10:35
Ok, I updated to 1065 and there it is, Thanks for the help guys!
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 02:09 Edited at: 1st Jan 2012 02:10
I have a question. The placement editor seems very straight forward and I thank you for creating it.

When it comes to the assets, say I have wooden planks that are in my media folder and I drag them onto the level. I want to define them as physics objects and set collision so that they will fall down or get destroyed when hit.

Also, I have a media object to knock down the planks, like a hammer, how do I set that as a collision object (or whatever I have to set it as to make it know down the planks)?

How is this done with the viewer example?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 1st Jan 2012 11:38 Edited at: 1st Jan 2012 14:13
As the code creates each object you can check the name of the image it uses and if you find the one you are looking for just edit the sprite's properties.

I'll be making a tutorial on using the placement editor in this way in the near future but I'll try to make a simple example for you when I get 10 mins to spare

EDIT:
In the placement editor code after this line-


Check the image name:


Steve Ancell
18
Years of Service
User Offline
Joined: 16th Feb 2006
Location: Brighton, East Sussex, UK
Posted: 1st Jan 2012 16:26
I've never managed to get the placment editor to work. I've tried putting image files into the media folder and it still tells me nothing is in there. That's why I'm having a go at making my own editor, but I would use the placement editor if someone can tell me where I'm going wrong.
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 16:29
First of all, is your media jpg or png files? I am using png files. Copy and paste them into the /media folder and then re-run the editor. If you see them on the left, then you can place them.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 16:30
SetSpriteFlip ( id, val ( mirror$ ), val ( flip$ ) )

In the placement editor? Is there a place for us to enter our own code or is this to change the source of the placement editor?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 16:32
So we are going with the spride ID - that is how we assign code to the sprite? So, for example, I can have the player control the hammer by pressing the space bar or touching it/swiping it on the tablet?

Can we control a swipe on touch devices?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
Steve Ancell
18
Years of Service
User Offline
Joined: 16th Feb 2006
Location: Brighton, East Sussex, UK
Posted: 1st Jan 2012 16:36
Quote: "First of all, is your media jpg or png files? I am using png files. Copy and paste them into the /media folder and then re-run the editor. If you see them on the left, then you can place them."


I'm using png files, I've tried small images and whole tilesheets, still no joy.
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 16:47 Edited at: 1st Jan 2012 16:48
Where is your main executeable (the placement editor)?

Mine is under /program files (x86)/the game creators/agk/ide/utilities/placement editor/

Are you running 32 bit or 64 bit?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 16:51
I'm a bit confused.

Where in:

SetSpriteFlip ( id, val ( mirror$ ), val ( flip$ ) )

Do we set the image$?

Or is this already done in the editor and viewer for you? I am guessing viewer reads in the text file and places these things in arrays or something.

Also, how does one create multiple levels - just rename the export text file to something else?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 1st Jan 2012 16:54 Edited at: 1st Jan 2012 16:56
Quote: "In the placement editor? Is there a place for us to enter our own code or is this to change the source of the placement editor?"

There should be some sample code for loading the levels you make with the editor but not on my PC at the moment so I can't check where. I just copied the "placement_editor.agc" file in my project folder and include the code...

Edit:
This is obviously more confusing than I thought. Maybe I'll cover this in the next AppGameKit Bitesize tutorial?

Steve Ancell
18
Years of Service
User Offline
Joined: 16th Feb 2006
Location: Brighton, East Sussex, UK
Posted: 1st Jan 2012 16:56
Quote: "Where is your main executeable (the placement editor)?

Mine is under /program files (x86)/the game creators/agk/ide/utilities/placement editor/

Are you running 32 bit or 64 bit?

Mike"


Mine is the same directory as the one you suggested. I'm running 32 bit (Windows XP).
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 17:25
Can you send me one of your graphics and i'll see if it will run on my computer.

Obviously, make sure your programs are 100% up to date.

I'll be out this afternoon, but i'll try it as soon as I get back.

My email addr is admin at mfelkerco dot com.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 17:28 Edited at: 1st Jan 2012 17:33
Here is the code for the viewer:




Is this the correct script or is it one of the other ones we need to edit?

[edit]I'm beginning to see that we need to create our functions between the do/loop in the main.agc file. The placement_editor.agc file reads in the data created by the actual placement editor application.

OK. Now that I read through all the scripts, I see EXACTLY how this works. Cool. I'll be able to take it from here.

Thanks for your help.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 1st Jan 2012 22:45
If I may make a suggestion, physics needs to be added to the placement editor.

When you load in a sprite - its object properties needs more than just position, rotation and scale - it needs its physics properties set as well (you could make it so that when you choose a new level project, you are given the choice of a static level or one with physics).

That would make it much easier to create a physics-based game than to do it after-the-fact.

What do you think? Is this possible?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 2nd Jan 2012 00:43
Personally I think it is far more practical to set those properties yourself since there are an almost unlimited number of possible settings.

I am using some placeholders for complex physics objects that would take an age to set up one by one in every level of my game, for example...

World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 2nd Jan 2012 03:25
Question: Is the source to the placement editor available (I assume it was done in AGK)? Was it done as a tier 1 or tier 2 project?

I need to create my own level editor and I would love a head start since I am so darn rusty with coding.

I did successfully create the beginnings of my game engine - got images loaded successfully. Got physics, both static and dynamic, working properly and got movement working properly.

However, I need to start creating levels and I am having a really tough time utilizing the level editor files. When I code it by hand, it works, when I try to use the viewer along with a level, nothing works right.

Perhaps someone can give me hints or code fragments as to set movement, rotation, physics and collision to specific sprites. I cannot seem to figure out how they are assigned ID #s.

Any help is appreciated.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
bjadams
AGK Backer
16
Years of Service
User Offline
Joined: 29th Mar 2008
Location:
Posted: 2nd Jan 2012 09:37
I need to make a level editor too, and be able to assign certain reserved properties to every sprite, so that my game will know how to move the bad guys sprites, etc...
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 2nd Jan 2012 17:22 Edited at: 2nd Jan 2012 17:23
I can use the existing placement editor - it's very good. However, I need someone's help in explaining how to single out sprites so I can assign code to them.

How are IDs assigned and how, in the main.agc file, do I reference them?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 2nd Jan 2012 18:29
Did my explanation not help? Sorry, I don't have time right now but I'll make a full example ASAP.

Alien Menace
AGK Developer
19
Years of Service
User Offline
Joined: 11th Jan 2005
Location: Earth (just visiting)
Posted: 2nd Jan 2012 18:42 Edited at: 2nd Jan 2012 18:43
The editor is a great start but you do need to be able to set the physics properties of the objects as well. Doing this after the fact seems to defeat the purpose of using an editor in the first place. I don't think it needs to be a comprehensive physics editor but should support the basic physics properties.

Intel i7-2600k - Asus P67 Sabertooth - 16GB RAM - 2x GTX 460 OC SLI - Lexar 128GB SSD Drive - 2TB ATA/600, Windows 7 x64. iPad, iPad2, iPhone 3GS & 4, HTC Inspire, Mac-Mini. Apps published: 3
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 2nd Jan 2012 20:59
Your code fragment:

if image$ = "Fan1.png"
`do stuff
setSpritePhysicsOn(id,2)
rem or whatever (id is the sprite ID)
endif

In the rem, you say id is the sprite id - great. How do we figure out what the sprite id is? Is it in an array? I just need to know how you get the ID so I can assign it physics properties.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 2nd Jan 2012 21:27
Ok, tomorrow I will set up a simple project as an example.

World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 2nd Jan 2012 21:41 Edited at: 2nd Jan 2012 21:46
I am having some troubles. I am trying to load a simple background image and it is not showing up.



Also, the first sprite I added using the placement editor was a small hammer. It will not show on screen no matter what I do. Everything else is perfect. What can I do?

curweapon is the variable for the hammer (physics is set on, shape of 3). curmat is the variable for the wood planks that have physics set on for them, shape of 2. Curmat2 is the ground variable that is set to static, shape of 2.

Here is the code for the project:

Main:



Placement Editor:



Setup:



Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 2nd Jan 2012 21:59 Edited at: 2nd Jan 2012 22:12
OK, I kinda solved the background issue by loading it in using the placement editor instead of after the fact. However, the hammer refuses to show and it used to.

Also, how do I pin the entire level to fit full screen. If I set the width to 640 and height to 480, then place the background full screen and set all sprites into position, when I load the viewer, everything is offset by quite a bit (x and y) and I have to use the virtual joystick to center the level (based on the full screen background).

I did lock the background in the placement editor, but can that be done in the viewer?

[edit]: sort of fixed it. I found the two lines of data that represent the offset. The question is - why is it offset? Is there a way in the placement editor to make sure you are starting at 0,0 (top left)?

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 3rd Jan 2012 11:31 Edited at: 3rd Jan 2012 11:32
Quote: "I am having some troubles. I am trying to load a simple background image and it is not showing up."

I notice you aren't setting the scale. Could that be the problem? If you are scaling it down that might also be the problem. There was a bug where the placement editor was not using floats for scale so anything smaller than original size was being effectively deleted. There is a fix in for this in the next release.

I would make sure I manually set the correct depth for my sprites too as this might be why they are not visible. Could be they are behind your background image. I just finished a simple example but the code is no better than your own really. I'll attach it here for anyone interested.

Quote: "I found the two lines of data that represent the offset. The question is - why is it offset? Is there a way in the placement editor to make sure you are starting at 0,0 (top left)?"

Not sure about this myself... I would like to see it possible to position an "origin" point for (0,0) on the screen. I'll put a request in.

EDIT: added attachment...

Attachments

Login to view attachments
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 3rd Jan 2012 21:32
Thank you for the example.

I loaded my background using the placement editor and that fixed it, but that offset is really weird. I also figured out the numbers to make that offset disappear. I have to set it every time, but at least they are consistent.

Now I am working on a file loader. I hope AppGameKit has one built in. I want to be able to choose and load level files instead of auto loading them.

I am also working on a main menu of sorts.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com

Login to post a reply

Server time is: 2024-04-19 15:30:39
Your offset time is: 2024-04-19 15:30:39