diff --git a/nml/actions/real_sprite.py b/nml/actions/real_sprite.py index 6e03473..5ae2f26 100644 --- a/nml/actions/real_sprite.py +++ b/nml/actions/real_sprite.py @@ -16,7 +16,8 @@ with NML; if not, write to the Free Software Foundation, Inc., from nml import generic, expression from nml.actions import base_action from nml.ast import assignment -import os, Image +import os +from PIL import Image palmap_d2w = [ 0, 215, 216, 136, 88, 106, 32, 33, # 0..7 diff --git a/nml/ast/alt_sprites.py b/nml/ast/alt_sprites.py index 163bb23..fb12d0a 100644 --- a/nml/ast/alt_sprites.py +++ b/nml/ast/alt_sprites.py @@ -16,7 +16,8 @@ with NML; if not, write to the Free Software Foundation, Inc., from nml import expression, generic, global_constants from nml.actions import real_sprite from nml.ast import base_statement -import os, Image +import os +from PIL import Image """ List with all AltSpritesBlocks encountered in the nml file. diff --git a/nml/main.py b/nml/main.py index cbee6d2..abbecda 100644 --- a/nml/main.py +++ b/nml/main.py @@ -19,7 +19,7 @@ from nml.actions import action2layout, action2var, action8, sprite_count, real_s from nml.ast import general, grf, alt_sprites try: - import Image + from PIL import Image except ImportError: pass diff --git a/nml/output_grf.py b/nml/output_grf.py index 8f116aa..b5c05a8 100644 --- a/nml/output_grf.py +++ b/nml/output_grf.py @@ -18,7 +18,7 @@ from nml import generic, palette, output_base, lz77, grfstrings from nml.actions.real_sprite import palmap_w2d try: - import Image + from PIL import Image except ImportError: pass diff --git a/nml/version_info.py b/nml/version_info.py index da0ff94..b077baf 100644 --- a/nml/version_info.py +++ b/nml/version_info.py @@ -45,7 +45,7 @@ def get_lib_versions(): versions = {} #PIL try: - import Image + from PIL import Image versions["PIL"] = Image.VERSION except ImportError: versions["PIL"] = "Not found!"