Hola, esta es un modulo para lua muy simple que usa Skype4COM, es un ejemplo de interoperabilidad con estos objetos.

El plugin consta de la función Join donde debemos usar como argumento una funcion que procesara los mensajes recibidos, tambien tiene la funcion Send(usuario, mensaje) para enviar. Muy simple y facil para aprender y crear bots. en este caso !date responderá con la hora y fecha actual.
Como nota, al iniciarlo debeis permitir en el skype que se conecte pulsando en Permitir acceso

Source:
DESCARGA

El plugin consta de la función Join donde debemos usar como argumento una funcion que procesara los mensajes recibidos, tambien tiene la funcion Send(usuario, mensaje) para enviar. Muy simple y facil para aprender y crear bots. en este caso !date responderá con la hora y fecha actual.
require("Skype4Lua")
Skype.Join(function(handle, msg)
Paragraph.SetText("Paragraph1", "<"..handle.."> "..msg.."\n"..Paragraph.GetText("Paragraph1"));
if msg=="!time" then
Skype.Send(handle, os.date())
end
end)

Source:
using LuaVM.Utilities.Lua;
using RGiesecke.DllExport;
using System;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Text;
namespace Skype4Lua
{
public class Skype
{
private static SKYPE4COMLib.Skype skype;
public static IntPtr L;
[DllExport(CallingConvention = CallingConvention.Cdecl)]
public static int luaopen_Skype4Lua(IntPtr ls)
{
Lua.register_lua_function(ls, "Skype", "Join", (Lua.LuaFunction)lua_skype_join);
Lua.register_lua_function(ls, "Skype", "Send", (Lua.LuaFunction)lua_skype_send);
return 1;
}
public static int lua_skype_join (IntPtr ls)
{
L = ls;
Lua.lua_tocfunction(ls, 1);
Lua.lua_setglobal(L, "skyp3n0t1f");
skype = new SKYPE4COMLib.Skype();
skype.Attach(7, false);
skype.MessageStatus += new SKYPE4COMLib._ISkypeEvents_MessageStatusEventHandler(skype_MessageStatus);
return 0;
}
public static int lua_skype_send(IntPtr ls)
{
skype.SendMessage(Lua.lua_tostring(ls, 1), Lua.lua_tostring(ls, 2));
return 0;
}
private static void skype_MessageStatus(SKYPE4COMLib.ChatMessage pMessage, SKYPE4COMLib.TChatMessageStatus Status)
{
Lua.lua_getglobal(L, "skyp3n0t1f");
Lua.lua_pushstring(L, pMessage.FromHandle);
Lua.lua_pushstring(L, pMessage.Body);
Lua.lua_call(L, 2, 0);
}
}
}
DESCARGA