This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2011-05-09 18:58:21

gbear605
Scratcher
Registered: 2008-03-06
Posts: 1000+

Password lock

Hi all, I want to have a password lock for the developer menu, like in Bingo.  Any help would be appreciated.  I want to incorporate this in Scraft.

If anyone helps they will get credit in Scraft, and lots of thanks.  tongue

EDIT: 900th post!

Last edited by gbear605 (2011-05-09 19:02:04)


Yeah, I'm mostly inactive.  I check in once in a while though.  If you want to contact me, I have a contact form at my website, http://escratch.org

Offline

 

#2 2011-05-10 02:43:59

scimonster
Community Moderator
Registered: 2010-06-13
Posts: 1000+

Re: Password lock

I'm sure LS97 knows.  tongue

Offline

 

#4 2011-05-10 12:35:09

johnnydean1
Scratcher
Registered: 2010-02-12
Posts: 1000+

Re: Password lock

Just do.

enterPass: Pass
Pass = 'password'
ifTrue: [
open menu code
].


You can now reach me on Twitter @johnnydean1_

Offline

 

#5 2011-05-10 13:21:06

LS97
Scratcher
Registered: 2009-06-14
Posts: 1000+

Re: Password lock

you'll have to get the value from a dialog and check if it's correct.

declare 'res' first.

res _ StringDialog ask: 'Enter Password'.
(res = 'password') ifFalse: [^ self beep].

add that code just after adding all of the menu items, and it should work!  smile

Offline

 

#6 2011-05-10 14:45:13

gbear605
Scratcher
Registered: 2008-03-06
Posts: 1000+

Re: Password lock

Thanks to both of you, it works  big_smile


Yeah, I'm mostly inactive.  I check in once in a while though.  If you want to contact me, I have a contact form at my website, http://escratch.org

Offline

 

#7 2011-05-12 15:25:08

johnnydean1
Scratcher
Registered: 2010-02-12
Posts: 1000+

Re: Password lock

Remember you have to leave your mod open source. So you must give the pass out to people,


You can now reach me on Twitter @johnnydean1_

Offline

 

Board footer