Just started relearning AS2 for Flash today and I have been wanting to make a Escape from Monkey Island type game. I am trying to make my own little look and use buttons (Ex. Hand icon picks things up and glasses looks at things). I want to be able to click a button to change the cursor and then press another button to display another cursor. This is what I have so far. The controls would be simple. Click the button you want to use and it will ethier look or use what you click. I have put down a small amount of code and have been tweeking it for the past few hours. I have looked at multible guides and they only help a little bit.
Here is the code on the frame
_global.Look=0
_global.Use=0
if(_global.Use=1)
{
cursor_sc.startDrag(true);
Mouse.hide();
}
if(_global.Look=1)
{
cursor_mc.startDrag(true);
Mouse.hide();
}
And this is the code for the glasses button
on(press)
{
if(_global.Look=0)
{
_global.Look=1
_global.Use=0
}
}
and finally the hand box code
on(press)
{
if(_global.Use=0)
{
_global.Use=1
_global.Look=0
}
}
Something tells me I am forgeting something that will make me feel dumb. Anyways Thanks for viewing and please contact me if you find out what is wrong.