Download

Is there a "Class equal to"?

I want to check if self is of a particular type of blueprint but can’t figure it out. Object equal doesn’t work since that’s for a specific instance and I can’t find a cindition for type/class.

Thoughts?

Thanks

You can attempt to cast it to the type you are looking for. The cast function has an execution output for both success and failure so you can use it for this type of decision making.

True! Not pretty, but it could work for now.

The cast method should work. That was a pretty standard method back in the UnrealScript days. All objects have an IsA() function, but I don’t think it’s exposed to Blueprints. I think there is also a GetActorClass() function you can use with an Actor to get its class which I would assume you could then check with an equality node.

The node “Get Class” return the class of an object.

The node “Class Is Child Of” compare 2 classes.

As Parkar mentioned, you have to use Cast for 4.0, but 4.1 will have == and != for classes exposed to Blueprints as well.

Cheers,
Michael Noland

Sweet! Happy to hear it.

Yay more options!