From 7ffe45c711632f06c5b26b10855d55707489b1e6 Mon Sep 17 00:00:00 2001 From: frank <420@shampoo.ooo> Date: Sat, 29 May 2021 20:50:14 -0400 Subject: [PATCH] added license --- LICENSE.txt | 17 ++++++++++++++++ README | 50 +++++++++++++++++++++-------------------------- pgfw/Animation.py | 6 ++---- 3 files changed, 41 insertions(+), 32 deletions(-) create mode 100644 LICENSE.txt diff --git a/LICENSE.txt b/LICENSE.txt new file mode 100644 index 0000000..550e193 --- /dev/null +++ b/LICENSE.txt @@ -0,0 +1,17 @@ +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +This permission notice shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README b/README index 91c0774..b6f7d7a 100644 --- a/README +++ b/README @@ -11,45 +11,39 @@ Example Save and run to create a project that redraws a square at a random location every second. This script is also written in the `sample.py` file. -from time import sleep -from random import randint + from time import sleep + from random import randint -from pgfw.Game import Game + from pgfw.Game import Game -class SampleGame(Game): + class SampleGame(Game): - square_width = 30 + square_width = 30 - # instructions in the update method automatically run once every frame - def update(self): - sleep(1) - screen = self.get_screen() - bounds = screen.get_size() - screen.fill((0, 0, 0)) - screen.fill((255, 255, 255), - (randint(0, bounds[0]), randint(0, bounds[1]), - self.square_width, self.square_width)) + # instructions in the update method automatically run once every frame + def update(self): + sleep(1) + screen = self.get_screen() + bounds = screen.get_size() + screen.fill((0, 0, 0)) + screen.fill((255, 255, 255), + (randint(0, bounds[0]), randint(0, bounds[1]), + self.square_width, self.square_width)) -if __name__ == '__main__': - SampleGame().run() + if __name__ == '__main__': + SampleGame().run() License ------- -This software is dedicated to the public domain. See -http://creativecommons.org/publicdomain/zero/1.0/ for details. +MIT License + +see LICENSE.txt for details -Todo ----- +Business +-------- -- Remove unecessary python libraries from windows build -- Debug levels - - -Credit ------- - -Frank DeMarco +420@shampoo.ooo diff --git a/pgfw/Animation.py b/pgfw/Animation.py index f0a1c78..3e26ec5 100644 --- a/pgfw/Animation.py +++ b/pgfw/Animation.py @@ -52,10 +52,8 @@ class Animation(GameChild): def is_playing(self, method=None, check_all=False, include_delay=False): if check_all: - return any(self.is_account_playing(account, include_delay) for \ - method, account in self.accounts.items()) - return self.is_account_playing(self.accounts[self.get_default(method)], - include_delay) + return any(self.is_account_playing(account, include_delay) for method, account in self.accounts.items()) + return self.is_account_playing(self.accounts[self.get_default(method)], include_delay) def is_account_playing(self, account, include_delay): return account.playing and (include_delay or not account.delay)