Problem with "Click a model to earn badge."

Hey, I been trying to make a click to earn badge, but I am having trouble. I’m not the best at lua, and I used my knowledge that I have so far to make this.


When I went in game It did not work for me. I looked all over the dev forum on this, and then I went to the output to check the error. It said “Unable to cast Instance to int64.” I have no idea what this is so I searched it up, but it didn’t help. So if anyone can help me out here that would be great.

two problems:


remove the parenthesis around the id.


Modify your code so the function looks like this:

    print("Mouse Clicked!")
1 Like

which line of code is the id you are referring to?

the 3rd line; where the variable is defined

Thanks for the help! I’m going to test it out right now!


Use a Capital i, might work maybe


Wow, it worked. Cool, thanks too!