Finished product will look like this; (mouse hovered over first one) things you need to have in your folder before hand:
-ground image for imagemap (purple above)
-idle image for imagemap (black above
-hover image for imagemap (white above)
Here's the code in script:
Code: Select all
label start:
#these are your points, rename them to what you are selecting! you van have as many of these as you'd like
$malePoints = 0
$femalePoints = 0
screen characterselectscreen:
imagemap:
#these are your images
ground "sprite ground"
idle "sprite idle"
hover "sprite hover"
#these are your hotspots, alter them to fit your screen and however you want it to look. Add one every time you create a new point.
hotspot (1310, 0, 567, 1080) action SetVariable("malePoints", malePoints + 1), Return()
hotspot (687, 0, 595, 1080) action SetVariable("femalePoints", femalePoints + 1), Return()
label chrsel:
"Narrator" "Choose your character"
$ renpy.call_screen("characterselectscreen")
if malePoints ==1:
"Boy" "I am a boy"
#this onward is for names, you don't need to have this in your game at all, it's just after character selection for me.
$ player_name = renpy.input("My name is...")
$ player_name = player_name.strip()
#this is if a player leaves their name as blank.
if player_name == "":
$ player_name="MC male"
if femalePoints == 1:
"girl" "I am a girl"
#this onward is for names, you don't need to have this in your game at all, it's just after character selection for me.
$ player_name = renpy.input("My name is...")
$ player_name = player_name.strip()
#this is if a player leaves their name as blank
if player_name == "":
$ player_name="MC female"
"narrator" "that was the end of character selection screen, %(player_name)s."
# This ends the game.
return