Giter Club home page Giter Club logo

maca134.arma.dllexport's Introduction

Maca134.Arma.DllExport - Download

Simplify C# extensions for ARMA

PM> Install-Package Maca134.Arma.DllExport

Demo

public class SomeClass
{
    [ArmaDllExport]
    public static string Invoke(string input, int size)
    {
        return input;
    }
}

maca134.arma.dllexport's People

Contributors

maca134 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

maca134.arma.dllexport's Issues

[Question] How to get Arma 3 Folder

I think ArmA is using PInvoke, right? If so which folder is being used for relative paths? And if it's not the folder containing "arma3.exe", which one is it instead and how to navigate to the game folder from there?

How it works?

After reading this tutorial (https://forums.bistudio.com/forums/topic/210259-arma-dllexport-c-extensions/) I tried this but I don't figure out how it works on Arma3 once .dll is loaded. If I have this code:

using Maca134.Arma.DllExport;

namespace A3Extension
{
    public class DllEntry
    {
        [ArmaDllExport]
        public static string Invoke(string input, int size)
        {
            return input;
        }
    }
}

I executed this command from the EDC on Arma A3Extension callExtension "Invoke" but nothing happens... also A3Extension callExtension ["Invoke", ["Hello"]] but the same result.

Any advice?

Could not find file '\Arma 3\Mods\@My Mod\My Mod.dll.il'.

Why does it need IL code anyway?

Severity	Code	Description	Project	File	Line	Suppression State
Error		The "ArmaDllExportTask" task failed unexpectedly.
System.IO.FileNotFoundException: Could not find file 'S:\Steam\steamapps\common\Arma 3\Mods\@AIO_SPPack_GIT\All-In-One AI Command Menu.dll.il'.
File name: 'S:\Steam\steamapps\common\Arma 3\Mods\@AIO_SPPack_GIT\All-In-One AI Command Menu.dll.il'

Server stack trace: 
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.StreamReader..ctor(String path, Encoding encoding, Boolean detectEncodingFromByteOrderMarks, Int32 bufferSize, Boolean checkHost)
   at System.IO.StreamReader..ctor(String path, Encoding encoding)
   at System.IO.File.InternalReadAllLines(String path, Encoding encoding)
   at System.IO.File.ReadAllLines(String path)
   at Maca134.Arma.DllExport.MsBuild.DllExporter.IlParser(String ilIn) in U:\Projects\ARMA\C# Projects\Maca134.Arma.DllExport\Maca134.Arma.DllExport.MsBuild\DllExporter.cs:line 235
   at Maca134.Arma.DllExport.MsBuild.DllExporter.Export() in U:\Projects\ARMA\C# Projects\Maca134.Arma.DllExport\Maca134.Arma.DllExport.MsBuild\DllExporter.cs:line 98
   at Maca134.Arma.DllExport.MsBuild.ArmaDllExportTask.Execute() in U:\Projects\ARMA\C# Projects\Maca134.Arma.DllExport\Maca134.Arma.DllExport.MsBuild\DllExportTask.cs:line 55
   at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Object[]& outArgs)
   at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg)

Exception rethrown at [0]: 
   at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
   at Microsoft.Build.Framework.ITask.Execute()
   at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
   at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__26.MoveNext()	All-In-One AI Command Menu

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.