HTML Tutorial


 /help/HTML Help Forum   FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
RegisterRegister - Not registered yet? Got something to say? Join HTML Code Tutorial!
Director Lingo, if anyone can help
Post new topic   Reply to topic    HTML Help Forum -> Others
View previous topic :: View next topic  
Author Message
bloodyknee



Joined: 22 Apr 2009
Posts: 18

PostPosted: Thu Apr 30, 2009 1:41 am     Director Lingo, if anyone can help Reply with quote

So I'm making a really basic sudoku game in director, not auto generated cells or anything, just a basic game where you have to input the right numbers and see if it is correct.
here is what it looks like:


Main area, 4 static text areas and 4 editable text areas (the ones with 0's).


The next screen at frame 6-10, just to let people know they won.

and here are the scripts:

Movie:
Code:
on startMovie
  sprite(11).visible = FALSE
end


Sprite 11 is a cross that should appear if you get the answer wrong when you click the button

Hold:
Code:
on exitFrame me
  go to the frame
end


Working fine as usual, placed at frame 5 and 10

Button:
Code:
global cell1
global cell4
global cell6
global cell7

on mouseUp me
  cell1 = member(1).value
  cell4 = member(4).value
  cell6 = member(6).value
  cell7 = member(7).value
  if (cell1 = 4 and cell4 = 3 and cell6 = 2 and cell7 = 1) then
    go to frame 6
  else
    sprite(11).visible = TRUE
  end if
end


This is what I can't get to work
even the sprite doesn't show up, as if it ignored the whole if statement

Please help if you can
kanenas



Joined: 14 Dec 2004
Posts: 352

PostPosted: Fri May 01, 2009 12:26 pm     Debugging Reply with quote

Have you tried using the debugger?
bloodyknee



Joined: 22 Apr 2009
Posts: 18

PostPosted: Fri May 01, 2009 8:34 pm     debugger Reply with quote

I've never really use debugger until now.
I can't seem to get it to start, either because it's a on mouseup event, or because there is no error, because it is a logical error, not a syntax error.
any other ideas?
kanenas



Joined: 14 Dec 2004
Posts: 352

PostPosted: Sat May 02, 2009 11:07 am     Breakpoints Reply with quote

Make sure you put the breakpoint on a line within the event handler, not on the "on mouseUp" line. The fact that it's a mouseUp event has no affect on the debugger. If the debugger still isn't stopping at the breakpoint, the line isn't being reached because either the handler isn't registering for the event or the event isn't firing (the latter seems unlikely).
Display posts from previous:   
Post new topic   Reply to topic    HTML Help Forum -> Others All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
HTML Help Archive
Powered by phpBB © 2001, 2005 phpBB Group
HTML Help topic RSS feed 

 
DARFUR
HOSTING / DESIGN

Home
  |   Tutorials   |   Forum   |   Quick List   |   Link Directory   |   About
Copyright ©1997-2002 Idocs and ©2002-2007 HTML Code Tutorial