Skip to content

Commit

Permalink
code cleanup + engine version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
wkta committed Apr 22, 2024
1 parent 0007f87 commit 4f5fc25
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 147 deletions.
2 changes: 1 addition & 1 deletion src/pyved_engine/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
from abc import ABCMeta, abstractmethod
from . import vars
from math import degrees as _degrees
from .classes import Spritesheet as _Spritesheet
# from .classes import Spritesheet as _Spritesheet
from . import _hub
import time
from .compo import vscreen
Expand Down
141 changes: 0 additions & 141 deletions src/pyved_engine/classes.py

This file was deleted.

8 changes: 4 additions & 4 deletions src/pyved_engine/compo/gfx.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def __init__(self, filename_noext_nopath, pathinfo=None, ck=None):
avoid several bugs that exist in the pyVM component.
(scaling images, and use .subsurface on these images for cutting sub images)
As long as the pyVM has not bee toroughly debugged and tested,
I recommend not modifying the following code /!\ unless you want to take risks
I recommend not modifying the following code, unless you want to take risks
"""

print('create SpriteSheet based on json:', filename_noext_nopath)
Expand Down Expand Up @@ -91,7 +91,7 @@ def _init_sheet_attr(self):
def __init__(self):
self.forcing_transparency = False

self._sheet = None
self._sheet = dict()
self._init_sheet_attr()

# specific to capello-ft.png and capello-ft.json...
Expand Down Expand Up @@ -134,11 +134,11 @@ def __init__(self):

# - generic
self.ascii2img = dict()
defaultw = self._sheet['tile{:03d}.png'.format(self.UNKNOWN_CAR_RK)].get_width()
defaultw = self._sheet["tile{:03d}.png".format(self.UNKNOWN_CAR_RK)].get_width()
self.car_width = defaultdict(lambda: defaultw)

for my_asciicode in mappingtable.keys():
ssurf = self._sheet['tile{:03d}.png'.format(mappingtable[my_asciicode])]
ssurf = self._sheet["tile{:03d}.png".format(mappingtable[my_asciicode])]
self.ascii2img[my_asciicode] = ssurf
self.car_width[chr(my_asciicode)] = ssurf.get_width()

Expand Down
2 changes: 1 addition & 1 deletion src/pyved_engine/vars.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

# below is a read-only value,
# to retrieve this value from outside you can call pyv.get_version()
ENGINE_VERSION_STR = '24.4a2'
ENGINE_VERSION_STR = '24.4a3'

# deprecated but mandatory for web ctx
STD_SCR_SIZE = [960, 720]
Expand Down

0 comments on commit 4f5fc25

Please sign in to comment.