How to make 4 digit brass number lock

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
User avatar
luat1995
Newbie
Posts: 24
Joined: Mon Nov 07, 2016 8:27 am
Completed: Home Alone
Github: https://github.com/luatsenpai
itch: https://luatsenpai.i
Location: vietnamese
Contact:

How to make 4 digit brass number lock

#1 Post by luat1995 »

Hello all
I want make 4 digit brass number lock like
Image and how to make this?
Sorry my bad english, thank :mrgreen:

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3785
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: How to make 4 digit brass number lock

#2 Post by Imperf3kt »

I'm not able to give you a code example right now, but I suggest two screens, one with your lock image and the numbers as imagebuttons, which, when clicked, calls the other screen (with kwargs to tell it which number you clicked on)
The opened screen would use renpy.input to set a variable or probably a dictionary
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

philat
Eileen-Class Veteran
Posts: 1900
Joined: Wed Dec 04, 2013 12:33 pm
Contact:

Re: How to make 4 digit brass number lock

#3 Post by philat »

The mechanics of the lock are simple. Have some buttons set a variable for each digit, check the answer. How it should be presented is too varied for anyone to help you effectively.

User avatar
Andredron
Miko-Class Veteran
Posts: 700
Joined: Thu Dec 28, 2017 2:37 pm
Location: Russia
Contact:

Re: How to make 4 digit brass number lock

#4 Post by Andredron »

luat1995 wrote: Mon Sep 17, 2018 8:51 pm Hello all
I want make 4 digit brass number lock like
Image and how to make this?
Sorry my bad english, thank :mrgreen:


Resurse download https://yadi.sk/d/nmggciTI3TtpWw

User avatar
Showsni
Miko-Class Veteran
Posts: 563
Joined: Tue Jul 24, 2007 12:58 pm
Contact:

Re: How to make 4 digit brass number lock

#5 Post by Showsni »

You don't want to make one like that, Master Lock are well known for being terrible quality :P
https://www.youtube.com/watch?v=bfDPtt-bnAI

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Bing [Bot], Kocker, Semrush [Bot]