Way to make the analog clock pretty?
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.
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.
- justloveme94
- Newbie
- Posts: 20
- Joined: Sat Nov 18, 2017 11:07 pm
- Contact:
Way to make the analog clock pretty?
Hello everyone,
I am very new to Ren'Py and coding in general. I am currently just messing around with the system at the moment. I stumbled upon the analog clock and I followed the tutorial on the wiki and it worked. My only compliant is that it is a bit of eye sore. I was hoping to insert a clock with a transparent background. One that would just sit on top of the background. Any help would be appreciated.
I am very new to Ren'Py and coding in general. I am currently just messing around with the system at the moment. I stumbled upon the analog clock and I followed the tutorial on the wiki and it worked. My only compliant is that it is a bit of eye sore. I was hoping to insert a clock with a transparent background. One that would just sit on top of the background. Any help would be appreciated.
- mitoky
- Veteran
- Posts: 316
- Joined: Sat Feb 07, 2015 9:12 pm
- Projects: The Purring Demon's Love, circus eterie
- Contact:
Re: Way to make the analog clock pretty?
For it to be transparent, you have to delete the black part in an art programm and then safe it as png file.
- justloveme94
- Newbie
- Posts: 20
- Joined: Sat Nov 18, 2017 11:07 pm
- Contact:
Re: Way to make the analog clock pretty?
Ah yes, I did think of that! Unfortunately, I went into Gimp and noticed that the clock face already had a transparent background.
- mitoky
- Veteran
- Posts: 316
- Joined: Sat Feb 07, 2015 9:12 pm
- Projects: The Purring Demon's Love, circus eterie
- Contact:
Re: Way to make the analog clock pretty?
So the images are transparent but it doenst appears transparent in renpy or the images arent transparent? (Please excuse, i am a bit confused)
- trooper6
- Lemma-Class Veteran
- Posts: 3712
- Joined: Sat Jul 09, 2011 10:33 pm
- Projects: A Close Shave
- Location: Medford, MA
- Contact:
Re: Way to make the analog clock pretty?
I assume you are using the old code from the wiki that is no longer supported. How are you adding that clock to the game? Also, you might want to check out my Clock tutorial which is linked in my signature.
A Close Shave:
*Last Thing Done (Aug 17): Finished coding emotions and camera for 4/10 main labels.
*Currently Doing: Coding of emotions and camera for the labels--On 5/10
*First Next thing to do: Code in all CG and special animation stuff
*Next Next thing to do: Set up film animation
*Other Thing to Do: Do SFX and Score (maybe think about eye blinks?) Check out My Clock Cookbook Recipe: http://lemmasoft.renai.us/forums/viewto ... 51&t=21978
*Last Thing Done (Aug 17): Finished coding emotions and camera for 4/10 main labels.
*Currently Doing: Coding of emotions and camera for the labels--On 5/10
*First Next thing to do: Code in all CG and special animation stuff
*Next Next thing to do: Set up film animation
*Other Thing to Do: Do SFX and Score (maybe think about eye blinks?) Check out My Clock Cookbook Recipe: http://lemmasoft.renai.us/forums/viewto ... 51&t=21978
- justloveme94
- Newbie
- Posts: 20
- Joined: Sat Nov 18, 2017 11:07 pm
- Contact:
Re: Way to make the analog clock pretty?
Yes, I was using the wikia! I couldn't find a more recent post but I guess I wasn't looking hard enough! Thank you very much. I will definitely check out the link in your sig and give it a try.
- Scribbles
- Miko-Class Veteran
- Posts: 636
- Joined: Wed Sep 21, 2016 4:15 pm
- Completed: Pinewood Island, As We Know It
- Projects: In Blood
- Organization: Jaime Scribbles Games
- Deviantart: breakfastdoodles
- itch: scribbles
- Location: Ohio
- Contact:
Re: Way to make the analog clock pretty?
it looks like your clock is inside of a frame, so you can either change the frame to be transparent in GUI, or change the type of frame in the code for that screen? If you post the code you used, maybe we can help better (between [ code ] [ /code ] tags)
https://www.renpy.org/doc/html/screens.html
https://www.renpy.org/doc/html/screens.html
- justloveme94
- Newbie
- Posts: 20
- Joined: Sat Nov 18, 2017 11:07 pm
- Contact:
Re: Way to make the analog clock pretty?
I tried using the other instructions that were provided in the signature but unfortunately it is still coming up the same, even with the different code. The clock image is still the same from the wikia.
Code: Select all
image clock = "clock.png" # Short Clockhand
image clock_1 = "clock_1.png" # Long Clockhand
image clock_2 = "clock_2.png" # Clockface
image bg Fates Background = "bg Fates Background.png"
init:
$ minutes = 540
transform rotateshort:
xanchor 0.5
yanchor 0.5
xalign 0.5
yalign 0.5
rotate (minutes*6)
transform rotatelong:
xanchor 0.5
yanchor 0.5
xalign 0.5
yalign 0.5
rotate (minutes*0.5)
transform alpha_dissolve:
alpha 0.0
linear 0.5 alpha 1.0
on hide:
linear 0.5 alpha 0
# This is to fade in the clock.
screen clock:
frame at alpha_dissolve:
xmaximum 250 # X size of clock graphic
ymaximum 250 # Y size of clock graphic
xalign 0.99 # X placement on screen
yalign 0.02 # Y placement on screen
add "clock_2"
add "clock_1" at rotatelong
add "clock" at rotateshort
label start:
scene bg Fates Background
show screen clock
"It is already 9:00AM."
"He is very late."
"But he is my friend so I will wait."
$ minutes += 2
"Two minutes has passed."
$ minutes += 2
"Four minutes has passed."
$ minutes += 2
"Six minutes has passed."
"HE IS LATE! I KILL HIM!"
hide screen clock
- Imperf3kt
- Lemma-Class Veteran
- Posts: 3794
- Joined: Mon Dec 14, 2015 5:05 am
- itch: Imperf3kt
- Location: Your monitor
- Contact:
Re: Way to make the analog clock pretty?
Try adding alpha True to your frame (not alpha = True) within the clock screen
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
pro·gram·mer (noun) An organism capable of converting caffeine into code.
Current project: GGD Mentor
Who is online
Users browsing this forum: alyoshaslab