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 - Rirath

Pages: [1]
1
Support / BMFont + 2D Toolkit output issues?
« on: December 30, 2013, 12:34:56 am »
Hey guys, this may arguably be more of a BMFont issue, but I'm pretty sure I followed the instructions to the letter and I was having no luck converting a TTF to work with 2D Toolkit.  I repeatedly got the error "only one page supported in font" despite only having a single page.  So for anyone else having the same problem:

In comparing the .fnt file with some demo files, the key difference appears to be that BMFont is setting chnl=15, while 2D Toolkit appears to expect chnl=0.  Changing this in a text editor (with no other changes) cleared things right up.  Any idea if I missed a setting somewhere, or has BMFont just changed something since the docs were written?

2
Support / Re: 4.3 Physics2D.Raycast and Tilemap/Edge Collider 2D
« on: December 01, 2013, 04:13:17 am »
Quote
I figured performance was probably the reason but I haven't thought of a single way to get around building world geometry with tiles where you can jump through floors properly with edge colliders.  I'm all ears of course if anyone out there has figured this out though.

I'm speaking well above my experience level here, so apologies if I've misunderstood, but this thread has a few techniques for one-way collisions that may help you out, and a custom 2d character controller that has implemented it.  Around here he talks about one-way collisions jumping onto a platform.  Particularly this post has a few techniques, and the foot collider method mentioned a few times seems most accepted and easiest to me.

Quote
Put all of the one-way passable objects onto a single layer.
Whenever your character's y speed is <= 0, enable collisions with that layer.
Otherwise disable collisions with that layer.
(Might want to add an additional check for overlap when re-enabling the collision check)

Though I hope Unity adds things like rigidbody2d.ignoreCollision soon enough.

3
Support / Re: Is 2D Toolkit getting over complicated?
« on: December 01, 2013, 03:37:34 am »
In way of support of Unikron Software, my own $0.02 is I agree with micky.  I bought 2D Toolkit after the release of Unity 4.3 and its native 2D features.  I did this because while Unity's new box2d physics and better 2D integration into the editor interested me, 2D Toolkit's features completed the package and sold it.  Better GUI tools, tilemaps, static sprite batching, fonts, platform dependent sprites, pixel perfect camera.  All very important tools to me that Unity doesn't yet support, or not as well as I'd like.

Plus, looking through these forums before buying, it made me confident that Unikron Software will continue build 2D Toolkit as an extension of Unity's native functionality, rather than it becoming an obsolete plugin.

Quote
it's all well and good to play around with a plugin but when you have a project with millions of lines of code the last thing you need is for your builds to break because you want to upgrade to a newer version that has features you need.

My own personal view on this is you should never upgrade mid-production unless you absolutely have to, which also means you shouldn't use a tool that doesn't have the features you need when you start.   If an upgrade is deemed worthwhile, significant project time should be devoted to making the upgrade.  It's nice to hear Unikron takes API stability so seriously though.

4
Support / Re: Unity sprites in 2D Toolkit
« on: December 01, 2013, 03:20:26 am »
Just curious, do you think they'll get around to exposing the needed interfaces in future releases?  Judging by some of the dev posts over on Unity's forums, it seems there are many 2D related features they didn't get to in 4.3.0 but do plan for later revisions.  (rigidbody2d.movePosition, for example)

Is there anywhere we can go suggest to Unity we'd like this functionality?  If so, it might be good to point your users there when they ask.  There's issuetracker.unity3d.com, but I'm afraid I'm not sure exactly what to ask for.

5
Support / Re: Unity 4.3 vs 2Dtoolkit
« on: November 17, 2013, 05:51:24 pm »
Quote
Automatic collider & sprite shape detection. (This is not a scripting limitation, but we've not had enough requests for this)

I might as well lend my voice in saying that would be nifty some day. ;)

6
Support / Two Whack a Mole tutorial bugs & possible fixes (Unity 4.3)
« on: November 15, 2013, 08:06:07 am »
Hey guys, just picked up 2D Toolkit the other day - enjoying it so far.  Immediately went through the Whack a Mole tutorial and I believe I've found two bugs, and two possible fixes, in Unity 4.3.  These are in both the step by step directions, and the RestOfGame_Complete.unitypackage download.

#1 - in MainGameScript.cs

Code: [Select]
randomMole = (int)Random.Range(0, moles.Count - 1);

while(moles[randomMole].sprite.gameObject.activeSelf)
{
randomMole = (int)Random.Range(0, moles.Count - 1);
}

As is, the code appears to never select the last MoleUnit prefab in your game.  If you have 3, it will select from 2.  If you have 6, it will choose between 5. 
Changing

Code: [Select]
randomMole = (int)Random.Range(0, moles.Count - 1);
to

Code: [Select]
randomMole = (int)Random.Range(0, moles.Count);
appears to solve this issue without introducing any new ones. 
Note that (1, moles.Count) does not seem to work - it will also skip a mole and possibly introduce lockups. (see below)

#2 - Related, also in MainGameScript.cs

Code: [Select]
moleLimit = 3;
Unity will hang after running for a short period of time if the number of (selectable) MoleUnits is less than the moleLimit.  For example, 1 or 2 moles with a limit of 3.  The whole program locks up and needs to be shut down via taskmanager.  Setting the range to (0, moles.Count) and making sure the moleLimit is not greater than the number of MoleUnits you have appears to solve this.  The above range fix is important as without it, even 3 moleUnits with a moleLimit of 3 will crash due to only two being available.  I'm not entirely sure what's causing the lockup, however.

I'm a web developer by trade, very new to Unity and only a hobbyist game developer,  so while I have some idea of what's going on it's only the gist.   ;)  But I didn't see these fixes while looking around, so thought I'd post them here in the hopes someone will find this useful.

Pages: [1]