Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

(RELEASED) Cartoon FX: Cartoon/Comic Book styled Particles Effects Pack

Discussion in 'Assets and Asset Store' started by Jean-Moreno, Aug 1, 2012.

Thread Status:
Not open for further replies.
  1. sirius_002

    sirius_002

    Joined:
    Aug 16, 2012
    Posts:
    65
    Hi Jean,

    I bought both your cartoon packs, but there is one "war fx" particle system I would like as a cartoon effect and that's the muzzle flashes!

    Thanks for your consideration.
     
  2. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Well I'm quite busy these days, and it turns out that I'm making cartoon muzzle flashes for a project, but they are more complicated to do with a cartoon style: turns out the technique I used so that the effect looks good from all angles doesn't work well with solid shapes, so it requires more work than just changing textures.

    Short answer: it's unlikely that I'll update the packs anytime soon, and probably without such an effect. Sorry :-/
     
  3. sirius_002

    sirius_002

    Joined:
    Aug 16, 2012
    Posts:
    65
    Well, I can appreciate your honesty.
     
  4. accessdev

    accessdev

    Joined:
    May 9, 2012
    Posts:
    37
    Hi,

    One thing is unclear for me :

    once I have added the CFX_SpawnSystem script and preloaded one or more objects how do I find the GameObject I have to put in parameter

    For exemple I preloaded "CFX2 Blood" what do I have to do to spawn this prefab in my scene
     
  5. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    You have to set the same source prefab (or object) that you dropped onto the spawn script as your variable to retrieve the copies.

    For example:
    Code (csharp):
    1.  
    2. C#:
    3. public GameObject myEffect;  // --> drop the "CFX2_Blood" prefab from your Project panel
    4.  
    5. void MyFunction()
    6. {
    7.     (...)
    8.     GameObject preloadedEffect = CFX_SpawnSystem.GetNextObject(myEffect); // --> returns the next *copy* of the source object
    9.     (...)
    10. }
    11.  
    12. JS:
    13. public var myEffect:GameObject;  // --> drop the "CFX2_Blood" prefab from your Project panel
    14.  
    15. function MyFunction()
    16. {
    17.     (...)
    18.     var preloadedEffect:GameObject = CFX_SpawnSystem.GetNextObject(myEffect); // --> returns the next *copy* of the source object
    19.     (...)
    20. }
    21.  
     
  6. accessdev

    accessdev

    Joined:
    May 9, 2012
    Posts:
    37
    Thanks for your quick reply !

    I m doing this but for some reason I get an error message about the usage of CFX_SpawnSystem

    error CS0103: The name `CFX_SpawnSystem' does not exist in the current context

    Do i need a usign directive or something ?
     
  7. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    If you are using JavaScript, you need to place the spawn script in a particular folder so that it is compiled beforehand and let the JS scripts know about it (by default C# scripts are compiled last). I suggest putting it in the "Plugins" folder.

    See here for more informations: Script compilation.

    If you are not using JavaScript then it probably means that something went wrong with the compilation, but then you shouldn't normally have this error alone.
     
  8. meta87

    meta87

    Joined:
    Dec 31, 2012
    Posts:
    254
    I purchased both cartoon packs and they look great! I have a quick question about increasing the size of the effects. The size of everything in my game is very large because I'm using 2dtoolkit. This means I need the effects to be significantly larger.

    For some effects I've just increased the "start size" setting, but this doesnt look right for others. Is there a better way to go about it?

    For instance, the rock particles in the "Debris hit" prefab do not seem to increase in size, just the impact flashes. Very excited to get these working. The tool inspector window is great. Thanks.
     
  9. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Use the included Cartoon FX Easy Editor!
    In the top menu: GameObject -> Cartoon FX Easy Editor

    Once the editor window is opened, select any effect, set the scale multiplier in the editor, and hit "Scale Size". This will adjust all of the effect's settings related to speed/size so that it scales the effect properly!
    Make sure to Stop the effect and Play it again in the Scene view to properly view the changes.

    Let me know if you are having any issue.
     
  10. meta87

    meta87

    Joined:
    Dec 31, 2012
    Posts:
    254
    Thanks for the quick response. I totally missed that, got it working easily. very cool.
     
  11. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,043
    Just letting you know that the latest version of Cartoon FX is broken a bit in Unity 4.1... hopefully you're working on it?

    EDIT: Actually, it's interesting...

    All I needed to do was add a set of braces in CFX_SpawnSystem.cs, so this:

    Code (csharp):
    1.  
    2. GameObject returnObj = instance.instantiatedObjects[uniqueId][cursor];
    3. if(activateObject)
    4.     #if UNITY_4_0
    5.             returnObj.SetActive(true);
    6.     #elif UNITY_3_5
    7.             returnObj.SetActiveRecursively(true);
    8.     #endif
    9.  
    became this:

    Code (csharp):
    1.  
    2. GameObject returnObj = instance.instantiatedObjects[uniqueId][cursor];
    3. if(activateObject)
    4. {
    5.     #if UNITY_4_0
    6.             returnObj.SetActive(true);
    7.     #elif UNITY_3_5
    8.             returnObj.SetActiveRecursively(true);
    9.     #endif
    10. }
    11.  
    It shouldn't matter though, unless something has changed in the handling of those directives?

    EDIT, EDIT: And of course I'm an idiot :) Not all code paths return values now because there's no case for Unity 4.1! Anyway... something to fix in the next version.
     
    Last edited: Mar 15, 2013
  12. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Thanks for the notice! :)
    I've just submitted an update that fixes this issue.
    Actually the proper fix is:
    Code (csharp):
    1.  
    2. if(activateObject)
    3.     #if UNITY_3_5
    4.             returnObj.SetActiveRecursively(true);
    5.     #else
    6.             returnObj.SetActive(true);
    7.     #endif
    8.  
    With just the brackets added there's still no case for 4.1, so the activateObject flag is just ignored!
     
  13. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    I've also added 4 new effects!



    Hope you'll like them :)
     
    Last edited: Mar 25, 2013
  14. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,043
    Just ran into a new issue unfortunately. Whenever I try to import the latest version from the Asset Store (on MacOS) it gets to the following entry and Unity freezes. The only way out is a Force Quit.



    NOTE: As a workaround, have just turned off importing of all the /Demo/ assets.
     

    Attached Files:

    Last edited: Mar 18, 2013
  15. SteveB

    SteveB

    Joined:
    Jan 17, 2009
    Posts:
    1,448
    I'm assuming Cartoon FX 2 will be updated the same...soon?

    Thanks Jean!

    -Steve
     
  16. ZJP

    ZJP

    Joined:
    Jan 22, 2010
    Posts:
    2,646
    These effects are not present on the actual WebPlayer demo.Right?
     
  17. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    I had sent the update at the same time but it got approved after the weekend! Anyway the new update is up :)
    If we don't find a way to solve that import crash, I'll have to disable the water shader.

    Oops, no I forgot to update it! Thanks for the notice. Let me fix that...

    EDIT: New demo is up! The new effects are at the end of the list!
     
    Last edited: Mar 19, 2013
  18. huxley

    huxley

    Joined:
    Apr 27, 2009
    Posts:
    329
    Salut Jean,

    I'm getting an error when I try to export using unity flash v4.1. I have updated the latest cartoon fx patch that you have on the store.

    "Assets/Cartoon FX/Scripts/CFX_AutoDestructShuriken.cs(19,29): error CS0103: The name 'particleSystem' does not exist in the current context"

    merci pour vous m'aider
     
  19. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    This looks like an omission of the API in Unity Flash.

    Try this in Cartoon FX/Scripts/CFX_AutoDestructShuriken.cs :
    Code (csharp):
    1.  
    2. // Replace:
    3. if(!particleSystem.IsAlive(true))
    4. // With:
    5. if(!this.GetComponent<ParticleSystem>().IsAlive(true))
    6.  
    Let me know if it does the trick!
     
  20. huxley

    huxley

    Joined:
    Apr 27, 2009
    Posts:
    329
    yes, that corrected the error. Thanks!
     
  21. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Hey everyone!

    Version 2.5 has just been submitted with new effects, including this sweet tornado effect:



    The new effects are:
    * Explosions/CFX_Firework (multiple colors)
    * Misc/CFX_Tornado (+ looped, big)
    * Misc/CFX_Tornado_Straight (+ looped, big)
    * Misc/CFX_GroundAura

    The demo has been updated as well, the new effects are the last ones!

    Enjoy! :)
     
  22. ZJP

    ZJP

    Joined:
    Jan 22, 2010
    Posts:
    2,646
    Happy to see that you improve this package constantly. Thx ;)
     
  23. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,043
    Getting the following error whenever I try to build my project. Very weird - only happening since I updated to the new version of Cartoon FX that came out recently.

     

    Attached Files:

  24. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Just checked it and indeed there's an editor script that has been duplicated outside of the Editor folder! I'll fix the package as soon as I can.

    In the meantime, you can safely delete the "Assets/Cartoon FX/CFX_SpawnSystemEditor.cs" file and it should compile fine again.
     
  25. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,043
    Thanks!
     
  26. akstntn

    akstntn

    Joined:
    May 28, 2013
    Posts:
    19
    Hello.

    Could you please explain how to use CFX Spawn System?

    I bought Cartoon FX Pack but no idea how to use CFX Spawn System.

    How can I open it in inspector?
     
  27. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Follow these steps:
    - create an Empty GameObject in your Scene
    - drop the CFX_SpawnSystem script on it
    - the interface will now appear in the Inspector when you select this GameObject
    - drag/drop the prefabs that you want to preload on this interface
    - use the following line in your own scripts to instantiate the effects from the pool:
    Code (csharp):
    1. CFX_SpawnSystem.GetNextObject(myPrefab);
    where myPrefab is a reference to the same prefab you dropped on the interface.

    Let me know if it works or if you need something else!
     
  28. akstntn

    akstntn

    Joined:
    May 28, 2013
    Posts:
    19
    Wow... fast reply..

    Thank you so much !!!
     
  29. akstntn

    akstntn

    Joined:
    May 28, 2013
    Posts:
    19
    Hello

    I need to change the prefab position
    Below is the part of my code

    if( PC.Instance.PcSpellShortcut[0].GetType().ToString() == "Bolt" ) {
    if( tar.selectedTarget != null ) {
    CFX_SpawnSystem.GetNextObject( go );

    go.transform.position = tar.selectedTarget.position;

    // Instantiate ( go, tar.selectedTarget.position, go.transform.rotation );
    tar.selectedTarget.SendMessage( "UptadeMobCurHP", ( (Bolt) PC.Instance.PcSpellShortcut[0]).MaxDamageValue );
    }

    else {
    Instantiate ( go, PC.Instance.transform.position , go.transform.rotation );
    }
    }


    when I press a button , I find the nearest enemy and attack the enemy by the prefab.

    The problem is when i press a button , the prefab position does not change

    If I use instantiate . it works.

    How do I change the prefab position?

    Thank you
     
    Last edited: Jun 5, 2013
  30. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    The CFX_GetNextObject function returns the instantiated object, so you need to change the position of that reference instead of the prefab reference (which won't do anything); so this line:
    Code (csharp):
    1.  
    2. CFX_SpawnSystem.GetNextObject( go );
    3. go.transform.position = tar.selectedTarget.position;
    4. // Here you're changing the position of the *prefab* object, which is the "model" for your object, not the actual object in the scene
    5.  
    becomes
    Code (csharp):
    1.  
    2. GameObject instance = CFX_SpawnSystem.GetNextObject( go );
    3. instance.transform.position = tar.selectedTarget.position;
    4.  
    (PS: You should copy/paste your code in the [*CODE] code here [*/CODE] brackets (without the *) for better readability on the forum)
     
  31. akstntn

    akstntn

    Joined:
    May 28, 2013
    Posts:
    19
    Thank you , sir . It works great now

    You are my hero.

    ( ps. I did not know how to copy code ;;; sorry about that )
     
  32. Shreddin_PB

    Shreddin_PB

    Joined:
    May 30, 2013
    Posts:
    5
    Hey there.. bought this the other day, and I am having a really hard time getting it going.. I dont know why.
    I havnt worked in Unity for a while so I am sure that is it ;)

    I followed your steps above. Everything goes fine until step 4. I add the code to my script, but I dont know how to make "myPrefab" a gameObject :( I know.. seems terrible. Here is the relevant part of the script

    Code (csharp):
    1. using UnityEngine;
    2. using System.Collections;
    3.  
    4. public class levelLost : MonoBehaviour {
    5.    
    6.     private static GameObject lowestBubble;
    7.     public GameObject lostParticleSystem;
    8.  
    9.     public static void lost()
    10.     {
    11.         CFX_SpawnSystem.GetNextObject(lostParticleSystem,true);
    12.     }
    13. }
    14.  
    If I leave it like this then I can drag my prefab onto the script (levelLost), but I get this error
    Code (csharp):
    1. Assets/Scripts/Levels/levelLost.cs(19,47): error CS0120: An object reference is required to access non-static member `levelLost.lostParticleSystem'
    2.  
    So I tried adding static to public GameObject lostParticleSystem;, but then I loose the ability to drag the prefab to my script, so how do I tell it which prefab it is?

    thanks!
     
  33. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    This is because, in the code you posted above, lostParticleSystem is an instance variable whereas lost() is a static method.

    You should make lost() an instance method too, then you won't have the error.
    Then in the script where I assume you call "levelLost.lost()", you should change it so it takes the GameObject on which you added your levelLost script as a reference, i.e. :
    Code (csharp):
    1.  
    2. public levelLost myLevel;  //drag the GameObject on which you have added the levelLost script
    3. (...)
    4. myLevel.lost();
    5.  
     
  34. Shreddin_PB

    Shreddin_PB

    Joined:
    May 30, 2013
    Posts:
    5
    GIANT LIGHTBULB on top of my head!

    That whole thing right there is something I never really understood (I taught myself c# for unity by just doing it) and I only know a little C++ from writting some maya plugins (also self taught). I never quite understood how that worked.. and looking it up never seemed to say it in the way I could understand.

    I get it now!
    That little bit of information learned right there is worth the price I payed for your effects pack!!
    Thanks again!
     
  35. Donkey111

    Donkey111

    Joined:
    Mar 17, 2013
    Posts:
    9
    I can't get the effects to spawn in my level (new to unity). I added a blank object (called it VFX_Spawner) and added CFX_SpawnSystem Script to it. I dropped in CFXM2_PickupHeart. At the top of my gameplay script, I added:

    public GameObject HeartBreakVFX

    and dropped in the CFXM2_PickupHeart prefab. I then called this from script:

    GameObject Player = GameObject.Find("Player");
    CFX_SpawnSystem.GetNextObject(HeartBreakVFX);
    HeartBreakVFX.transform.position = Player.transform.position;

    It doesn't show up on my player! Is this how you spawn the vfx? I'm new to Unity and this is confusing.
     
  36. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    The steps are correct, you only have a small problem in your code:
    Code (csharp):
    1.  
    2. CFX_SpawnSystem.GetNextObject(HeartBreakVFX);
    3. HeartBreakVFX.transform.position = Player.transform.position;
    4.  
    Here you're changing the position of the prefab linked to HeartBreakVFX, which isn't an actual object of your scene (hence why it doesn't do anything).
    You have to get a reference to the copy of that prefab, and change the position of the copy instead.
    Here's the proper code:
    Code (csharp):
    1.  
    2. GameObject heartBreakCopy = CFX_SpawnSystem.GetNextObject(HeartBreakVFX);
    3. heartBreakCopy.transform.position = Player.transform.position;
    4.  
     
  37. Xete

    Xete

    Joined:
    Oct 17, 2012
    Posts:
    9
    Hi Jean, straight to the point i was wondering whenever a JS version of the CFX_SpawnSystem can be done?if not its understandable since all your codes are in c# , thx
     
  38. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    It is not planned, but you can actually use the system with JS code: make sure to put the CFX_SpawnSystem.cs file in a folder named "Plugins" so that it is compiled before all other files, then you'll be able to call CFX_SpawnSystem.GetNextObject(obj); from JS files (or any other function).
    More info here: http://docs.unity3d.com/Documentation/ScriptReference/index.Script_compilation_28Advanced29.html
     
  39. Xete

    Xete

    Joined:
    Oct 17, 2012
    Posts:
    9
    wow i didnt know that cud work :eek: and i will try thanks for support
     
  40. SteveB

    SteveB

    Joined:
    Jan 17, 2009
    Posts:
    1,448
    Quick note:

    Still getting the "CFX_SpawnSystemEditor" error. I deleted it as per your instructions above...am I to assume this is still the case with your latest update?

    Thanks Jean!!
     
  41. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Err...indeed the misplaced script was here again!
    I've issued a new update without it; and made sure to delete it from my SVN repository!

    Thanks for the notice!
     
  42. alexsan75

    alexsan75

    Joined:
    Feb 6, 2012
    Posts:
    95
    Hello Jean,
    just want to thank you for such amazing Unity assets!
    We bought both Cartoon FX and FX2, thanks to these - our game got even more polished with cool effects :cool:

    The Game 5 Vikings has just been released and is now available on the App Store:
    https://itunes.apple.com/us/app/5-vikings/id659539981?mt=8

    $5vikings_003.jpg

    Thanks again and keep delivering great assets!
     
    Last edited: Aug 9, 2013
  43. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    That's very nice! I hope it'll be a success :)
    Is there an Android version planned? I'd love to try it!
     
  44. alexsan75

    alexsan75

    Joined:
    Feb 6, 2012
    Posts:
    95
    Thanks! we hope too :)

    And Yes, there will be an Android version of the 5 Vikings game. It is scheduled to be released sometime this july 2013, both paid and free versions. I'll let you know, of course ) .. or you could subscribe at www.5vikings.com/5-vikings/

    Btw, nice WAR FX pack! Love it.
     
    Last edited: Aug 9, 2013
  45. alexsan75

    alexsan75

    Joined:
    Feb 6, 2012
    Posts:
    95
    5 Vikings arcade / puzzle game is now available for both iOS and Android!
    Help those brave vikings to battle through the waves of Moorlocks :D

    5 Vikings on iOS

    5 Vikings for Android


    Test how Cartoon FX pack is integrated in our game:

    $5viking_screenshot_0006.jpg
     
    Last edited: Aug 9, 2013
  46. blurededge

    blurededge

    Joined:
    Mar 14, 2012
    Posts:
    255
    Hey Jean, I just purchased your fX pack and it's great but I'm having issues with (you guessed it) the spawn system. It seems the system will only spawn as many of the particle systems as I pre-load rather than recycling them. Below is a copy of the error I'm getting in the Unity Console. Any help would be appreciated. Thanks!

    $Error.jpg
     
  47. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Are you destroying the effects manually somewhere?
    If so, you shouldn't have to worry about destroying the effects. Once they are added to the Spawn System, they'll be automatically deactivated once they're finished, and ready to be used again.
    Also, the system doesn't check whether the next object is active or not, so make sure to set the correct number of times that an effect can appear simultaneously on screen or you may notice some effects to be moved from one point to another when they're not finished.
     
  48. duncanx

    duncanx

    Joined:
    Feb 12, 2011
    Posts:
    43
    Needs ice theme added (to either this pack or Cartoon FX 2). Pretty please :p
     
  49. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Funny thing, I'm actually working on Cartoon FX 3 and it will partly be based on fantasy themed-effects, including ice ones!
    More information hopefully next week ;)
     
  50. Jean-Moreno

    Jean-Moreno

    Joined:
    Jul 23, 2012
    Posts:
    463
    Cartoon FX Pack 3 should be released later today, at an introductory price of 10$ only! ;)
    You can already see the webplayer demo here !
     
Thread Status:
Not open for further replies.
unityunity