Giter Site home page Giter Site logo

unrealcs's People

Contributors

marynate avatar xiongfang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

unrealcs's Issues

cannot use System.Drawing.Color

I am trying to use System.Drawing.Color structure, but getting an error.

I've already copied

c:\Program Files\Mono\lib\mono\4.6.2-api\System.Drawing.dll
to
\Content\Scripts\framework\

.cs
Color color = Color.Aqua;

It compiles, but throwing exception on run

LogMono:Warning: Unhandled Exception:
System.NullReferenceException: Object reference not set to an instance of an object
at Game.RotateMe.BeginPlay () <0x1de015f2660 + 0x0004c> in :0

Using an external C# DLL

I am trying to use a very simple c#.dll with the plugin. It has only one test function, but I always get an error message, in unreal engine when I call my test function.

LogMono:Warning: Unhandled Exception:
System.IO.FileNotFoundException: Could not load file or assembly 'DLLTest, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
File name: 'DLLTest, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'

Is it possible to use external DLLs with the plugin? If so, where should I place my dll ?

Can't get json from my api

Hello,

I am trying to download player info from my WebApi project but UnrealCs crashing when i run this code

using (WebClient wc = new WebClient())
            {
                var json = wc.DownloadString("http://localhost:2556/api/*****/" + username + "/" + password);
                LogInfo(json.ToString());
            }

LogMono:Warning: Unhandled Exception: System.Net.WebException: An exception occurred during a WebClient request. ---> System.TypeInitializationException: The type initializer for 'System.Net.WebRequest' threw an exception. ---> System.Configuration.ConfigurationErrorsException: Error Initializing the configuration system. ---> System.ArgumentException: The 'ExeConfigFilename' argument cannot be null. at System.Configuration.ExeConfigurationHost.CheckFileMap (ConfigurationUserLevel level, System.Configuration.ExeConfigurationFileMap map) <0x22b835c4e60 + 0x00122> in <filename unknown>:0 at System.Configuration.ExeConfigurationHost.InitForConfiguration (System.String& locationSubPath, System.String& configPath, System.String& locationConfigPath, IInternalConfigRoot root, System.Object[] hostInitConfigurationParams) <0x22b835c47b0 + 0x00142> in <filename unknown>:0 at System.Configuration.InternalConfigurationSystem.InitForConfiguration (System.String& locationConfigPath, System.String& parentConfigPath, System.String& parentLocationConfigPath) <0x22b835c4730 + 0x00052> in <filename unknown>:0 at System.Configuration.Configuration..ctor (System.Configuration.InternalConfigurationSystem system, System.String locationSubPath) <0x22b835c4510 + 0x000f1> in <filename unknown>:0 at System.Configuration.InternalConfigurationFactory.Create (System.Type typeConfigHost, System.Object[] hostInitConfigurationParams) <0x22b835c3f90 + 0x00084> in <filename unknown>:0 at System.Configuration.ConfigurationManager.OpenExeConfigurationInternal (ConfigurationUserLevel userLevel, System.Reflection.Assembly calling_assembly, System.String exePath) <0x22b835c2f80 + 0x00408> in <filename unknown>:0 at System.Configuration.ClientConfigurationSystem.get_Configuration () <0x22b835c2d00 + 0x0004a> in <filename unknown>:0 --- End of inner exception stack trace --- at System.Configuration.ClientConfigurationSystem.get_Configuration () <0x22b835c2d00 + 0x00106> in <filename unknown>:0 at System.Configuration.ClientConfigurationSystem.System.Configuration.Internal.IInternalConfigSystem.GetSection (System.String configKey) <0x22b835c2c60 + 0x00022> in <filename unknown>:0 at System.Configuration.ConfigurationManager.GetSection (System.String sectionName) <0x22b835c2940 + 0x00039> in <filename unknown>:0 at System.Net.WebRequest..cctor () <0x22b835c25b0 + 0x00099> in <filename unknown>:0 --- End of inner exception stack trace --- at System.Net.WebClient.GetWebRequest (System.Uri address) <0x22b835c2390 + 0x00025> in <filename unknown>:0 at System.Net.WebClient.DownloadDataInternal (System.Uri address, System.Net.WebRequest& request) <0x22b835c1fa0 + 0x00070> in <filename unknown>:0 --- End of inner exception stack trace --- at System.Net.WebClient.DownloadDataInternal (System.Uri address, System.Net.WebRequest& request) <0x22b835c1fa0 + 0x0037b> in <filename unknown>:0 at System.Net.WebClient.DownloadString (System.Uri address) <0x22b835c1cc0 + 0x00060> in <filename unknown>:0 at System.Net.WebClient.DownloadString (System.String address) <0x22b835b5a40 + 0x00044> in <filename unknown>:0 at (wrapper remoting-invoke-with-check) System.Net.WebClient:DownloadString (string) at Game.MainUI.OnClickSummit () <0x22b8359a570 + 0x0023a> in <filename unknown>:0

Crash when inheriting from AMonoCharacter ?

First of all thanks for this wonderful plugin !

Here's the issue, when I try to make a new class that inherits from AMonoCharacter, Unreal crashes.
A simple class such as : public class VillagerCSharp: AMonoCharacter {} causes this.

What am I doing wrong here?

Here's the crashlog:

[2017.05.13-19.34.17:850][796]LogWindows:Error: === Critical error: ===
[2017.05.13-19.34.17:850][796]LogWindows:Error: 
[2017.05.13-19.34.17:850][796]LogWindows:Error: Fatal error!
[2017.05.13-19.34.17:850][796]LogWindows:Error: 
[2017.05.13-19.34.17:850][796]LogWindows:Error: Unhandled Exception: EXCEPTION_ACCESS_VIOLATION reading address 0x00000010
[2017.05.13-19.34.17:850][796]LogWindows:Error: 
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoPlugin.dll!UMonoScriptBind_Component::InitDefault() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoplugin\private\monoscriptbind_component.cpp:62]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoPlugin.dll!UMonoScriptClass::CreateDefaultObject() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoplugin\private\monoscriptclass.cpp:117]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-CoreUObject.dll!UClass::GetDefaultObject() [c:\unrealsource\unrealengine\engine\source\runtime\coreuobject\public\uobject\class.h:2251]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-KismetCompiler.dll!FKismetCompilerContext::FinishCompilingClass() [c:\unrealsource\unrealengine\engine\source\editor\kismetcompiler\private\kismetcompiler.cpp:2153]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoEditorPlugin.dll!FMonoBlueprintCompiler::FinishCompilingClass() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoeditorplugin\private\monoblueprintcompiler.cpp:212]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-KismetCompiler.dll!FKismetCompilerContext::Compile() [c:\unrealsource\unrealengine\engine\source\editor\kismetcompiler\private\kismetcompiler.cpp:3799]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoEditorPlugin.dll!FMonoBlueprintCompiler::Compile() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoeditorplugin\private\monoblueprintcompiler.cpp:237]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoEditorPlugin.dll!FScriptEditorPlugin::Compile() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoeditorplugin\private\monoeditorplugin.cpp:184]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-KismetCompiler.dll!FKismet2CompilerModule::CompileBlueprintInner() [c:\unrealsource\unrealengine\engine\source\editor\kismetcompiler\private\kismetcompilermodule.cpp:118]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-KismetCompiler.dll!FKismet2CompilerModule::CompileBlueprint() [c:\unrealsource\unrealengine\engine\source\editor\kismetcompiler\private\kismetcompilermodule.cpp:230]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-UnrealEd.dll!FKismetEditorUtilities::CreateBlueprint() [c:\unrealsource\unrealengine\engine\source\editor\unrealed\private\kismet2\kismet2.cpp:515]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoEditorPlugin.dll!UMonoFactory::FactoryCreateNew() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoeditorplugin\private\monofactory.cpp:110]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoEditorPlugin.dll!FScriptEditorPlugin::Event_OnNewClass() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoeditorplugin\private\monoeditorplugin.cpp:152]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoEditorPlugin.dll!TBaseRawMethodDelegateInstance<0,FScriptEditorPlugin,void __cdecl(FString const & __ptr64,UClass * __ptr64)>::ExecuteIfSafe() [c:\unrealsource\unrealengine\engine\source\runtime\core\public\delegates\delegateinstancesimpl.h:648]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoPlugin.dll!TBaseMulticastDelegate<void,FString const & __ptr64,UClass * __ptr64>::Broadcast() [c:\unrealsource\unrealengine\engine\source\runtime\core\public\delegates\delegatesignatureimpl.inl:937]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoPlugin.dll!FMonoDomain::NativeHotReload() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoplugin\private\monodomain.cpp:638]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoPlugin.dll!FMonoDomain::HotReload() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoplugin\private\monodomain.cpp:667]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-MonoPlugin.dll!FMonoDomain::Tick() [c:\unrealsource\unrealengine\engine\plugins\unrealcs\source\monoplugin\private\monodomain.cpp:728]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-Engine.dll!FTickableGameObject::TickObjects() [c:\unrealsource\unrealengine\engine\source\runtime\engine\private\leveltick.cpp:1182]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-UnrealEd.dll!UEditorEngine::Tick() [c:\unrealsource\unrealengine\engine\source\editor\unrealed\private\editorengine.cpp:1666]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor-UnrealEd.dll!UUnrealEdEngine::Tick() [c:\unrealsource\unrealengine\engine\source\editor\unrealed\private\unrealedengine.cpp:391]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor.exe!FEngineLoop::Tick() [c:\unrealsource\unrealengine\engine\source\runtime\launch\private\launchengineloop.cpp:3025]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor.exe!GuardedMain() [c:\unrealsource\unrealengine\engine\source\runtime\launch\private\launch.cpp:166]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor.exe!GuardedMainWrapper() [c:\unrealsource\unrealengine\engine\source\runtime\launch\private\windows\launchwindows.cpp:134]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor.exe!WinMain() [c:\unrealsource\unrealengine\engine\source\runtime\launch\private\windows\launchwindows.cpp:210]
[2017.05.13-19.34.17:850][796]LogWindows:Error: UE4Editor.exe!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:259]
[2017.05.13-19.34.17:850][796]LogWindows:Error: KERNEL32.DLL!0x0000000059B62774
[2017.05.13-19.34.17:850][796]LogWindows:Error: ntdll.dll!0x000000005B780D61
[2017.05.13-19.34.17:850][796]LogWindows:Error: ntdll.dll!0x000000005B780D61
[2017.05.13-19.34.17:850][796]LogWindows:Error: 
[2017.05.13-19.34.17:864][796]LogExit: Executing StaticShutdownAfterError
[2017.05.13-19.34.17:866][796]LogWindows: FPlatformMisc::RequestExit(1)
[2017.05.13-19.34.17:866][796]Log file closed, 05/13/17 21:34:17

Note: I've compiled UnrealCS with engine 4.15.2 from source.

Custom structure

Is it possible to return a custom structure from a c# function and use it in blueprints with the break structure node ?

LogMono:Warning: Can't find devenv.exe

当我下载4.15分支并自己手动编译,作为工程插件时,我打开项目点击File-UnrealCS下的OpenProject,在log屏幕提示LogMono:Warning: Can't find devenv.exe。 请问这是怎么回事呢?我是否需要自己主动修改源码?

Using extension methods crashes the editor

Example of an extension method that crashes the editor:

namespace Game
{
    static class ExampleExtensions
    {
        public static int test(this Enum enum1)
        {
            return 1;
        }
    }
}

Log output:

Fatal error: [File:E:\unrealcs_v4.14.3_v1.0\HostProject\Plugins\UnrealCS\Source\MonoPlugin\Private\MonoDomain.cpp] [Line: 211] 
* Assertion: should not be reached at ..\mono\metadata\loader.c:299



KERNELBASE
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_MonoPlugin!MonoLog() [e:\unrealcs_v4.14.3_v1.0\hostproject\plugins\unrealcs\source\monoplugin\private\monodomain.cpp:211]
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
monosgen_2_0
UE4Editor_MonoPlugin!FMonoDomain::NativeHotReload() [e:\unrealcs_v4.14.3_v1.0\hostproject\plugins\unrealcs\source\monoplugin\private\monodomain.cpp:611]
UE4Editor_MonoPlugin!FMonoDomain::HotReload() [e:\unrealcs_v4.14.3_v1.0\hostproject\plugins\unrealcs\source\monoplugin\private\monodomain.cpp:690]
UE4Editor_MonoPlugin!FMonoDomain::Tick() [e:\unrealcs_v4.14.3_v1.0\hostproject\plugins\unrealcs\source\monoplugin\private\monodomain.cpp:750]
UE4Editor_Engine
UE4Editor_UnrealEd
UE4Editor_UnrealEd
UE4Editor
UE4Editor
UE4Editor
UE4Editor
UE4Editor
kernel32
ntdll

custom UObject class crashes UE

Hi, thank you for you plugin, looks very promising.
Nevertheless, I was faced with difficulties.
When I added to TestClass.cs next code

public class MyTestComponent : UMonoActorComponent
{
    public string text = "text";
}

all works fine, but the folowing code crashes UE

public class MyTestObject : UObject
{
    public string text = "text";
}

What am I doing wrong?

fatal error C1083: 无法打开包括文件: “Engine/SubDSurface.h”: No such file or directory

引擎版本:4.16.2
使用"D:\UE_4.16\Engine\Build\BatchFiles\RunUAT.bat" BuildPlugin -Plugin=D:\UnrealCS\UnrealCS.uplugin -Package=D:\Package -Rocket命令编译插件时报错
错误详细:
UnrealBuildTool: 正在创建库 D:\Package\HostProject\Plugins\UnrealCS\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-MonoHelper.suppressed.lib 和对象 D:\Package\HostProject\Plugins\UnrealCS\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-MonoHelper.suppressed.exp
UnrealBuildTool: D:\Package\HostProject\Plugins\UnrealCS\Source\MonoPlugin\Public\Headers_Engine.h(100): fatal error C1083: 无法打开包括文件: “Engine/SubDSurface.h”: No such file or directory
UnrealBuildTool: D:\Package\HostProject\Plugins\UnrealCS\Source\MonoPlugin\Public\Headers_Engine.h(100): fatal error C1083: 无法打开包括文件: “Engine/SubDSurface.h”: No such file or directory
UnrealBuildTool: ERROR: UBT ERROR: Failed to produce item: D:\Package\HostProject\Plugins\UnrealCS\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-MonoPlugin.lib
UnrealBuildTool: Total build time: 50.10 seconds (Local executor: 0.00 seconds)

看起来好像时环境变量或者Engine的Include路径没找到的问题

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.