I want the InputComponent->BindAction to call a function from a other class. How can i do that? I try to get this working for like 4 hours now and don’t get anything… So hopefully you guys can help me out!
When you need more Information, please let me know!
I only get this error when i use any variable from the KeyPickUp class. Otherwise, when i only call ‘GEngine->AddOnScreenDebugMessage’, it works perfect.
For explanation: the bool ‘canPickUpKey’ is true, when the player overlaps with the sphere collider of this actor. Only in this sphere, the player can pick up the key. But, as i said, it’s irrelevant which variable i use in this function, i’m always getting “Access violation when writing to position 0x0000000000000330”…
How are you setting the pointer Other? If you just declare it, it will just be NULL, and calling a function on it will crash. You’ll need to set it somehow (via a line trace, via an iteration over all AKeyPickUp instances etc).