Game Development Community

ITGB 1.1 Feedback Thread

by Michael Perry · in iTorque 2D · 12/19/2008 (3:24 pm) · 82 replies

iTGB v1.1 Feedback Thread

Purpose:
The purpose of this thread is to gather feedback focused completely on the release of iTGB 1.1. We are open to whatever you can provide, but ask that we focus on this particular version.


Areas of Interest:
- Crashes
- Bugs
- Favorite Features
- #1 Feature Improvement
- #1 New Feature Request


Documentation:
Please use the Official Documentation Feedback Thread to post any feedback.

*** Thread will be unlocked later today ***
#41
01/06/2009 (11:19 am)
I use all the flags and set the start path to 0 and the final path to %path.getNodeCount()-1 I believe. I got it working for one path after reordering the nodes in the path and then drew my second path and had to once again reorder the nodes manually by dragging the nodes around to get it to work correctly. I tried the edit node linkages but that didn't seem to have any effect at all. I'm doing all of this in iTGB on Mac OS X for the record. When I get home I'll post the behavior code I'm using.
#42
01/06/2009 (1:18 pm)
I'd be interested in a tutorial on how to convert a game written using scripts/behaviors etc into a c++ implementation. My c++/c coding skills are much higher than my graphics/scripting skills and it might be faster/easier for me to just write my behaviors and such in native code from the get go. Also do natively written versions integrate with the TGB game editor?

BTW things I like about the product so far:
1. Particle animations are surprisingly fast and beautiful.
2. It's been surprisingly easy to do most everything I've wanted to do with behaviors, scripts etc.
3. Great communication and support in the forums so far
#43
01/06/2009 (1:32 pm)
You could take a look at the BehaviorShooter and BehaviorShooter_Components behaviors and see how they compare to get a handle on components. All the BehaviorShooter source components(.cpp files) are just the BehaviorShooter behaviors converted as closely as possible. There are still behaviors though, they just link the object to the component and then they're pretty much done, so they do still work with the editor.

personally, I'd recommend using scripts primarily because they are MUCH easier to prototype and test (especially if they interact with other objects/behaviors). Just convert to C++ components when you need to optimize them for speed or something.
#44
01/06/2009 (1:40 pm)
I'll probably stick with scripts for now until necessary. My games basically a little maze where you build guns on the walls to shoot mobs running through the maze. The primary bottlnecks are likely to be just pure # of objects running around and all of the missiles and lasers going off. Right now I'm planning on just have a global list of structures built, a global list of creatues and then looping through them and calculating the distances between each structure to object and then selecting firing targets in range and firing off missiles and/or particle effects to animate the shots.

Right now I'm using 2 layers of tile maps (background and then platforms). I'm thinking of converting that to a single 320x480 static image and setting it as background instead. I was reading somewhere that the fill rate on the iphone is not sufficient for doing any serious layering type graphics.
#45
01/07/2009 (6:31 am)
Is anyone having any consistency issues between iTGB, Simulator and iPhone device? I keep running into a scenario where everything works perfectly in iTGB, doesn't work in the simulator with 2 different kinds of problems and then doesn't work on my actual device with only 1 of the two problems I see in the simulator? I've spent dozens of hours cleaning/rebuilding/tweaking and haven't been able to consistantly get things to work reliably inside the simulator or the iphone.

I've tried installing torsion in a vmware and attatching to it remotely to debug. Problem is torsion doesn't seem to be able to "watch" any of my local script variables. It always gives me empty strings for the value for everything when I type it in. Though randomly when I continue and reenter a break point I'll see values for the variables.

Is there anyway I can zip up my project and send it in for a developer to see why things aren't working consistently between the iphone device/simulator and iTGB?
#46
01/07/2009 (7:10 am)
With all the flak firing against iTGB i just thought i might add that it is a hell of alot faster that 1.0.
I still have my issues with paying the premium to be a guinea pig, but good job guys.

:P
#47
01/07/2009 (8:43 am)
I'm going to convert all my behaviors and gamescripts to Components and see if that fixes my reliability/consistency issues. The biggest issue I'm having is that it's rare for things to work on the iphone/simulator when they work in iTGB. I would think the only issue would be performance, but from my experience the scripting is not reliable on the iphone/simulator. The worst part is there is not a reliable way to debug it. Torsion apparently is the premiere tool but from using it the last two days it either shows a seriously corrupted scripting engine or doesn't work well.

With Components at least I'd have a reliable way to debug my project using xcode and open defects against iTGB instead of spending hours and hours changing scripts and praying it randomly fixes only to have it break a day later when I add new functionality (and only break on the iphone and simulator).
#48
01/07/2009 (8:55 am)
I do not believe Torsion is working on this version of iTGB.
#49
01/07/2009 (11:14 am)
Here's the behavior I'm using to spawn and attach to a path object. The problem I'm having (now, it use to work) is that it's spawning but the things it spawns are not following the path designated.

This behavior is central to my entire project. It works perfectly in iTGB on the Mac but when I run it
on the iphone simulator or iphone device the creatures never move.

//-----------------------------------------------------------------------------
// Torque Game Builder
// Copyright (C) GarageGames.com, Inc.
//-----------------------------------------------------------------------------

if (!isObject(SpawnAreaBehavior))
{
%template = new BehaviorTemplate(SpawnAreaBehavior);

%template.friendlyName = "Spawn Area";
%template.behaviorType = "AI";
%template.description = "Spawns objects inside the area of this object";

%template.addBehaviorField(object, "The object to clone", object, "", t2dSceneObject);
%template.addBehaviorField(particle, "The particle effect to use",object,"",t2dParticleEffect);
%template.addBehaviorField(thePath,"The Path to follow on spawn",object,"",t2dPath);
%template.addBehaviorField(speed,"The speed to follow path.",int,20);
%template.addBehaviorField(count, "The number of objects to clone (-1 for infinite)", int, 50);
%template.addBehaviorField(health, "The health each object has initially.", int, 50);
%template.addBehaviorField(healthIncrease, "The percent health increase each wave causes.", float, 0.50);
%template.addBehaviorField(waveNumber, "The initial wave number.", int, 50);
%template.addBehaviorField(spawnTime, "The time between spawns (seconds)", float, 2.0);
%template.addBehaviorField(spawnVariance, "The variance in the spawn time (seconds)", float, 1.0);
}

function SpawnAreaBehavior::onAddToScene(%this, %scenegraph)
{
%this.spawnCount = 0;
%this.schedule(%this.spawnTime, "spawn");
}

function SpawnAreaBehavior::spawn(%this)
{
if (!isObject(%this.object))
return;

%clone = %this.object.cloneWithBehaviors();
%clone.health = %this.health*(%this.waveNumber*%this.healthIncrease);

%particleClone = %this.particle.cloneWithBehaviors();
%clone.visible = true;
%particleClone.visible = true;

%particleClone.mount(%clone);
%nodeCount = %this.thePath.getNodeCount();
%nodeCount = %nodeCount;
//attachObject(%object, %speed, [%direction = 1], [%startNode = 0], [%endNode = 0], [%followMode = "WRAP"], [%loops = 0], [%sendToStart = false])
%this.thePath.attachObject(%clone,%this.speed,0,0,1,"RESTART",-1,true);


%this.spawnCount++;
if (%this.spawnCount < %this.count)
{
%minTime = (%this.spawnTime - %this.spawnVariance) * 1000;
%maxTime = (%this.spawnTime + %this.spawnVariance) * 1000;
%spawnTime = getRandom(%minTime, %maxTime);
%this.schedule(%spawnTime, "spawn");
}
}
#50
01/07/2009 (12:00 pm)
I can't see any problem with the behavior altough I didn't really test it either.
Have you tried the same code without the behavior?
I am doing similar tasks except I don't use behavior and I don't use clone.
I create objects in a loop via new t2dAnimatedSprite and attach them to an existing path that I pre-generated in the editor.

I do all that work in when the level loads for each path.
#51
01/07/2009 (1:51 pm)
Yea the problem is I can't see the problem with any of my behaviors or gamescripts and they all work on the iTGB on the mac. However they fall flat on the simulator or iphone device and don't function. The worst part is I've yet to find a way to debug anything written in script code. My inclination is to dump scripting altogether so that I don't waste time one something that I can't debug. With C++ behaviors I can set a breakpoint in xcode and just do all my development debugging in there for the script logic.
#52
01/07/2009 (1:57 pm)
@Bret:

It was suggested to me a couple times for the problems that I was having to make sure physics is turned on (it's off by default for all objects on the iphone device).

Perhaps the pathing stuff is subjected to physics too since stuff is moving around. For everything in my game that moves (characters and floaty scores and anything that interacts with the character like triggers), I needed to add this code for those instances of each of those objects:

if ( %this.isMethod("setUsesPhysics") )
{
%this.setUsesPhysics( true );
}

Did you try that yet?
#53
01/07/2009 (2:07 pm)
I have physics turned on. I can still build objects on my map and they will fire projectiles that hit the objects and the objects explode. The primary problem is that the creatures will no longer join their path and start moving. I'm also having issues with the mouse location being interpreted correctly on the simulator and sometimes on the iphone. So sometimes my buildings always get built in the top left corner and some runs everything works fine.

I should also note that all of this was working perfectly, just at 7fps because I have 2 layers of tiles. So I moved over to using a background image and got rid of the tile layers. Then everything stopped working for some reason. So I went back to my previous project and it had started to experience weird issues that I'm not trying to get past.
#54
01/07/2009 (2:09 pm)
@Everyone - about stability

1) The Xcode projects supplied with the release have two very important defines in them that have to be consistent accross your entire project.

PUAP_SCRIPT_CHANGE and PUAP_OPTIMIZE/USE_COMPONENTS

Those must match for the PC/MAC build that generate the dsos and the Simulator and Device builds in XCode, if they don't match they won't work.

@Bret
If you are using PUAP_OPTIMIZE you must have your objects setUsesPhysics(true), that may be your problem.

2) As I mentioned in another thread, Xcode is not 100% consistent when copying .dso and other project files over to the application to be installed on the device and may sometimes require a clean build, this is unfortunate and but also out of our hands as it is an Xcode issue.

3)Torsion works with iTGB 1.1 with the demos we provided if it is not working for you please provide details, but it is a good tool to check on things

4) Do most of your development on your PC/MAC, the reality for debugging/development of code is that the vast majority of it can be done on your desktop/laptop. The details for getting it to work on the iPhone are dealing with the acceleromter, multi-touch and fitting in that foot print. If you keep your images to a reasonable size fitting on the iPhone should be fairly straight forward.
#55
01/07/2009 (2:31 pm)
I'll do some more debugging ASAP with your suggestions for things to look for. I'm always very diligent about removing game/common/main.cs from xcode and cleaning/rebuilding after changes. I'm seeing my changes picked up. I'm building the dso's with iTGB 1.1 and then just updating xcode like above and running on the iphone. I haven't changed any of the compile flags for iTGB 1.1 in any of the code projects. This same code etc all worked at one point but ran very slow on the device. So I went back to optimize it by reducing texture sizes and layers and then came back to find that pathing wasn't working again.

I'll do all my development etc on the MAC once I can have what I write in iTGB reliably work on the simulator and iphone, which it hasn't so far. Also I frequently do the iphone/simulator to test performance so I have a feel for how many objects I can track on screen and shoot at. If I can't get 10-20 objects moving around and 10-30 static object shooting 1-3 projectiles at them reliably then I need to either cancel the project and do something more feasible or revert back to my original project in native c++/objective c in order to accomplish it.

I'd be happy to zip up my whole game project and email it to you so you can see first hand what I'm seeing. I just need an email address I can send it to.



Edit: Just wanted to be clear that my statement towards the end wasn't intended to imply that iTGB is slow in any way. From my experience the framerates are very good considering how easy it is to do things. Tilemap layering could definitely use some love, but of course we can do that ourself by combining the tile layer artwork ourself. Once I get past the reliability issues and lack of debugging support I can see myself doing a simple but addictive game every 2-4 weeks depending on how long it takes to get artwork made from friends or purchase it :).
#56
01/07/2009 (2:44 pm)
@Paul

(first, thanks so much for all your hard work making this product work for us!) Is there any documentation anywhere of how to use the PUAP_OPTIMIZE and all the other special commands, like the ones for 16bit etc?

I would love a simple sheet listing all the special commands and functions relating to the iPhone/iTGB, what they do, and a simple example of what the code for it in use would look like. This really shouldn't take that long to create. I'm not asking for full documentation as I know that is eventually coming and Michael is working on it, but wouldn't it be possible for you, Paul, to take an hour or two and create such a sheet so we know what is available to us and how to use it? You have tested everything you've created, so I'm sure you have sample code snippets to pull from?

I know for me that would be a huge help, and would save many of us many many hours we have spent trying to figure this out, and trying to remember what forum post has what salient bit that we need!
#57
01/07/2009 (4:23 pm)
PUAP_OPTIMIZE etc are no commands

they are compiler flags and must be set in the XCode compile settings.


the 16bit thing is in torque config.h as all defines
#58
01/07/2009 (5:46 pm)
@Marc

Sorry if I wasn't clear, I know some are flags, etc. I wasn't listing everything I wanted defined, I was trying to get a list of everything like flags (as an example), the commands relating to turning physics on and off (as another example), the new ability to specify 16 bit (as yet another example), the callbacks for when the home button is pressed or a call is answered (just an example, not the full list) and EVERYTHING else that is unique to iTGB vs regular TGB, and what they do, without having to go through hundreds of forum posts looking for the ones that have been discussed.

But thanks for pointing me to config.h, I will check that out. I always appreciate help. But a full list would make it so I wouldn't have to ask for help as often. I'm sure you see the advantage to that.

Thanks again!
#59
01/07/2009 (8:26 pm)
ITGB 1.1 for windows won't run at resolutions lower than 640x480

When I Build and Go in Xcode I get a codesign error. If I just click Build and Go again, it works the 2nd time. This happens every time I make a change and rebuild.
#60
01/07/2009 (9:34 pm)
From Developer: Conor O'Kane
Another 1.1 bug - oniPhoneTouchDown() is not working any more.
--------------------------------------------------------------------------------
I've noticed the same thing today. Actually none of the oniPhone callback worked for me.