Anyhelo

I am using the upgraded 4.13.2 unreal engine now , when open a new project got an error while compiling in the new engine



Running D:/Program Files (x86)/Epic Games/4.13/Engine/Binaries/DotNET/UnrealBuildTool.exe SimulatorS60_VREditor Development Win64 -project="D:/Kuliah/Semester 8/Simulator57mm_VR 4.13 - 2/Simulator57mm_VR.uproject" -editorrecompile -progress -noubtmakefiles -NoHotReloadFromIDE
 @progress push 5%
Parsing headers for SimulatorS60_VREditor
  Running UnrealHeaderTool "D:\Kuliah\Semester 8\Simulator57mm_VR 4.13 - 2\Simulator57mm_VR.uproject" "D:\Kuliah\Semester 8\Simulator57mm_VR 4.13 - 2\Intermediate\Build\Win64\SimulatorS60_VREditor\Development\SimulatorS60_VREditor.uhtmanifest" -LogCmds="loginit warning, logexit warning, logdatabase error" -Unattended -WarningsAsErrors -installed
Reflection code generated for SimulatorS60_VREditor in 10.2573993 seconds
 @progress pop
Performing 8 actions (2 in parallel)
[2/8] Resource PCLaunch.rc
PCH.SimulatorS60_VR.h.cpp
[3/8] Resource ModuleVersionResource.rc.inl
SimulatorS60_VR.generated.cpp
UDPNetworkingWrapper.cpp
D:\Kuliah\Semester 8\Simulator57mm_VR 4.13 - 2\Source\SimulatorS60_VR\UDPNetworkingWrapper.cpp(10): warning C4996: 'StaticConstructObject': StaticConstructObject is deprecated, please use NewObject instead. For internal CoreUObject module usage, please use StaticConstructObject_Internal. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile.
d:\program files (x86)\epic games\4.13\engine\source\runtime\coreuobject\public\uobject\UObjectGlobals.h(245): note: see declaration of 'StaticConstructObject'
D:\Kuliah\Semester 8\Simulator57mm_VR 4.13 - 2\Source\SimulatorS60_VR\UDPNetworkingWrapper.cpp(56): error C2660: 'TArray<uint8,FDefaultAllocator>::Init': function does not take 1 arguments
UDPComponent.cpp
SimulatorS60_VR.cpp
ERROR: UBT ERROR: Failed to produce item: D:\Kuliah\Semester 8\Simulator57mm_VR 4.13 - 2\Binaries\Win64\UE4Editor-SimulatorS60_VR.dll
Total build time: 115.39 seconds


here’s the suspected file



// Fill out your copyright notice in the Description page of Project Settings.

#include "SimulatorS60_VR.h"
#include "UDPNetworkingWrapper.h"
#include <string>
#include "UDPNetworkingWrapper.h"

UUDPNetworkingWrapper* UUDPNetworkingWrapper::Constructor()
{
	return (UUDPNetworkingWrapper*)StaticConstructObject(UUDPNetworkingWrapper::StaticClass());
}

UUDPNetworkingWrapper* UUDPNetworkingWrapper::ConstructUDPWrapper(const FString& Description, const FString& SenderSocketName, const FString& TheIP, const int32 ThePort, const int32 BufferSize,
	const bool AllowBroadcast, const bool Bound, const bool Reusable, const bool Blocking)
{

	UUDPNetworkingWrapper* wrapper = Constructor();

	wrapper->SocketSubsystem = ISocketSubsystem::Get(PLATFORM_SOCKETSUBSYSTEM);
	FIPv4Address::Parse(TheIP, wrapper->RemoteAdress);

	wrapper->SenderSocket = FUdpSocketBuilder(TEXT("DATA"))
		.AsNonBlocking()
		.AsReusable()
		.BoundToAddress(FIPv4Address::Any)
		.BoundToPort(ThePort)
		.WithMulticastLoopback();
	return wrapper;
}

void UUDPNetworkingWrapper::sendMessage(int32 port, FString Message)
{
	FSocket* Socket = FUdpSocketBuilder(TEXT("DATA"))
		.AsNonBlocking()
		.AsReusable()
		.WithMulticastLoopback();
	FString se = Message;
	FIPv4Endpoint re = FIPv4Endpoint(FIPv4Address::LanBroadcast, port);
	bool c = Socket->Connect(*re.ToInternetAddr());
	TCHAR *serializedChar = se.GetCharArray().GetData();
	int32 size = FCString::Strlen(serializedChar);
	int32 sent = 0;
	bool s = Socket->Send((uint8*)TCHAR_TO_UTF8(serializedChar), size, sent);
	Socket->Close();
}

FString UUDPNetworkingWrapper::GrabWaitingMessage()
{
	uint32 Size;

	TSharedRef<FInternetAddr> Sender = SocketSubsystem->CreateInternetAddr();

	while (SenderSocket->HasPendingData(Size))
	{
		int32 Read = 0;
		ReceivedData.Init(FMath::Min(Size, 65507u));
		SenderSocket->RecvFrom(ReceivedData.GetData(), ReceivedData.Num(), Read, *Sender);
	}

	return StringFromBinaryArray(ReceivedData);
}

bool UUDPNetworkingWrapper::anyMessages()
{
	uint32 Size;

	if (SenderSocket->HasPendingData(Size))
	{
		return true;
	}

	return false;
}

FString UUDPNetworkingWrapper::StringFromBinaryArray(const TArray<uint8>& BinaryArray)
{
	const std::string cstr(reinterpret_cast<const char*>(BinaryArray.GetData()), BinaryArray.Num());
	return FString(cstr.c_str());
}

void UUDPNetworkingWrapper::UDPDestructor()
{
	SocketSubsystem->DestroySocket(SenderSocket);
	SenderSocket = nullptr;
	SocketSubsystem = nullptr;
}


other

As it says, the ReceivedData.Init() call has the wrong amount of arguments.