mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 16:58:40 -04:00
Don't show libpandaexpress ImportError if importing panda3d.core failed
This commit is contained in:
parent
2b034506fa
commit
461b231a2e
@ -111,9 +111,14 @@ def Dtool_PreloadDLL(module):
|
|||||||
# new-style build, and if it fails we must be in an old-style build.
|
# new-style build, and if it fails we must be in an old-style build.
|
||||||
try:
|
try:
|
||||||
from panda3d.core import *
|
from panda3d.core import *
|
||||||
except ImportError:
|
except ImportError as ex:
|
||||||
Dtool_PreloadDLL("libpandaexpress")
|
# Maybe we're using an old-style libpandaexpress module?
|
||||||
from libpandaexpress import *
|
try:
|
||||||
|
Dtool_PreloadDLL("libpandaexpress")
|
||||||
|
from libpandaexpress import *
|
||||||
|
except ImportError:
|
||||||
|
# Nope. Re-raise the original ImportError.
|
||||||
|
raise ex
|
||||||
|
|
||||||
def Dtool_ObjectToDict(cls, name, obj):
|
def Dtool_ObjectToDict(cls, name, obj):
|
||||||
cls.DtoolClassDict[name] = obj;
|
cls.DtoolClassDict[name] = obj;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user