local owl = require "owl" -- create a new class local Dog = owl.class{ name="DogClass", image="dog.png", width="100", height="100"} function Dog:init( params ) local params = params or {} for k,v in pairs( params ) do self[k] = v end self.params = params end local params = { name = "rox", size = "medium", jump\_false = false, jump\_true = true } --create a new instance of "DogClass" local black\_dog = owl.instance{ from=Dog, id = "black\_dog", params = params } print(black\_dog.name, black\_dog.jump\_false, black\_dog.jump\_true, "boolean") Output : rox nil true boolean
My code is pretty simple because I’m testing this new library:Owl made by jonbeebe, you can find it code here: https://github.com/pickerel/owl/blob/master/owl.lua
Even with his sample, when I print a boolean value from an instance, it return me nil excepted when I use the proxy( property_call_back ). to update value but if I don’t want to use it , I’m stuck…
So the problem come from the library, I’m still looking through it to find out why this happen but it’s hard.
thanks to your help