I can’t drag and drop functions from my Favorites Menu oder the Find a Node Menu like i used to.
Instead i often get an Error Message: Function is hidden and inaccessible
See Picture in the Attachment
For Example when i want to drop the “Get Actor Location” Function in my PlayerController Class, i can’t do this anymore. Also i can’t duplicate it any more.
I can get the function i want if i pull if from the “Return Value” but i would rather just drag and drop it from my Favorites Menu.
Is there a way to disable this new feature ?
In 4.5 i could just drag and drop everything from my Palette on the right which was way more convenient.
Some nodes are marked as ‘not Blueprint Spawnable’ in certain blueprint classes. The reason behind this is they’re Context Sensitive and will only work with other specific nodes. This is to protect your project from compile errors or even becoming corrupted. These nodes also aren’t allowed to be copied/duplicated because it has been found to sometimes cause errors as well.
Unfortunately there isn’t a way to disable this feature in the editor. You could however alter the source code if you are using the Github version of the editor.
After looking into this issue further, it looks like some of the nodes that were effected weren’t meant to be. Including the GetActorLocation node. It’s been fixed in our latest internal build so you should see this corrected in a future update.
Thank you for answering and looking into the issue further!
Can’t wait for the new update.
I have been impressed with the great support.
Keep on rocking!
CORRECTION BELOW
I am working in C++ and hit the GetActorLocation is hidden problem. After diving into the Unreal souce code (4.7.0)
I found that APlayerState is a subclass of AInfo, which is a subclass of AActor.
So this ugly code appears to have worked so far. It in effect forces the GetActorLocation to get un-hidden.
(I’m finding the nearest player to a NPC Character in the game.)
Maybe there is a more elegant way?
float d2 = NO_PLAYER_DISTANCE * NO_PLAYER_DISTANCE;
APlayerState * nearestPlayer = NULL;
for (int i = 0; i < GetWorld()->GetGameState()->PlayerArray.Num(); i++)
{
// Known bug in Unreal. ** NO ITS NOT! **
APlayerState * pst = GetWorld()->GetGameState()->PlayerArray[i];
// So horribly violate encapsulation.
AActor * act = (AActor *)pst;
float dSq = FVector::DistSquared(act->GetActorLocation(), GetActorLocation());
if (dSq < d2)
{
d2 = dSq;
nearestPlayer = pst;
}
}
*** CORRECTION ***
Turns out the PlayerState is ‘global’ in the world and does not track the location of the player’s Character. Thus correctly, GetActorLocation is hidden.
So you get the Character (possibly sub-class of Character) of the players.