Only search projects.blender.org
Log In
New Account
Home
My Page
Projects
Blender 2.x BF release
Summary
Activity
Tracker
SCM
Files
Blender 2.6 Bug Tracker: Browse
[#26667] Can't import scripts when using blenderplayer *NEED MORE INFO*
Date:
2011-03-29 14:47
Priority:
3
State:
Closed
Submitted by:
Daniel Dionne (
mrzeon
)
Assigned to:
Campbell Barton (campbellbarton)
Category:
None
Status:
Fixed / Closed
Relates to:
Duplicates:
Patches:
Summary:
Can't import scripts when using blenderplayer *NEED MORE INFO*
Detailed description
Internal script imports aren't working properly when executing with blenderplayer.
For example, I have a script called util.py. When doing "import util" from another script, I get the following error:
ImportError: No module named util
Python script error from controller "init.py#CONTR#3":
Traceback (most recent call last):
File "init.py", line 3, in <module>
Exporting the script to the path where the .blend is located works.
Followup
Message
Date
: 2011-03-29 15:42
Sender
:
Campbell Barton
please upload an example blend (or zip of multiple files which show this bug).
if your files are complicated it helps to make a more simple testcase.
Date
: 2011-03-29 16:36
Sender
:
Daniel Dionne
I uploaded a simple example.
Opening it in Blender works fine, it should print "hey, I'm a function!" to the console.
Opening it with blenderplayer results in the previously mentioned import error.
Date
: 2011-03-29 18:12
Sender
:
Campbell Barton
fixed r35882.
Attached Files:
Name
Date
Download
scripts_bug.blend
2011-03-29 16:36
Download
Changes:
Field
Old Value
Date
By
status_id
Open
2011-03-29 18:12
campbellbarton
close_date
None
2011-03-29 18:12
campbellbarton
Status
Investigate
2011-03-29 18:12
campbellbarton
File Added
15600: scripts_bug.blend
2011-03-29 16:36
mrzeon
assigned_to
none
2011-03-29 15:42
campbellbarton
summary
Can\'t import scripts when using blenderplayer
2011-03-29 15:42
campbellbarton
Status
New
2011-03-29 15:42
campbellbarton