Difference between revisions of "Iab"
From GiderosMobile
(Created page with "===== Code example: ===== local test = IAB.new("test") test:addEventListener(Event.AVAILABLE, function(e) --provide setup stuff (framework specific) test:setUp("value1", "v...") |
(No difference)
|
Revision as of 13:06, 7 March 2019
Code example:
local test = IAB.new("test")
test:addEventListener(Event.AVAILABLE, function(e) --provide setup stuff (framework specific) test:setUp("value1", "value2", "value3") test:purchase("product1") --purchase something end)
test:addEventListener(Event.PURCHASE_COMPLETE, function(e) --unlock your purchase here print(e.productId, e.receiptId) test:confirm(e.productId) end)
test:isAvailable() test:restore()