x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Replicated Property is resulting in unresolved external error.

I'm getting an unresolved external symbol from my generated header file or something. This property (remaining time) is replicated and thus a GetLifetimeReplicatedProps function is generated in the generated header. I'm not sure how to solve this. I'm mimicking the ShooterGameState.h.

 // PropHuntGameState.h
 #pragma once
 
 #include "GameFramework/GameState.h"
 #include "PropHuntGameState.generated.h"
 
 /**
  * 
  */
 UCLASS()
 class THIRDPERSONBP_API APropHuntGameState : public AGameState
 {
     GENERATED_UCLASS_BODY()
 
     /** time left for warmup / match */
     UPROPERTY(Transient, Replicated)
     int32 RemainingTime;
     
     
 };

1> Creating library C:\Users\Cobryis\Dev\Unreal\ThirdPersonBP\Intermediate\Build\Win64\ThirdPersonBPEditor\DebugGame\UE4Editor-ThirdPersonBP-Win64-DebugGame.lib and object C:\Users\Cobryis\Dev\Unreal\ThirdPersonBP\Intermediate\Build\Win64\ThirdPersonBPEditor\DebugGame\UE4Editor-ThirdPersonBP-Win64-DebugGame.exp 1>PropHuntBase.cpp.obj : error LNK2001: unresolved external symbol "public: virtual void __cdecl APropHuntGameState::GetLifetimeReplicatedProps(class TArray &)const " (?GetLifetimeReplicatedProps@APropHuntGameState@@UEBAXAEAV?$TArray@VFLifetimeProperty@@VFDefaultAllocator@@@@@Z) 1>PropHuntGameState.cpp.obj : error LNK2001: unresolved external symbol "public: virtual void __cdecl APropHuntGameState::GetLifetimeReplicatedProps(class TArray &)const " (?GetLifetimeReplicatedProps@APropHuntGameState@@UEBAXAEAV?$TArray@VFLifetimeProperty@@VFDefaultAllocator@@@@@Z) 1>ThirdPersonBP.generated.cpp.obj : error LNK2019: unresolved external symbol "public: virtual void __cdecl APropHuntGameState::GetLifetimeReplicatedProps(class TArray &)const " (?GetLifetimeReplicatedProps@APropHuntGameState@@UEBAXAEAV?$TArray@VFLifetimeProperty@@VFDefaultAllocator@@@@@Z) referenced in function "class UFunction * __cdecl Z_Construct_UFunction_ATestHUD_OnChatTextSubmitted(void)" (?Z_Construct_UFunction_ATestHUD_OnChatTextSubmitted@@YAPEAVUFunction@@XZ) 1>C:\Users\Cobryis\Dev\Unreal\ThirdPersonBP\Binaries\Win64\UE4Editor-ThirdPersonBP-Win64-DebugGame.dll : fatal error LNK1120: 1 unresolved externals

Product Version: Not Selected
Tags:
more ▼

asked Sep 22 '14 at 11:07 PM in C++ Programming

avatar image

Cobryis
477 34 18 47

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Oh, I'm not very bright. If I had bothered to look at the wiki I would have realized that I do have to write the implementation myself.

more ▼

answered Sep 23 '14 at 12:42 AM

avatar image

Cobryis
477 34 18 47

avatar image Greywacke Mar 11 '17 at 02:10 PM

I just fell for the same think myself. Thanks for answering your question ;)

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question