Upload
vinicius-jarina
View
1.384
Download
0
Embed Size (px)
DESCRIPTION
Citation preview
Scripting with NLua and Xamarin
domingo, 14 de abril de 13
Why scripting?
• Isolate behaviors/complex logic• Change behavior without rebuild• Allow customization/extension
domingo, 14 de abril de 13
[Preserve]
public class Scriptable { public Scriptable (string param) { // ... } public void DoSomething () { Console.WriteLine ("Do Something"); }}
01
02
03
04
05
06
07
08
09
10
11
12
13
14
15
16
domingo, 14 de abril de 13
public void ViewDidLoad (string param) { var lua = new Lua (); lua.DoString ("a = 10"); lua.DoFile (luaFile); } // ... } lua.Dispose (); // ... }}
local s = Scriptable ("Do Something")s:DoSomething ()
domingo, 14 de abril de 13
Thank you
• http://github.com/nlua/nlua• http://nlua.org• http://lua.org
domingo, 14 de abril de 13