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.


Topics - VGT

Pages: [1]
1
Support / Changing wrap mode while playing
« on: July 09, 2012, 06:20:31 pm »
I have an animation loop that when I decide for it to stop, I'd like it to finish before going onto the next sequence.  I currently call on GetComponent<tk2dAnimatedSprite>().animation.wrapMode = WrapMode.Once.

This doesn't seem to have an effect.  Is it possible to make this work through some other means?

2
Support / Atlas creation and memory problems
« on: June 19, 2012, 08:26:52 pm »
I currently am running 64-bit windows Unity 3.5.1 with 2D Toolkit version 1.7 + patch 2.

We recently started adding animation sequences of different sizes and lengths.  (most were large animations being 1024x1024 and 70 + frames).

As expected Unity ran out of memory quite frequently resulting in crashes as we tried estimating the right collection sizes.  I have also noticed 2D toolkit gets buggy after crashing.  Frequently I have to delete the entire sprite collection prefab because it won't even show up in the Inspector.  Other times I will click on 'Open Editor...' and it will open a white window where the only way to fix this is to re-open unity and hope it doesn't occur again. 

Sometimes when creating an atlas, Unity will freeze but not appear as 'Not Responding' in task manager.  The Sprite collection window won't be frozen and I can click different frames. 

Other times I will get the error that 2D toolkit cannot cast to source destination.  This means that I have too many frames and there isn't enough memory for what I'm trying to create.  I will see that there is a corrupted image file in the data folder.  I'll delete the data folder and if I try to create the collection again Unity will immediately crash due to running out of memory.

Sometimes it will appear that the collection successfully created all the files but when I assemble the animation the collection will now show up. (deleting the .asset file and 'rebuild index' doesn't fix this)

Sometimes unity will crash saying it ran out of memory while selecting multiple or single images (around 1024x1024) while having the sprite collection editor open.

When successfully creating an atlas, data prefab, and material, I will go onto the next collection and unity will immediately crash almost as if the memory used to create the previous collection wasn't freed.

I have also noticed that the version of 2D toolkit's sprite collections aren't as efficient as previous versions.  I can try to re-create a collection using the same exact image sequence, same amount of frames, and same settings and unity will just endlessly crash due to being out of memory.

Changing the Max size to 2048 instead of 4096 does help a lot when fitting more frames into a single collection but there are certain days that even this won't help.  I'll have a 1024x1024 image (which needs to be trimmed) crash unity if I try to make a collection over 10 frames.  When I have an animation that is over 100 frames at this size it can get quite tedious.

The animations look great once I can put them together and see them playing in game but the collection editor has been frustrating to work with lately.  Is there any possible fixes to these or improvements coming in new versions?

3
Support / ReflectionTypeLoadException
« on: May 22, 2012, 11:31:44 pm »
When building animations, I have come across this error:

ReflectionTypeLoadException: The classes in the module cannot be loaded.
System.Reflection.Assembly.GetTypes ()
tk2dSpriteCollectionBuilder.RefreshExistingAssets (.tk2dSpriteCollectionData spriteCollectionData) (at Assets/TK2DROOT/tk2d/Editor/Sprites/tk2dSpriteCollectionBuilder.cs:1124)
tk2dSpriteCollectionBuilder.Rebuild (.tk2dSpriteCollection gen) (at Assets/TK2DROOT/tk2d/Editor/Sprites/tk2dSpriteCollectionBuilder.cs:1101)
tk2dSpriteCollectionEditorPopup.DrawToolbar () (at Assets/TK2DROOT/tk2d/Editor/Sprites/SpriteCollectionEditor/tk2dSpriteCollectionEditorPopup.cs:410)
tk2dSpriteCollectionEditorPopup.OnGUI () (at Assets/TK2DROOT/tk2d/Editor/Sprites/SpriteCollectionEditor/tk2dSpriteCollectionEditorPopup.cs:670)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture)

I found the only thing this does is that it doesn't attach the material(s) of the atlas to the data prefab.

I tried re-importing the 2DToolkit files (excluding the demo folder) and this didn't seem to fix it.  I have a feeling something might be wrong in my project settings but I'm not sure what.

4
Support / 2DToolkit Animations Update issue
« on: May 16, 2012, 07:48:58 pm »
I am running Unity version 3.5.1 and I updated 2D Toolkit from version 1.6 to 1.7 Patch 2.

Upon updating, I reimported all my assets and rebuilt the Index.  If I click on any of my animation prefabs I get an error saying 'Object reference not set to an instance of an object'  I cannot create anymore new animations because all of my sprite collections are invalid.  Before I removed my sprite collection prefabs along with the image sequences to save about 3 gigs of memory from our files.

I also noticed that all of my objects are now missing their script references.  I imagine reimporting everything broke my animations because of the lack of sprite collections, but I read that I need to remove those if I want to remove my image sequences.  These dependancies might cause me to be more cautous with updating 2D Toolkit in the future unless I took the wrong steps to updating.

5
Support / 2D Toolkit Animations on Macs
« on: May 11, 2012, 12:39:12 am »
I have been making sprite collections on my workstation for a while now.  It is windows 7 64-bit with 8 gigs of ram.

Recently we included our artists in the use of 2D toolkit.  They use MacOS 10.6.8 64-bit with 12 gigs of ram.

I have found out that when creating large animations that require multiple atlases at the size of 4096, my windows machine can make two or even three but the macs that the artists are using can't go beyond one.   Unity crashes way more often on their machines due to running out of memory.

We are sure to compress our atlases and check the box multiple atlases.  We also disable sprite thumbnails.

We are all currently using 1.61 but are considering upgrading to the latest version.  (we wait on this because it must be company wide and therefore approved)

Is there an improvement to the Mac performance of 2D toolkit in the new version?  If not, is this an issue that Unikron is aware of or are there settings that are different on Macs that can be used to improve this?

Thank you for the assistance.

6
Support / Sprite Animation Number of frames
« on: April 18, 2012, 12:37:56 am »
Some of the animations I'm creating require me to make multiple sprite collections currently.  (The amount of images and their sizes causes unity to crash while creating the atlases.  Eventually these images will be smaller and it may eliminate this problem)

For the time being I'm using four sprite collections for a single animation. 

Here is what I do to assemble this animation in a Sprite Animation prefab:

1. Select the first collection and press AutoFill.  This fills the animation with the 54 frames that are in the first collection.

2. Click the drop down for Num Frames and increase the number by one.

3. Change the collection for the 55th frame to the next collection and make sure it's on the first image of that sequence.

4. Click AutoFill.

5. If not done, go back to step 2.

The problem that I'm having is that at step 2, if the number of frames is over 99, I cannot add a frame because the dropdown menu doesn't extend that far.  Is there a way to manually enter this value or to go over 99 frames?



My current fix to this problem is I select the last frame and change the collection to the next one (cutting out the last frame of the previous collection).  I then click autofill and I swap that frame that I changed to what it was originally and proceed to change the frame of each one after that to be in proper order. (See Attachment for visual explanation)



I'm hoping that eventually we can fit our animations into one collection without crashing unity during the 'commit'.  If we cannot, there will always be that tedious work of creating the animation.  Could there be a way around this?

Pages: [1]