Advertisement
barsunduk

renpy cursor

Apr 13th, 2016
704
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.64 KB | None | 0 0
  1. init python:
  2.     # функция для смены курсора
  3.     # курсоры должны лежать в папке images
  4.     # формат имен фалов для курсоров:
  5.     # 'images/cursor_ИмяКурсора.png'
  6.     def cursor(name = None):
  7.         if name:
  8.             config.mouse = {'default' : [('images/cursor_' + name + '.png', 0, 0)]}
  9.         else:
  10.             config.mouse = None
  11.     # превращаем функцию в action,
  12.     # чтобы можно было привязать, например, к нажатию кнопок:
  13.     # action Cursor("finger")
  14.     Cursor = renpy.curry(cursor)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement