a few woes
by rennie moffat · in iTorque 2D · 06/17/2010 (9:30 am) · 181 replies
Hi there, anyone who has been following me this week understands my situation. I built, stupidly, my app in TGB, not iTGB, anyhow, essentially I have simply been transferring all I did into iTGB however I have run into two problems.
1. when I run my game it crashes.
2. my player animation (idling) is of the same size (object is 32x32) however in TGB the actual sprite, at least what was visible was only a quarter of that size. It sat, very quietly in the middle, in other words it did not take up the whole 32x32 space. In iTGB however the object is still 32x32 but the animation is bloated. It is stretched out to fill the entire space. I am not sure why, any suggestions?
edit; cont from pt2.
I have just noticed, as I say, my level, opened up, everything appears to be fine. all objects, positions, sizes are correct. However, when I drag in those same elements into the editor fresh, they are a good 20% larger. I think this may have something to do with resolution, but in the level.t2d's I see no "resolution" or something like that to adjust.
3. Images are not being called.
I have redone every image i needed, created animations, etc. Saved then reloaded my game. All images are gone. They still exist in the folder "game/data/images" but are not called into the editor.
3 cont.
I just created a whole new project and loaded in one image, thinking one of my files may have corrupted the project, but the same thing happened. The message i get is...
How can this be? I created the image, simply calling into the editor, pulled it onto the level editor, saved, then reloaded the game just to test.
If anyone can help me out with these pressing issues I would greatly appreciate it.
Thanks.
1. when I run my game it crashes.
2. my player animation (idling) is of the same size (object is 32x32) however in TGB the actual sprite, at least what was visible was only a quarter of that size. It sat, very quietly in the middle, in other words it did not take up the whole 32x32 space. In iTGB however the object is still 32x32 but the animation is bloated. It is stretched out to fill the entire space. I am not sure why, any suggestions?
edit; cont from pt2.
I have just noticed, as I say, my level, opened up, everything appears to be fine. all objects, positions, sizes are correct. However, when I drag in those same elements into the editor fresh, they are a good 20% larger. I think this may have something to do with resolution, but in the level.t2d's I see no "resolution" or something like that to adjust.
3. Images are not being called.
I have redone every image i needed, created animations, etc. Saved then reloaded my game. All images are gone. They still exist in the folder "game/data/images" but are not called into the editor.
3 cont.
I just created a whole new project and loaded in one image, thinking one of my files may have corrupted the project, but the same thing happened. The message i get is...
Quote:
Invalid Project Data
This project contains 1 invalid datablock. This is likely because a referenced image file was deleted from the project directory.
How can this be? I created the image, simply calling into the editor, pulled it onto the level editor, saved, then reloaded the game just to test.
If anyone can help me out with these pressing issues I would greatly appreciate it.
Thanks.
About the author
My thanks to Garage Games and the Garage Games Community combined with owned determination I got one game up, Temple Racer and I am looking to build more interesting, fun games for the mass market of the iOS app store.
#122
WRT the format of the file, you don't need the <> brackets - that was just to show when the name of your level goes.
06/30/2010 (9:13 am)
Rennie, I rarely use the editor so most of the time my datablocks don't play well with the editor - I find it quicker just to hand edit.WRT the format of the file, you don't need the <> brackets - that was just to show when the name of your level goes.
#124
06/30/2010 (11:04 am)
that you open a text editor and work with the cs files
#125
06/30/2010 (11:17 am)
So if I wanted a new image, at position, with behavior X, etc etc? just set it in the datablocks?
#126
06/30/2010 (12:14 pm)
all you do in the editor is configuring and setting datablocks :)
#127
::?
06/30/2010 (12:56 pm)
when you say editor, you mean the iTGB interface? and by configure I am not sure what you mean? Setting datablocks I would think would be done in the text editor, unless you mean the new beta datablock manager.::?
#128
configure = gives you options that are filled in the datablocks.
and this has nothing to do with the per level datablock editor.
the whole tgb as you see it visually does nothing but create datablocks!
06/30/2010 (4:50 pm)
editor = TGB / iTGB editor right.configure = gives you options that are filled in the datablocks.
and this has nothing to do with the per level datablock editor.
the whole tgb as you see it visually does nothing but create datablocks!
#129
::::
06/30/2010 (5:05 pm)
right I agree, I just always think it is "weird" when anyone says, and I have heard it before, that they do not use the editor. But whatever works I guess.::::
#130
especially when you worked with TGB 1.1.3 and older where no behaviors existed, where you worked around datablock classes, its clear why you are faster there. but also working with all regular 3d torques makes you know them inside out kind of as you are there a lot ...
06/30/2010 (5:08 pm)
well if you worked with torque lon enough you are used to it. also as pointed out: it can save a lot of time as you can do copy paste etc and with torsion etc its not that much of work anymore at all you are pretty performant.especially when you worked with TGB 1.1.3 and older where no behaviors existed, where you worked around datablock classes, its clear why you are faster there. but also working with all regular 3d torques makes you know them inside out kind of as you are there a lot ...
#131
06/30/2010 (5:23 pm)
coool.
#132
\MyProjects\MyGame\buildFiles\XCode_iPhone\build\Release-iphoneos\
I think that is correct anyway, but hopefully the other guys will correct me if I'm wrong, as I haven't gone through the process yet of submitting an app to the Apple store.
I think the final version that is seen in the apps store will end up being slightly larger compared to the file that you submit to them (like 1 or 2 MB larger), because they add some extra files for their own security etc.
06/30/2010 (8:35 pm)
Rennie, the 20 MB limit refers to the find application after it's been compiled. I believe that is the iTorque2DGame.app file that resides in the following folder:\MyProjects\MyGame\buildFiles\XCode_iPhone\build\Release-iphoneos\
I think that is correct anyway, but hopefully the other guys will correct me if I'm wrong, as I haven't gone through the process yet of submitting an app to the Apple store.
I think the final version that is seen in the apps store will end up being slightly larger compared to the file that you submit to them (like 1 or 2 MB larger), because they add some extra files for their own security etc.
#133
However when I get to
\MyProjects\MyGame\buildFiles\XCode_iPhone\build\....
I have no "Release-iphoneos",
only "Debug-iPhoneSimulator" & iTorque2D.build.
::::Just curious as I would ultimately like to judge my file size off of this.
06/30/2010 (9:02 pm)
Thanks Marc, However when I get to
\MyProjects\MyGame\buildFiles\XCode_iPhone\build\....
I have no "Release-iphoneos",
only "Debug-iPhoneSimulator" & iTorque2D.build.
::::Just curious as I would ultimately like to judge my file size off of this.
#134
\MyProjects\MyGame\buildFiles\XCode_iPhone\build\Debug-iPhoneos
if you look in that directory you should see the .app file, which is the one that gets downloaded to the phone (or the simulator). The size of that file should help determine the size of the final product (just add 1 or 2 MB to be safe).
07/01/2010 (12:05 am)
Yes, that is because you compiled your code in debug mode, and you built for the iphone simulator. I am also building in debug mode, so in my case my app is in:\MyProjects\MyGame\buildFiles\XCode_iPhone\build\Debug-iPhoneos
if you look in that directory you should see the .app file, which is the one that gets downloaded to the phone (or the simulator). The size of that file should help determine the size of the final product (just add 1 or 2 MB to be safe).
#135
Also, I have "iTorque2DGame.app.dSYM" in my debug folder. Is this it?
07/01/2010 (2:29 am)
I am sure there is docs on it, but I will ask, what is debug mode? Do I need to not be in debug mode to officially release my product?Also, I have "iTorque2DGame.app.dSYM" in my debug folder. Is this it?
#136
Normally, you'd always use debug mode for developing and debugging your program, and then when you are ready to submit the application to Apple you'd rebuild the program in Release mode.
07/01/2010 (4:55 pm)
Debug mode is usually the default when you are developing the code. The compiled code will be slightly larger (compared to Release mode), as it includes a lot more things that is used by the debugger. I think the .dSYM file is a list of the symbols used in the code, and this is something that is used by the debugger, so that it knows the variable names etc. The final application is the iTorque2DGame.app file.Normally, you'd always use debug mode for developing and debugging your program, and then when you are ready to submit the application to Apple you'd rebuild the program in Release mode.
#137
Hmm, ok, I figure I need to read more but if anyone has thoughts etc, I would love to read them.
Cheers.
07/02/2010 (9:25 am)
Hmm, how would you switch? Also after a brief flip thru the docs, upon being ready to release I am to remove all pngs, if there is an equivalent pvr, also remove all cs files if there is an equivalent .dso? Hmm, ok, I figure I need to read more but if anyone has thoughts etc, I would love to read them.
Cheers.
#138
The other steps that you mention would be done to make the final application as small as possible, to make sure that you are able to keep your app size smaller than the limit specified by Apple. The docs also talk about some optimisation flags, that can be used if necessary.
07/02/2010 (4:00 pm)
It's very easy to switch from debug mode. If you open up your project in XCode, it's the first pulldown menu on the left. That's the same menu that you use to choose the target platform also, so that is where you select between the simulator and the iPhone device, and also for choosing what operating system you want to use. Actually, I've just noticed there are Debug, Release, and also a Shipping mode. The other steps that you mention would be done to make the final application as small as possible, to make sure that you are able to keep your app size smaller than the limit specified by Apple. The docs also talk about some optimisation flags, that can be used if necessary.
#139
Regarding the second point, specifically .cs & .dos files. am I to literally rid any folder with script and cs files ( i think all cs will have dso's) but if that is the case, then rid all cs files? including all behaviors as they have dos's, or am I missing something?
07/03/2010 (5:44 pm)
Ok, so if I want to load it on to my iPod to test, can I select one of these? And also, when the time comes, I am guessing set it to Release?Regarding the second point, specifically .cs & .dos files. am I to literally rid any folder with script and cs files ( i think all cs will have dso's) but if that is the case, then rid all cs files? including all behaviors as they have dos's, or am I missing something?
#140
07/03/2010 (6:06 pm)
Rennie, don't delete your cs files - you will need these to generate the .dso files. Personally, I leave the .cs files, remove all .dso files and let them get re-generated on the device.
Torque Owner rennie moffat
Renman3000
So it would be that file though that should be under 20MB? "~/MyProjects/MyGame"
@Dean
We may be talking. Thanks again.
@Scott
1. ok.
2. You dont use the editor for naming and classing? Do you just do it via the datablock? How does the editor and engine know what object is what? via the imagemap name?
3. ok.
4. The format includes <> brackets around the level name? And the same file must also be in the managed/datablocks folder?