Hello Guest

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - VeTaL

Pages: 1 [2]
16
Support / Re: tk2d camera, empty screen
« on: May 11, 2012, 08:23:36 am »
PS: but anyway, i was not seeing even your template Heart sprite.

Lets try to reproduce all this stuff:
1) I open the level, erase it. It is empty now.
2) Select DemoCameraSpriteCollection, open editor, go to Settings, make sure that "Use tk2dCamera" is set.
3) Create/tk2d/Camera. Its position (0,0,-10).
4) Now Camera/Create Anchor. Leave everything as it is (UpperLeft, Offset(0,0), tk2dCamera).
5) Create/tk2d/Sprite. Sprite is parented to Anchor. Set Collection to DemoCameraSpriteCollection. Sprite is HeartEmpty.

Looking like thats it. Trying to build... Looking like it works, that's pretty good. :)

6) Change Ahcnor settings to Middle Center.
7) Create/tk2d/Animated Sprite. Select my Anim Lib.
Running...
...
...

voila, it works 0_0


My only assumption is that at yesterday night, probably, i moved camera.. but as far as i remember, i set all sprite positions to (0,0,0) and parented them to anchors. Anchors was at correct places, but, probably, i moved a camera... Though, why i started to move a camera? Probably, it was something wrong before...

Anyway, my next step is to create some more animations, so, if i'd face this problem again, or if i'd have some thoughts on it, i'll report it here.

17
Support / Re: tk2d camera, empty screen
« on: May 11, 2012, 08:10:20 am »
At first, thanks for really fast answer.

I need to animate 50 frames, each one is 50-60 Kbytes, so 2.5Mb is pretty ok. Just was wondering, if tk2d supports such size. At this point, compression and size is not that important: the most important thing is just to render amount of animated sprites.

Yep, i'm looking at Game window. Sometimes i was lucky enough to see Full Heart from your pack (i was playing with both mine and yours sprites). Also, i was able to see my animated sprite in Editor window, but never - in Game window.

Huh, situation is not that good, cause sending package to you would be really the best and fastest way to solve it. Though, i'm not sure that i can share content :(

Anyway, i'll still work on it, and report results to you in any case. Probably, i'll try to reproduce this problem using another free package with lots of animated sprites.

18
Support / tk2d camera, empty screen
« on: May 11, 2012, 12:29:02 am »
Greetings

I have a problem: while using tk2d camera, i see only background. I found http://unikronsoftware.com/2dtoolkit/forum/index.php?topic=58.0 this topic and decided to start from the clear level.

Quote
tk2dCamera mini-tutorial.

1. Create sprite collection / font, and make sure you tick "Use tk2d Camera". You will not need to set up ortho size / height as you'd normally need to. Set up as usual, and don't forget to commit.
2. In the scene, delete the Main Camera, and "Create/tk2d/Camera"
3. Create a sprite as usual - if you set up the sprite collection as in step 1, it will automatically be pixel perfect, always. Otherwise, click "1:1" to make other sprites pixel perfect. You may need to click commit on your sprite collections again for this to work properly. You will see an error in the log if this is the case.

tk2dCamera Anchor mini-tutorial.

1. Click on the camera created above, and "Create Anchor". You will have an anchor object as a child to this camera.
2. Select this anchor object, and set it up as you like - offset is the offset from the anchor. For instance if your anchor wants to be 5 pixels in from the bottom right, simply select "BottomRight" as anchor, and set offset to -5, 5 (5 pixels in horizontally, 5 pixels up).
3. Create sprites as children to this object (simply select the object, and "Create/tk2d/Sprite" will automatically parent them and these objects will now automatically be anchored.

So, i created blank level, ran through all needed collections (actually, at this moment i need only 1 collection with 45 sprites) and set there "tk2d camera", then commited. atlas0.png weights 2.5 Mb, is that okay?

Then i added camera, added anchor, parented animated sprite to anchor... and see just blank screen.

PS: also, not object is not visible by editor camera (before, it was visible).

Pages: 1 [2]