For version A:
- if I hit F7 inside inside vs 2015 community, it fails linking
Development\UE4Editor-BatteryCollector-4265.lib and object Z: yoc\Unreal Projects\BatteryCollector\Intermediate/Build/Win64\UE4Editor\Development\UE4Editor-BatteryCollector-4265.exp
2>BatteryCollector.generated.cpp.obj : error LNK2001: unresolved external symbol "class FName BATTERYCOLLECTOR_Prox" (?BATTERYCOLLECTOR_Prox@@3VFName@@A)
2>Z: yoc\Unreal Projects\BatteryCollector\Binaries\Win64\UE4Editor-BatteryCollector-4265.dll : fatal error LNK1120: 1 unresolved externals
- from the editor it compiles with the compile button
For version B:
- if I hit F7 inside inside vs 2015 community, it compiles OK
- from the editor it compiles with the compile button
The only difference with A is if I choose to name Prox instead of version B prox (with lower case)
Here the versions:
Bullet.h - Version A
UFUNCTION(BlueprintNativeEvent, Category = "Collision")
void Prox(AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult &SweepResult);
void Prox_Implementation(AActor * OtherActor, UPrimitiveComponent * OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult & SweepResult);
Bullet.cpp - Version A
ProxSphere->OnComponentBeginOverlap.AddDynamic(this, &ABullet::Prox);
void ABullet::Prox_Implementation(AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult & SweepResult)
Bullet.h - version B
UFUNCTION(BlueprintNativeEvent, Category = "Collision")
void prox(AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult &SweepResult);
void prox_Implementation(AActor * OtherActor, UPrimitiveComponent * OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult & SweepResult);
Bullet.cpp - Version B
ProxSphere->OnComponentBeginOverlap.AddDynamic(this, &ABullet::prox);
void ABullet::prox_Implementation(AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult & SweepResult)