How do we assign a ".name" to behavior?
This function :
object.getBehavior() seems to return either first behavior if no name is specified or crashes if a name is specified.
i've Tried to make if like:
card_behavior = function ()
{
name = "card_behavior";
......
even
card_behavior = function ()
{
behavior.name = "card_behavior";
......
even
CardObj.addBehavior(card_behavior);
card_behavior.name = "card_behavior";
Still
CardObj.getBehavior("card_behavior");
or
CardObj.getBehavior(card_behavior);
returns Null;
Dunno... Maybe i'm just doing it wrong....