Search Unity

Energy Bar Toolkit - 2D and 3D Progress Bars

Discussion in 'Assets and Asset Store' started by genail, Mar 30, 2013.

  1. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032

    Nearly each and every game is using health or progress indicator of some sort. Think about it. Experience, health, mana, charging, draining, loading, unloading things, speed, pressure, progress, and many many more. All of these may be easily visualized using Energy Bar Toolkit.

    Energy Bar Toolkit is a tool to create elegant progress bars in just a few minutes without any additional scripting. Just drag and drop graphics into inspector and that's all! Simplicity have really high priority here. You can script the bars to make more interesting effect using the simplest possible API! And now if you own PlayMaker, Energy Bar Toolkit supports it!

    Please check out our demos (links below) to see what Energy Bar Toolkit can do for you!

    Main Features
    • Unity5 and uGUI support!
    • DF-GUI support!
    • NGUI support!
    • PlayMaker Support!
    • Atlases
    • Simple to use - strong inspector integration, no need to write any additional scripts
    • Event system to connect basic game events with bars without scripting
    • Results visible in Edit Mode (no need to go to the Play Mode)
    • Automatic size calculation - just throw in the texture
    • Highly configurable - think what you want and make it happen
    • Full inspector integration
    • Bars can be attached to 3D objects
    • Customizable bar labels
    • Built-in effects - animate, burn, cut, fade, shrink
    • It comes with example prefabs and 3 progress bar packs for free
    • Multiple screen resolutions support
    • Works with all Unity editions (Free, Pro, Personal)
    • Source code included!
    Upcoming features:
    • More advanced renderers
    • More effects

    Integrated With


    Screens


    WebGL demo (click to run)


    Examples (click to run)




    Theme Packs


    Follow Us!
     
    Last edited: Apr 1, 2015
  2. GCat

    GCat

    Joined:
    Jul 31, 2012
    Posts:
    172
    looks interesting, i'll buy to try it out
     
  3. GCat

    GCat

    Joined:
    Jul 31, 2012
    Posts:
    172
    have to update unity, maybe in the future you could sell for lower versions as well
     
  4. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Thank you GCat! Are you using version 3.5.7?
     
  5. GCat

    GCat

    Joined:
    Jul 31, 2012
    Posts:
    172
    4, but I already updated and bought it, works good
     
  6. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Thank you, I hope you like it! Please let me know of any issues or features that you would like to see in next releases :)
     
  7. GCat

    GCat

    Joined:
    Jul 31, 2012
    Posts:
    172
    btw, I recommend you to use for next version NGUI, the unity GUI will drop performances with multiple bars
     
  8. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    I was looking at NGUI just few hours ago and I think I am now convinced :) But I must wait with that investment for about week or so.
     
  9. Alf203

    Alf203

    Joined:
    Dec 7, 2012
    Posts:
    461
  10. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    I will, thanks!
     
  11. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Just updated to version 1.2.

    New Things:
    - Added two progress bar packs
    - Flicker warning when setting bar size manually
    - New effect: Repeated Renderer "cut" effect

    Bugfixes:
    - Repeated bars flickering
    - Exception "texture not readable" was exposed to end user
    - Repeated texture recommends texture filter mode set to "point"
    - Wrong automatic size calculation of bar texture
     
  12. TheRealFuzz

    TheRealFuzz

    Joined:
    Jul 17, 2012
    Posts:
    309
    These look really helpful! I think I might have to buy soon :)
     
  13. TheRealFuzz

    TheRealFuzz

    Joined:
    Jul 17, 2012
    Posts:
    309
    So I bought this last night and placed my bars and it's working pretty good but when I tested the same game on a different computer with a higher resolution screen, the bars were in the middle of the screen instead of the bottom left where they were positioned to be.

    Is there a way to fix this?
     
  14. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Hello! Thank you for your purchase :) I hope you like it!

    All bars are absolutely positioned using pixel coordinates from top-left corner. I don't know yet if the choice was right but I see now that when you would like to keep your bar close to bottom or right edge of the screen it would be tricky.

    First of all you must decide if you'd like to scale the bar textures with screen resolution or not. I do not recommend scaling because it may cause flickering effect that is hard to avoid with gui elements. Without scaling solution is simple. Depending of which bar renderer you're using attach to your bar script that look like this:

    For EnergyBarRenderer:
    Code (csharp):
    1. void Start() {
    2.     int margin = 20;
    3.     var renderer = GetComponent<EnergyBarRenderer>();
    4.     renderer.screenPosition.y = Screen.height - renderer.size.y - margin;
    5. }
    for EnergyBarRepeatRenderer:
    Code (csharp):
    1. void Start() {
    2.     int margin = 20;
    3.     var renderer = GetComponent<EnergyBarRepeatRenderer>();
    4.     renderer.startPosition.y = Screen.height - renderer.iconSize.y - margin;
    5. }
    for EnergyBarSequenceRenrerer:
    Code (csharp):
    1. void Start() {
    2.     int margin = 20;
    3.     var renderer = GetComponent<EnergyBarSequenceRenderer>();
    4.     renderer.position.y = Screen.height - renderer.size.y - margin;
    5. }
    Thank you for your feedback! I see room for improvement here. I think I will make this simpler in next release: without need of scripting.
     
    Last edited: Apr 7, 2013
  15. TheRealFuzz

    TheRealFuzz

    Joined:
    Jul 17, 2012
    Posts:
    309
    Thank you for your quick reply! I'll look into it :)
     
  16. Addi

    Addi

    Joined:
    Jan 6, 2013
    Posts:
    3
    This saved me a chunk of time, easy to plug into my game and works great. The progress bars are a nice addition too :D

    One request:
    I have the same problem as RealFuzz with elements being off screen when I change resolution, obviously that's not a bug as it's how you've implemented it to work but if you could add an option for placement using the screen rectangle (which I guess updates as resolution changes happen) that would be useful :D

    (I think I'm talking about Normalized values instead of pixels, still learning!)
     
    Last edited: Apr 10, 2013
  17. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Hello Addi,
    I'm happy to hear that!

    Just yesterday I've commited new version of Energy Bar Toolkit for the review. It should be available in Asset Store in just a few days. With newest update you'll get feature called pivots. By setting pivot point for your bar you can set it's position to be relative to screen edges, corner or screen center. In the result bar located let's say 10 pixels from right edge will remain so. You can read more about it here. Please follow this thread and you'll be notified when new version will be available.

    I like the idea about normalized coordinates. I'll write it down in my TODO notebook. Thank you for your suggestion! :)
     
  18. Addi

    Addi

    Joined:
    Jan 6, 2013
    Posts:
    3
    super, cant wait to check it out thanks! :D
     
  19. RandAlThor

    RandAlThor

    Joined:
    Dec 2, 2007
    Posts:
    1,257
    Just bought it and hope for an ngui update in the near future.
    Great asset :)
     
  20. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Thank you! I'm happy that you like it :)
    I'm looking into NGUI right now, so stay tuned!
     
  21. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    I'm proud to announce that Energy Bar Toolkit 1.2.2 version is out! The most noticeable addition are pivot points to make positioning easier.
    Full release notes can be found here.

    For those who are waiting for NGUI support I communicate that work is in progress. NGUI is really interesting and powerful GUI library. Creating energy bars may be little more difficult but just now I can say that NGUI version of bars will have more features and effects that traditional one. Of course update will be free :)
     
  22. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Hey! Here's probably last update before one with NGUI integration. The 1.3 is here!

    Features:
    • Bar color can change with progress
    • New effect: blink
    • Repeat Renderer can draw slots
    • Normalized coordinates support
    Full release notes can be found here.

    Also I encourage to follow me on Twitter MadPixelMachine where I will post updates about releases and upcoming features :) Of course this thread will be kept up to date too.
     
  23. TheRealFuzz

    TheRealFuzz

    Joined:
    Jul 17, 2012
    Posts:
    309
    Thanks for the updates :)
     
  24. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Thank you for your feedback :)
     
  25. Les-Bird

    Les-Bird

    Joined:
    Apr 22, 2013
    Posts:
    6
    Hi, not sure if it's just me or not but the updated version seems to be crashing on my iPad 3. I was using the previous version in another project and everything was fine but I started a new project then updated to the latest Energy Bar Toolkit version and it crashes on the device, although it works in the editor. Sorry I can't supply more information - the stack trace in Xcode doesn't say much.

    The crash is on startup while the Unity splash screen is up and I'm using Unity V4.1.2f1. If I remove the Energy Bar from my project then the app launches fine, so I narrowed it down to that. I was using the Bar2 prefab.

    If it's working for others than maybe it's something else I'm doing but just wanted to give Mad Pixel Machine a heads up so that maybe they can start looking into it.

    - Les
     
  26. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Hello Les Bird,

    This sounds like Unity bug. I have suspicion what may cause the crash but it's not rocket science here so I am very surprised :) For now I'm supplying older version of EBT to you by PM.
     
  27. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Just submitted 1.4 with NGUI integration to Asset Store and waiting for review :)
    Check out the demo here!

    I succeed with rewriting most of features from filled (default) and repeated renderers. Sequence renderer will be introduced in later update.
    There are some things that NGUI renderers can make but traditional cannot, like custom positioning in repeated or circle fill but all these things will be available on both shortly!
     
  28. Les-Bird

    Les-Bird

    Joined:
    Apr 22, 2013
    Posts:
    6
    Ok, I tracked this issue down to the stripping level setting for iOS builds. When I build for device I usually build the most optimized version so I can gauge the performance. My settings for stripping level were "Strip Assemblies" and for call optimization it was "Fast but no exceptions". These settings would cause the game to crash when I added an energy bar to my scene. I found that changing the stripping level to the default setting of "Disabled" will work just fine with the energy bar in the scene and there's no noticeable performance penalty, although the application bundle size is several MB larger.

    - Les
     
  29. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    This is great help, thank you very much! I will look deeper into it and eventually if I cannot fix this in my code I will notify Unity Technologies about this bug and make workaround for iOS devices. I will keep you posted.
     
  30. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    And here it is. 1.4 with NGUI integration is available for update from Asset Store! Please read the README.txt file first!
     
  31. GCat

    GCat

    Joined:
    Jul 31, 2012
    Posts:
    172
    Thanks genail for updating to NGUI, you stick to your word and I will be using your asset allot.
     
  32. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    I'm happy to hear that :) Next updates will bring sequence bar to NGUI, circle bar to Unity GUI, more bar packs, and some new features that I have in mind. Please let me know if there is anything that you'd like to see in future releases.
     
  33. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Energy Bar Toolkit 1.4.1 is out! With this release you have ability to create circle energy bars in classic Unity GUI. This feature was available only for NGUI until now ;-)

     
  34. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    For those who don't have latest version yet: After my last description update Energy Bar Toolkit is not reachable from asset store and it's not my doing. I can see it on my publisher administration panel with dead links to asset store so I believe this is store software issue. Anyway I sent an email to support staff and I am now waiting.
     
  35. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Asset is back online! I don't know what happened yet...
     
  36. GCat

    GCat

    Joined:
    Jul 31, 2012
    Posts:
    172
    its down again, whats up with the asset store
     
  37. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Unity support told me that they've made some changes in asset store lately and bugs have arisen. ETB is back online now but I cannot promise that when I'll prepare next update it won't happen again.

    I won't notify you about downtime anymore because I don't want to bump this thread that leads to offline asset. I want you just to know that if you cannot download latest ETB you can:
    - contact me via support@madpixelmachine.com . If you send me your invoice number I will send you the latest version of ETB
    - wait a little for asset to be online again
     
  38. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Hey,

    I am making a list of features that will be implemented in future releases of EBT. The most valuable features are of course these that are feature request from EBT users.

    My list looks currently like this:
    • Bars attached to 3D objects
    • Better NGUI integration
    • Multi-layered filled bar
    • More graphical effects for bars
    Please think about it for a second :) What do you want to see in future releases?
     
  39. Imawizrd

    Imawizrd

    Joined:
    Jan 19, 2013
    Posts:
    20
    Would this work with 2D Toolkit?
     
  40. Frozmat-Games

    Frozmat-Games

    Joined:
    Dec 17, 2012
    Posts:
    25
    Hello.
    First of all thanks for the excellent asset!
    As a designer I see almost endless potential in its usage, but…. Again as the designer I don't exactly understand how to work with it. Could you please make a simple (with boxes!))) example with health indicator of the character who receives damages and then somehow restores it? And if it is possible, please make an example accessing to your asset through a javascript?
     
  41. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    I will look into it by tomorrow and let you know :)

    As you mention it I realized that I don't have clear documentation about energy bar positioning. Good to hear what it look like from your perspective. By boxes do you mean defining rectangle? No problem with the example. Do you want progress bar to follow your character?
     
  42. Frozmat-Games

    Frozmat-Games

    Joined:
    Dec 17, 2012
    Posts:
    25
    Sorry for my english.) No, I meant simple Unity cubes. Something like this...

    P.S. I think it will be "OnTriggerEnter" for the most of cases. And "OnTriggerStay" for the "fire damage" for example.) $Energy Bar Toolkit.jpg
     
    Last edited: May 18, 2013
  43. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    Allright! Your english is ok, my reasoning is sometimes illogical :)
     
  44. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    @Ed Sheldon
    I am looking at 2D Toolkit right now and I believe that EBT should work with it just fine :). By "work with it" I think of not colliding with each other. 2D Toolkit is using game objects to draw sprites which is perfectly fine! EBT is built on Unity UI and NGUI (you can choose between these two). Unity UI draws itself always on top of everything else on the scene, so when you want to use this option you must be aware that progress bars will always on top "layer". NGUI on the other hand are game objects just like in 2D Toolkit. This may be tricky but I think it's perfectly possible to combine these two.

    Please let me know of any issues. I'll try to help as I can :)
     
  45. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    @Frozmat Games
    I've created real-game example with one simple energy bar. Maybe there's no boxes and it's not so simple as you requested but I believe it will be ok ;-)

    Example and UnityPackage here!

    There's two things for you too look at in the scene:

    First is energyBar game object. This is energy bar script that will render energy bar graphics on the screen.
    Second is PlayerHealth.js script attached to playerBar script. Please look at its content. The most important thing is that this JavaScript file cannot contain #pragma strict declaration. This is because normally JavaScript code does not see C# code during compile time.

     
  46. Frozmat-Games

    Frozmat-Games

    Joined:
    Dec 17, 2012
    Posts:
    25
    This is nice!) Great start point.

    But on Android platform I'm getting this two erors:
    NullReferenceException: Object reference not set to an instance of an object
    Interface.OnGUI () (at Assets/Examples/MinefieldExample/Scripts/Interface.js:8 )

    Assets/Examples/MinefieldExample/Scripts/PlayerHealth.js(17,9): BCE0019: 'ValueF' is not a member of 'UnityEngine.Component'.
     
    Last edited: May 17, 2013
  47. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    This unity package is not standalone project. You need to import EBT into it to work with it. I'll make sure that references are good as soon as I get home :)
     
  48. Frozmat-Games

    Frozmat-Games

    Joined:
    Dec 17, 2012
    Posts:
    25
    Well... that is exactly what I did. :) And it works fine until I change platform from PC to Android.
     
  49. genail

    genail

    Joined:
    Jul 2, 2012
    Posts:
    1,032
    According to this question removing #pragma strict has no effect for mobile platforms. There's another way that I didn't want to try until now. Based on this please try to create Standard Assets folder in root of your project and just move there Energy Bar Toolkit folder with all of its contents.

    This is just a guess, but we will figure this out :)
     
  50. Frozmat-Games

    Frozmat-Games

    Joined:
    Dec 17, 2012
    Posts:
    25
    Yes I already tried it but still getting the same errors. (