I use a lot of creative commons material in my games, and i want to credit authors for it.
At the moment I'm struggling with screen language to do so.
I tried to create screens to display credits to show at the end of my game, but I have trouble with interacting with them.
What I want to do :
- when called, screen show an image + text according to arguments that are passed to the screen when calling it
- In the text there are hyperlinks, that open in a web browser when you click on them
- If you click anywhere else (or use space or whatever is usually used to go forward), you go the next screen
What I have done so far :
code put in screen.rpy
Code: Select all
screen credit(illu,texte):
# show the image "illu" on the left of the screen
add illu anchor (0.5,0.5) ypos 300 xpos 300
#show text "texte" on the right of the screen
vbox:
xpos 635
ypos 100
xsize 330
text texte
key "dismiss" action Return(True)In the main script I put that code
Code: Select all
label credits:
scene fond2 with fade
call screen credit("credits auteur","Histoire et textes : Korova\n\nsous licence\nCreative Commons\n{image=cc/Cc-by.png} {image=cc/Cc-sa.png} {a=http://creativecommons.org/licenses/by-sa/2.0/fr/} CC-BY-SA{/a}")My image and text appear on the screen where I want them.
My problem is :
- if I don't put the in screen.rpy code, my screen get stuck forever (and i have other screens to show...)
Code: Select all
key "dismiss" action Return(True) - if i put it,hen i try to click on the hyperlinks in my text, the game show the next screen, instead of opening the hyperlink in the webbrowser.
(Sorry if my explanations are not cristal clear, english is not my native language)