Some of yall might have been gorillaz fans or visited the site when it was an interactive tour around the studio. If not, here is a link that shows sort of what it looked like. http://youtu.be/pmAo_POMRHY
I want to replicate that, where you have a room to look around and you can click on doors or items to progress(jump to a label, add item to inventory, etc. I don't need an explanation for that part). I've found this http://lemmasoft.renai.us/forums/viewto ... =8&t=23438 but I'm still not entirely sure what I'm doing orz i guess I want imagebuttons? And for them to disappear off screen when you scroll one way?
Thank you in advance for any help you can offer!
Look around parralax w/ clickable background
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.
- Abuelitaland
- Regular
- Posts: 135
- Joined: Fri Jun 07, 2013 9:12 pm
- Projects: Ways To The Grave(18+/Gore), Pantyline(18+)
- Tumblr: sketchyland
- Location: U.S.
- Contact:
- ketskari
- Veteran
- Posts: 296
- Joined: Tue Dec 21, 2010 6:22 pm
- Completed: Asher, Sunrise, Tell a Demon
- Projects: Asher Remake, TEoA
- Organization: Sun Labyrinth
- Tumblr: sunlabyrinth
- Deviantart: sunlabyrinth
- itch: sunlabyrinth
- Contact:
Re: Look around parralax w/ clickable background
I think you want to look at edgescroll and viewports:
http://www.renpy.org/doc/html/screens.html#viewport
So you'd make a screen and add an imagemap or imagebuttons into your viewport.
This thread solves/mentions the problem of getting a map with multiple imagebuttons working (which is similar to what you are doing):
http://lemmasoft.renai.us/forums/viewto ... 4&p=298872
http://www.renpy.org/doc/html/screens.html#viewport
So you'd make a screen and add an imagemap or imagebuttons into your viewport.
This thread solves/mentions the problem of getting a map with multiple imagebuttons working (which is similar to what you are doing):
http://lemmasoft.renai.us/forums/viewto ... 4&p=298872
- Abuelitaland
- Regular
- Posts: 135
- Joined: Fri Jun 07, 2013 9:12 pm
- Projects: Ways To The Grave(18+/Gore), Pantyline(18+)
- Tumblr: sketchyland
- Location: U.S.
- Contact:
Re: Look around parralax w/ clickable background
ketskari wrote:I think you want to look at edgescroll and viewports:
http://www.renpy.org/doc/html/screens.html#viewport
So you'd make a screen and add an imagemap or imagebuttons into your viewport.
This thread solves/mentions the problem of getting a map with multiple imagebuttons working (which is similar to what you are doing):
http://lemmasoft.renai.us/forums/viewto ... 4&p=298872
Hi sorry to have to come back and ask again. I read the links you posted but I'm still confused on how to add the imagemap/ imagebuttons?
for example if I'm trying with an imagemap...
Code: Select all
$ imagemapa = renpy.imagemap("ground.png", "selected.png", [
(100, 100, 300, 400, "a"),
(500, 100, 700, 400, "b")
])
if imagemapa == "a":
jump aresult
elif imagemapa == "b":
jump bresult
screen viewport1:
viewport:
xpos 0.00
ypos 0.00
xmaximum 1366
ymaximum 768
draggable True
mousewheel True
edgescroll (100, 400,)
child_size (8830, 1168)
add "testspr.png" #room image
add imagemapa #clickable item imagemap???
- ketskari
- Veteran
- Posts: 296
- Joined: Tue Dec 21, 2010 6:22 pm
- Completed: Asher, Sunrise, Tell a Demon
- Projects: Asher Remake, TEoA
- Organization: Sun Labyrinth
- Tumblr: sunlabyrinth
- Deviantart: sunlabyrinth
- itch: sunlabyrinth
- Contact:
Re: Look around parralax w/ clickable background
Did you try it and it didn't work? Anyway, I made a little test game and got it to work like this:
I also tried out imagebuttons:
Hope that helps.
Code: Select all
screen viewport1:
viewport:
xpos 0.0
ypos 0.0
edgescroll (100, 400)
draggable True
child_size (8830, 1168)
imagemap:
ground "ground.png" hover "selected.png"
hotspot (100, 100, 300, 400) clicked Jump("aresult")
hotspot (500, 100, 700, 400) clicked Jump("bresult")
Code: Select all
viewport:
xpos 0.0
ypos 0.0
edgescroll (100, 400)
draggable True
child_size (8830, 1168)
add "ground.jpg"
imagebutton idle "imagebutton1.png" hover "imagebutton1_hover.png" xalign .5 yalign .2 focus_mask True action Jump("aresult")
imagebutton idle "imagebutton2.png" hover "imagebutton2_hover.png" xalign .5 yalign .75 focus_mask True action Jump("bresult")
- Abuelitaland
- Regular
- Posts: 135
- Joined: Fri Jun 07, 2013 9:12 pm
- Projects: Ways To The Grave(18+/Gore), Pantyline(18+)
- Tumblr: sketchyland
- Location: U.S.
- Contact:
Re: Look around parralax w/ clickable background
THANK YOU!!!! That is exactly perfect. <3ketskari wrote:Did you try it and it didn't work? Anyway, I made a little test game and got it to work like this:I also tried out imagebuttons:Code: Select all
screen viewport1: viewport: xpos 0.0 ypos 0.0 edgescroll (100, 400) draggable True child_size (8830, 1168) imagemap: ground "ground.png" hover "selected.png" hotspot (100, 100, 300, 400) clicked Jump("aresult") hotspot (500, 100, 700, 400) clicked Jump("bresult")
Hope that helps.Code: Select all
viewport: xpos 0.0 ypos 0.0 edgescroll (100, 400) draggable True child_size (8830, 1168) add "ground.jpg" imagebutton idle "imagebutton1.png" hover "imagebutton1_hover.png" xalign .5 yalign .2 focus_mask True action Jump("aresult") imagebutton idle "imagebutton2.png" hover "imagebutton2_hover.png" xalign .5 yalign .75 focus_mask True action Jump("bresult")
Who is online
Users browsing this forum: Dark79, Google [Bot], Majestic-12 [Bot]