Latest Version: 1.4.2
Pylash
is a game engine for python
which imitates some classes and functions in flash
. We develop pylash
with Python3
and the GUI engine of pylash
is PyQt4
. Many classes which are almost from flash
such as Sprite
, BitmapData
, Bitmap
, TextField
, Loader
and Graphics
will be found in pylash
.
We use MIT License, which is a free and friendly license. Besides, you must follow the license of PyQt4
as well, because pylash
is based on it.
With Git:
Input this command in Git Bash
to clone pylash
:
git clone git@github.com:yuehaowang/pylash_engine.git
Without Git:
The url to download the engine is:
https://github.com/yuehaowang/pylash_engine/archive/master.zip
For pylash
is based on Python3
and PyQt4
, you need to install them first.
Python3 will be found here:
PyQt4 will be found here:
https://riverbankcomputing.com/software/pyqt/intro
If you find the library has some bugs or that you have any questions or advice, please let us know:
My email: wangyuehao1999@gmail.com
My twitter: https://twitter.com/yuehaowang
Bugs can be submited into Github Issues too.
- Find Character
- Get Fruits
- Tower Defense
- Overview of Pylash
- A Simple Program: Hello World
- Load and Display An Image
- Sprite and Mouse Event
- Create Vector Graphics
Documentation comes soon...
Release Date: 1/22/2017
Bugfix: cannot load and play music on Ubuntu.
Release Date: 3/13/2016
- Added
globalToLocal
method inDisplayObject
class to get a point's position which is relative to the global coordinate. - Added
localToGlobal
method inDisplayObject
class to get a point's position which is relative to the local coordinate of display object. - Added
Matrix
class ingeom
module to create a matrix used for transforming coordinate. - Added
Transform
class ingeom
module andtransform
property inDisplayObject
. With them, you can transform display object arbitrarily.
Release Date: 2/7/2016
- Enhancement: you can set
width
&height
property ofDisplayObject
to limit the size of display object. - Added
Sound
class inmedia
module to play music. - Enhancement: using
LoadManage.load
, you can load music. - Improvement:
LoadManage
used to usethreading.thread
to create a thread, now it useQThread
.
Release Date: 1/10/2016
- Added
LineEdit
class inui
module to create single-line input box. - Added
RankingSystem
insystem
module, which connect server and send requests to add/get ranking. - Added
RankingServer
innet
module, which is asocket
server used withRankingSystem
. - Bugfix: cannot use
onComplete
&onStart
&onUpdate
property inTweenLite
.
Release Date: 12/26/2015
- Added
ButtonSample
inui
module, which is used for creating a very simple button. Generally speaking, it's used for testing. - Added
StageWebView
inmedia
module to show some webpages in the window.
Release Date: 11/21/2015
- Added
draw
method inBitmapData
to draw a display object inBitmapData
object. - Improvement: change drawing
QImage
object into drawingQPixmap
object to make image rendering fast. - Added
setPixel
,getPixel
,setPixels
,getPixels
method inBitmapData
for pixel processing. - Added
lock
,unlock
method inBitmapData
for faster pixel processing when you process pixels many times at a time. - Added
Rectangle
class andPoint
class. - Bugfix: get wrong width/height of
Graphics
when usingmoveTo
method orlineTo
method. - Enhancement: support hex value when setting color.
Release Date: 11/8/2015
- Bugfix: some errors will be thrown when you give a
LinearGradientColor
/RadialGradientColor
/ConicalGradientColor
object tolineStyle
method ofGraphics
class as the second parameter. - Added
TweenLite
static class andTweenLiteChild
class to create some easing animations. - Added
Easing
static class to provide many easing methods forTweenLite
class. - Improvement: more detailed internal error hints.
- Bugfix: cannot use
Button.removeState
.
Release Date: 11/1/2015
- Added
Shape
class to create vector graphics. It's lighter thanSprite
when you just want to use vector graphics. - Enhancement: efficiency of mouse event.
Release Date: 10/7/2015
- Added some sample classes about loading page.
- Added
Button
class to create a simple button. - Added
LinearGradientColor
,RadialGradientColor
andConicalGradientColor
class to use gradient color. - Added
delay
property inLoadManage
class to set the delay time between loading a resource and loading the next resource in order to show loading page. - Added
useAntialiasing
property instage
in order to open/close antialiasing. - Bugfix:
onComplete
callback function will be called in the thread used for loading resources inLoadManage
. - Bugfix:
PyQt
will throw errors iftext
property ofTextField
is set to a value whose type is notstr
. - Added
mouseShelter
property inDisplayObjectContainer
to set whether stop propagating mouse events toDisplayObjectContainer
objects that are sheltered by other objects. - Bugfix:
selfY
in mouse event is wrong. - Enhancement: the
x
andy
property in parameter 'bitmapData' given into the constructor ofAnimation
class will be the origin position of the animation. - Added
AnimationSet
class to control a set of animations. - Added
MOUSE_OVER
andMOUSE_OUT
event.
Release Date: 9/20/2015
- Improvement: changed and added some methods in
Graphics
. - Added settings of
join style
,cap style
andmiter limit
inGraphics
.
Release Date: 9/12/2015
Create pylash
with display
, text
, system
, utils
and events
modules which include Sprite
, Bitmap
, Graphics
, Loader
, Stage
and more powerful classes.