Announcement

Collapse
No announcement yet.

Casting a variable

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Casting a variable

    Hi

    i am pretty new to Unreal.
    My problem: i have a Menu in a WidgetBlueprint. In this Menu i have a slider and i want to send the slider variable to another Blueprint.but i get a warning, that my target Blueprint can not inherit from my object.

    Thanks for any help?

    Greetings

    Christian

    #2
    Essentially, the class you are trying to cast is not a parent class to which you are casting. For more details, read about object-oriented programming (which you should do anyway, if you want to be able to work in UE4). Essentially, one class can inherit all attributes from another class - for example, UE4's Pawn class inherits from the Actor class. Basically, all pawns are actors, but not all actors are pawns. If you want to check if an actor is a pawn, you need to cast the actor to a pawn.

    Comment

    Working...
    X