Originally posted by martoof
View Post
Announcement
Collapse
No announcement yet.
[Plugin] Http/s REST, blueprintable JSON and Parse REST API manager at once (VaRest)
Collapse
X
-
Just tested, all works as it should. Please provide example that fails.Making games with Unreal Engine https://ufna.dev
My plugins official channel: https://discord.gg/N92pzqJ
Comment
-
Hi, ufna I am facing some problem about top-level arrays reading.
I have tried to do this: https://www.notion.so/HowTo-Read-top...de0c9e65d512f5 but it still does not work.
Error Log is: LogVaRest: Error: UVaRestJsonObject::SetRootObject(43): Trying to set invalid json object as root one. Reset now.
Thanks you in advance for your attention.
P.S. UE4.21
Edited (1): I've just found actually it did not callback after run Call URL node. Maybe it cause my issue ?
Last edited by タナポン.TEC; 06-11-2020, 02:31 AM.
Comment
-
ok so I Downloaded 4.25plus from github and compiled source. How do i re compile your plugin for source build engines? your wiki is gone. your site links to dead links etc.
I need to recompile the plugin so i can use it with a project requiring chaos but it says this error when trying to compile it:
editor modules can't be compiled while the engine is running.
Comment
-
With 4.25.2 I'm having issues getting my project to package. So I did a fresh pull on the repo and tried to load the the project and can't. I have make sure that the plugin is installed in the engine, but am getting this error when I try to load or build the project:
ERROR: Expecting to find a type to be declared in a module rules named 'VaRest' in UE4Rules, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null. This type must derive from the 'ModuleRules' type defined by Unreal Build Tool.
Comment
-
It's a bug of UE 4.25.2 release. Please check https://forums.unrealengine.com/unre...37#post1792437Making games with Unreal Engine https://ufna.dev
My plugins official channel: https://discord.gg/N92pzqJ
Comment
-
I'm trying to call VaRest plugin in my own plugin written in C++. I think I need to get the object of the UVaRestSubsystem in order to be able to access the rest of the VA* objects (e.g. VaRestRequest, VaRestJson, etc.). How do I get the UVaRestSubsystem in C++? I've used BP and it's just a node, but I'm not sure how to do that in C++.
Comment
-
Originally posted by jshu_quanser View PostI'm trying to call VaRest plugin in my own plugin written in C++. I think I need to get the object of the UVaRestSubsystem in order to be able to access the rest of the VA* objects (e.g. VaRestRequest, VaRestJson, etc.). How do I get the UVaRestSubsystem in C++? I've used BP and it's just a node, but I'm not sure how to do that in C++.Making games with Unreal Engine https://ufna.dev
My plugins official channel: https://discord.gg/N92pzqJ
Comment
-
Another noob question.
Now I want to bind a function in my plugin's class to the UVaRestRequestJSON::OnRequestComplete delegate. I've followed some tutorials (e.g. https://www.youtube.com/watch?v=MwqgmhOL8gs) about how to register the funciton using UVaRestRequestJSON::OnRequestComplete.AddDynamic() method. However, it looks like the AddDynamic() function requires that the class and method be declared using the UCLASS() and UFUNCTION() macros. However my plugin's class is derived from the IAnalyticsProvider class, which is not derived from any other class. Thus I'm not able to successfully add my class's method as delegate using AddDynamic(). So is there any other way to bind/register delegate function?
Comment
-
Ok, looks like I have to use a class that is derived from UObject. So I've done this:
header:
Code:/** * */ UCLASS() class MYOBJECT_API URestCommunicator : public UObject {
GENERATED_BODY()public:UFUNCTION() bool Initialize(); UFUNCTION() void OnRESTComplete(UVaRestRequestJSON* Request); UFUNCTION() void OnRESTFail(UVaRestRequestJSON* Request);private:/** The REST system that is used to send data via REST. */ UPROPERTY() UVaRestSubsystem* RESTSystem; UPROPERTY() UVaRestRequestJSON* JSONRequest;};
Code:bool URestCommunicator::Initialize() {
if (GEngine != nullptr) {RESTSystem = GEngine->GetEngineSubsystem<UVaRestSubsystem>(); if (RESTSystem == nullptr) {return false;}} else {return false;}JSONRequest = RESTSystem->ConstructVaRestRequestExt(EVaRestRequestVerb::POST, EVaRestRequestContentType::json); if (JSONRequest != nullptr) {JSONRequest->OnRequestComplete.AddDynamic(this, &URestCommunicator::OnRESTComplete); JSONRequest->OnRequestFail.AddDynamic(this, &URestCommunicator::OnRESTFail);}return true;}
Code:LogOutputDevice: Error: === Handled ensure: === LogOutputDevice: Error: Ensure condition failed: this->IsBound() [File:C:\Program Files\Epic Games\UE_4.24\Engine\Source\Runtime\Core\Public\Delegates/DelegateSignatureImpl.inl] [Line: 1132] LogOutputDevice: Error: Unable to bind delegate to 'OnRESTComplete' (function might not be marked as a UFUNCTION or object may be pending kill)
I know this is probably not a problem with the plugin, and more to do with the delegate add/bind issue. But just wondering if someone else has tried to do this in C++ and can spot where my problem is.
Comment
-
Please check two things:
1. Solution should be generated again after UFUNCTION was added
2. How URestCommunicator class object is created and existsMaking games with Unreal Engine https://ufna.dev
My plugins official channel: https://discord.gg/N92pzqJ
Comment
Comment