I am fairly new to classes in programming and I had made this method in my experimental class:
function Ground:setBlock(block)
– Codea does not automatically call this method
print(block)
end
In the main class, I call this:
Ground.setBlock(“Dirt”)
In my console, it prints a nil value. Why is this? Do I have to assign the block Parameter to a local variable?