// AUTOMATICALLY GENERATED, DO NOT EDIT
using System;
using System.Runtime.InteropServices;

namespace Creaturelib.Generated
{
    internal static class TypeLibrary
    {
        /// <param name="initialCapacity">long unsigned int</param>
        /// <returns>TypeLibrary *</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_Construct")]
        internal static extern IntPtr Construct(ulong initialCapacity);

        /// <param name="p">const TypeLibrary *</param>
        /// <returns>void</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_Destruct")]
        internal static extern void Destruct(IntPtr p);

        /// <param name="out">unsigned char &</param>
        /// <param name="p">const TypeLibrary *</param>
        /// <param name="type">const char *</param>
        /// <returns>unsigned char</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_GetTypeId")]
        internal static extern byte GetTypeId(ref byte @out, IntPtr p, IntPtr type);

        /// <param name="out">unsigned char &</param>
        /// <param name="p">TypeLibrary *</param>
        /// <param name="type">const char *</param>
        /// <returns>unsigned char</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_RegisterType")]
        internal static extern byte RegisterType(ref byte @out, IntPtr p, IntPtr type);

        /// <param name="p">TypeLibrary *</param>
        /// <param name="attacking">unsigned char</param>
        /// <param name="defensive">unsigned char</param>
        /// <param name="effectiveness">float</param>
        /// <returns>unsigned char</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_SetEffectiveness")]
        internal static extern byte SetEffectiveness(IntPtr p, byte attacking, byte defensive, float effectiveness);

        /// <param name="out">float &</param>
        /// <param name="p">TypeLibrary *</param>
        /// <param name="attacking">unsigned char</param>
        /// <param name="defensive">unsigned char</param>
        /// <returns>unsigned char</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_GetSingleEffectiveness")]
        internal static extern byte GetSingleEffectiveness(ref float @out, IntPtr p, byte attacking, byte defensive);

        /// <param name="out">float &</param>
        /// <param name="p">TypeLibrary *</param>
        /// <param name="attacking">unsigned char</param>
        /// <param name="defensive">unsigned char *</param>
        /// <param name="defensiveCount">long unsigned int</param>
        /// <returns>unsigned char</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_GetEffectiveness")]
        internal static extern byte GetEffectiveness(ref float @out, IntPtr p, byte attacking, IntPtr defensive, ulong defensiveCount);

        /// <param name="out">const char * &</param>
        /// <param name="p">TypeLibrary *</param>
        /// <param name="type">unsigned char</param>
        /// <returns>unsigned char</returns>
        [DllImport("libCreatureLib", CallingConvention = CallingConvention.Cdecl, EntryPoint= "CreatureLib_TypeLibrary_GetTypeName")]
        internal static extern byte GetTypeName(ref IntPtr @out, IntPtr p, byte type);

    }
}
