all repos — Legends-RPG @ 9c32963e4fe38f8522d954c3697c4f05829b5a19

A fantasy mini-RPG built with Python and Pygame.

data/components/portal.py (view raw)

 1__author__ = 'justinarmstrong'
 2import pygame as pg
 3from .. import constants as c
 4
 5
 6class Portal(pg.sprite.Sprite):
 7    """Used to change level state"""
 8    def __init__(self, x, y, name):
 9        super(Portal, self).__init__()
10        self.image = pg.Surface((32, 32))
11        self.image.fill(c.BLACK)
12        self.rect = pg.Rect(x, y, 32, 32)
13        self.name = name