0

我正在尝试为我的小说制作地图。但是我遇到了热点在呼叫其他建筑物的问题,我有一个问题,是否可以以多边形的形式制作热点?这是我的代码和地图:

screen map:
    imagemap:
        ground 'images/maps/morning/morning_ground.png'
        idle 'images/maps/morning/morning_idle.png'
        hover 'images/maps/morning/morning_hover.png'

        hotspot (690, 70, 200, 185) action Return("university")
        hotspot (528, 100, 120, 90) action Return("my house")


label charapter1:

    scene black with dissolve
    "Oh, finally I woke up, I had such a terrible dream"
    'Must hurry, otherwise I will be late, we must look at the map'
    window hide None
    call screen map
    window show None
    if _return == 'university':
        'Damn, I'm still late'
        return
    if _return == 'my house':
        'Why did I come home?'
        return

图片:morning_hovermorning_idlemorning_ground

4

1 回答 1

0

看起来图像按钮是您正在寻找的更好的选择。

在任何软件中绘制您想要的多边形,然后使用以下代码:

imagebutton:
                idle the_button_you_drew.png
                hover (im.MatrixColor(the_button_you_drew.png, im.matrix.brightness(0.25)))
                action Jump("a_label_you_want")

它采用与您使用的图像相同的形状和大小。我建议该图像的背景是透明的。

于 2019-07-06T23:40:09.067 回答