home *** CD-ROM | disk | FTP | other *** search
AMOS Source Code | 1993-03-07 | 2.0 KB | 110 lines |
- '
- '******************************
- '
- ' Enter
- ' Password Procedure v1.1
- '
- ' By Malcolm Lavery 1993
- '
- '******************************
- '
- '
- Screen Open 0,320,256,32,Lowres
- Curs Off
- Cls 0
- Flash Off
- Palette $0,$FFF,$F00
- '
- Pen 1 : Paper 0
- Ink 1,0
- Text 90,100,"Enter Password"
- '
- '
- PASSWORD
- '
- '
- Procedure PASSWORD
- '
- '**********************************
- ' Reset Variables
- '**********************************
- '
- PASSWORD$=""
- LEV=0
- Restore
- '
- '*********************************
- ' Enter Password
- '*********************************
- '
- Locate 11,14
- Line Input PASSWORD$;
- '
- '*********************************
- ' Search for password
- ' and find its level number
- '*********************************
- '
- '*********************************
- 'Increase loop for more passwords
- '*********************************
- '
- For POS=1 To 5
- '
- Read SECRET$
- If PASSWORD$=SECRET$
- LEV=POS
- Goto MISS
- End If
- Next POS
- '
- '********************************
- ' Invaled password entry
- '********************************
- '
- Locate 10,16
- Print "Hacker at system"
- '
- DI=1
- PITCH=50
- Shift Up 5,1,2,1
- '
- For TIMES=1 To 100
- '
- If PITCH>55
- DI=-1
- End If
- If PITCH<50
- DI=1
- End If
- Add PITCH,DI
- Play PITCH,1
-
- Next TIMES
- '
- Shift Off
- Locate 10,16
- Print " "
- Pop Proc
- '
- '*************************************
- ' Display password level
- ' And return value back to main loop
- '*************************************
- '
- MISS:
- '
- Locate 10,16
- Print "Access to Level "+Str$(LEV);
- '
- Pop Proc
- '
- '*************************************
- ' Level passwords
- ' Add as many as you want
- ' But adjust search 'For/Next loop'
- '*************************************
- '
- Data "easy","simple","harder","hard","veryhard"
- '
- End Proc