Ok, so I initiazlied in the main.lua all the open feint stuff I need. And then in the menu system I did what I had to do.
However, when the player wins the game, and gets the winLose function. I want to unlock the achievement.
I’m not requiring OpenFeint so far, and only have this little bit of code. Is this gonna suffice?
Or do I have to do, Local require openfeint = (“openfeint”)
and then put the coding in the winLose function?
Let me know. Take a look at this coding, and let me know what you think.
local function winLose(condition)
if(condition == "win") then
display\_txt.text = "WIN!";
win.isVisible = true
win.isBodyActive = true
openfeint.unlockAchievement ( 842812 )
[import]uid: 19768 topic_id: 7230 reply_id: 307230[/import]
[import]uid: 19768 topic_id: 7230 reply_id: 25438[/import]