Announcement

Collapse
No announcement yet.

Issue casting to a NPC blueprint

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

    Issue casting to a NPC blueprint

    I have a NPC blueprint but i cannot seem to cast to it
    If i use get player character it comes back cast failed
    Anything else i try comes up with warning or error.
    It has a parent class of Character

    #2
    Originally posted by Zael11 View Post
    I have a NPC blueprint but i cannot seem to cast to it
    If i use get player character it comes back cast failed
    Anything else i try comes up with warning or error.
    It has a parent class of Character
    Your problem is hidden in your question

    NPC = non player character, if you did this:

    Click image for larger version

Name:	NPC.JPG
Views:	75
Size:	32.6 KB
ID:	1773463

    it's always going to fail unless you are actually controlling the NPC with the player controller. This call always give you the character you're currently controlling.

    If you want references to NPCs, try:

    Click image for larger version

Name:	getactor.JPG
Views:	71
Size:	13.8 KB
ID:	1773464

    Check out Zof ( puzzle game ) on Steam:

    https://store.steampowered.com/app/1414480/Zof/

    Comment

    Working...
    X