Dear Friends at Epic,
Feedback: Probably the hardest thing I am encountering programming UE4 C++ is not being able to figure out what #includes to use to run the awesome functions that you have available.
I am still waiting for an answer on what #include I need for:
WindowsPlatformMisc::ClipboardCopy()
WindowsPlatformMisc::ClipboardPaste()
I spent hours trying to figure out what includes I needed on my own, with no success
I am also needing to know what #includes I need for GetNetMode() (engine.h) and appGetGameType (gametype.h)
none of the below will compile because the functions cannot be found.
Have these symbols been exposed to us Rocket users? (a Staff member used this phrasing with me regardnig a previous compile error of this nature)
//alternate method
ClientMessage(appGetGameType()->ToString());
ENetMode theNetMode;
theNetMode = GetNetMode(GetWorld());
//Client?
if (theNetMode == ENetMode::NM_Client)
{
ClientMessage("Net Mode >> This is a client!");
}
//Listen?
else if (theNetMode == ENetMode::NM_ListenServer)
{
ClientMessage("Net Mode >> This is single player instance!");
}
//single?
else if (theNetMode == ENetMode::NM_Standalone)
{
ClientMessage("Net Mode >> This is single player instance!");
}
Thanks!
Rama
PS: as a side note, using getworld()->IsServer() does not provide accurate info regarding a NM_Standalone game,
this or condition passes even for a single player game instance
UWorld * TheWorld = GetWorld();
if (!TheWorld) return;
if (TheWorld->IsClient() || TheWorld->IsServer())
{
//this code runs even for standalone games, why? its not a server or a client
}