I am going full Behavior programming, any tips?

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • I see now the advantages of behaviors, and I want to go full behavior from now on, any useful tips?

    I am only uncertain how I will deal with damages, if I will cread a "Receive damage" for player, or "Do damage" for enemies.

    Also, I think I will have trouble with pausing?

  • I stay away from behaviors myself except for very specific uses.
    It would be things that are completely self contained to the object itself.

    Once behaviors start interacting with multiple objects in other behaviors I completely lose track of whats going on.
    Perhaps your brain will work better but it made debugging a nightmare for me .. so for almost everything I stick with the frame event editor.

    I will be pushing for an event editor view in MMF3 where you can see all events interacting with a frame in a single view
    Global Events
    Frame Events
    All Objects behaviors

    Would then be easier for me to use behavior since when it comes time to debug you got one place to list all events to do with an object.

    Please login to see this link.

    Edited once, last by Jeff (December 2, 2011 at 2:19 PM).

  • I stay away from behaviors myself except for very specific uses.
    It would be things that are completely self contained to the object itself.

    Once behaviors start interacting with multiple objects in other behaviors I completely lose track of whats going on.
    Perhaps your brain will work better but it made debugging a nightmare for me .. so for almost everything I stick with the frame event editor.

    I will be pushing for an event editor view in MMF3 where you can see all events interacting with a frame in a single view
    Global Events
    Frame Events
    All Objects behaviors

    Would then be easier for me to use behavior since when it comes time to debug you got one place to list all events to do with an object.

    Jeff. That would be great to have a Event Editor like that. A "map" if you will. Would that be hard to implement?

    Thanks,

    Marv

    458 TGF to CTF 2.5+ Examples and games
    Please login to see this link.

  • Just a curious question Ive always had, hopefully this is a good topic to ask it in.

    Why can't qualifiers be referenced in behaviors? It just seems like it goes out of the way to make it NOT possible, and to tell you such, but I'm curious why its a problem to begin with. Cause doing it would seem simple enough to me.

    Spiritia: Spirit of Friendship: Please login to see this link.

  • I see now the advantages of behaviors, and I want to go full behavior from now on, any useful tips?

    I am only uncertain how I will deal with damages, if I will cread a "Receive damage" for player, or "Do damage" for enemies.

    Also, I think I will have trouble with pausing?


    Useful tip: Don't use behaviors.

    :)

    Please login to see this link.

    My examples:
    Please login to see this link.
    Please login to see this link.
    Please login to see this link.

  • Behaviours, when properly understood can be very powerful. I find them particularly useful when creating GUIs as with a little careful design you can make your menus and interfaces very rapidly and also dynamically generated.

    I made a blog post on here a few days ago about using behaviours to create switches and actuators which can all be dynamically assigned at runtime. This uses two behaviours, one in each of the the two objects, and each with just 3 events. I attached a demo and sample mfa :)

  • I agree with Simon that Behaviors are a great tool if you use them correctly.

    For example, I often have active objects that fade away or have a short life. I use behaviors on those objects count down to 0... when the counter on that object = 0 I destroy it. Also using that counter to increment the alpha blending coefficient and it fades out. So simple, the code is contained in the active's behavior and doesn't get in my way.

    Kevin Gunn (Tuna) - Hey! Check out MechaBall on iTunes by scanning below!
    [SIGPIC][/SIGPIC]

  • The problem comes when you try to debug - every time you debug a behavior you have to go through the process of closing it to run, and reopening it again. Also, debugging becomes difficult with many behaviors.

    Please login to see this link. by KetchupMaster - A must have for any web developer!
    Please login to see this link.

  • Behaviours are pointless - but not because I don't properly understand them.
    Plus, you still can't edit behaviours using the Event List Editor, which is far nicer to use than the horrible Event Editor.

    Tuna:
    You can just as easily put the exact same code inside a group within the main event list. That way you can still simply close the group so it doesn't get in your way, but it's much more easily accessible if you need to change anything, and you're far less likely to overlook it when trying to debug code.

    Simon:
    Again, in your example, you're not really "using" behaviours - the fact that the events are held in behaviours is completely irrelevant - you can just copy & paste them to the main event list and delete the behaviours, and it will function in exactly the same way (yes, I have tested this to make sure).

    Edited once, last by MuddyMole (December 4, 2011 at 3:15 AM).

  • Well...everyone has their own coding techniques and some coders are dead set for coding the way they do. As for me, I have half my brains on the floor and would not be able to debug to well using behaviors. Some coders have the brains of an ice cube, but others are sharp and can deal with debugging better.

    So live in piece and let people code as they will.

    Marv

    458 TGF to CTF 2.5+ Examples and games
    Please login to see this link.

  • If I have events that are specific to certain objects, I will often use behaviors to make sure those events get duplicated/cloned.

    Even if behaviors are usually pointless, Im against their removal if removing them is unneccessary. That way everyone's happy.

    :)

    Spiritia: Spirit of Friendship: Please login to see this link.

  • Behaviors will serve little use until I finish an extension I'm working on. For now, they're an optional way to organize your code in a way that makes sense to you but that is more confusing to others. ;)

    Working as fast as I can on Fusion 3

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!