pygame is
Simple DirectMedia Layer is
Site Swing
Map Editor

Map Editor - 11.0.0

Ian Mallett (geometrian)



A user-friendly method of making 3D texture-mapped maps. This program requires you to have PyOpenGL and PyGame preinstalled.


A complete overhaul of the entire source code! (No, like, seriously. I deleted everything and started from scratch). I added tools ranging from huge to tiny, multiple modes, improved speed, better blending effects, etc.

Numpad8 = Rotate view up
Numpad4 = Rotate view left
Numpad6 = Rotate view right
Numpad2 = Rotate view down
CTRL+Numpad8 = Translate view up
CTRL+Numpad4 = Translate view left
CTRL+Numpad6 = Translate view right
CTRL+Numpad2 = Translate view down
a, NumpadPlus = raise terrain at cursor
z, NumpadMinus = lower terrain at cursor
PAGEUP = zoom out
PAGEDOWN = zoom in
END = reset view
UPARROW = move tool up
DOWNARROW = move tool down
LEFTARROW = move tool left
RIGHTARROW = move tool right
1 = set tool radius to 1
2 = set tool radius to 2
3 = set tool radius to 3
4 = set tool radius to 4
5 = set tool radius to 5
6 = set tool radius to 6
7 = set tool radius to 7
8 = set tool radius to 8
9 = set tool radius to 9
0 = set tool radius to 10
CTRL+s = save (note .obj files not yet supported)
F1 = draw in "fill" mode
F2 = draw in "line" mode
F3 = draw in "point" mode


Home Page:


click to view original size


Map Editor - 15.0.0 - Dec 21, 2012
Map Editor - 14.1.5 - Oct 22, 2007
Map Editor - 14.1 - Oct 22, 2007
Map Editor - 14.0.0 - Oct 21, 2007
Map Editor - 13.1 - Aug 21, 2007
Map Editor - 11.1 - Aug 18, 2007
Map Editor - 11.0.0 - Aug 17, 2007
Map Editor - 10.1.0 - Jul 26, 2007
Map Editor - 10.0.0 - Jul 22, 2007
Map Editor - 9.0.0 - Jul 22, 2007
Map Editor - 8.0.0 - Jul 21, 2007
Map Editor - 5.0.0 - Jul 20, 2007
Map Editor - 4.0.0 - Jul 11, 2007
Map Editor - 3.0.0 - Jul 11, 2007 account Comments

If you wish to leave a comment with your account, please sign in first.

December 21, 2012 7:00pm - Ian Mallett - nickname: (geometrian)
Version 15.0.0 released! This version was completely rewritten and uses a completely different method of updating, so should be much better functioning.
August 30, 2009 2:02pm - Ian Mallett - nickname: (geometrian)
Delete all the .pyc files and try again. The problem is caused by your having a different version of Python than one who compiled the file originally. Ask the mailing list for faster results.
July 25, 2009 7:15am - Josh T - nickname: (mrbluesky) - 4/5
I keep getting this error:
Traceback (most recent call last):
File "/14.1.5/Map", line 7, in <module>
import GL, GetTextures
ImportError: Bad magic number in /14.1.5/GL.pyc

I seem to get this often with arbitrary pygame games, can somebody help me out here?
October 22, 2007 4:00pm - Ian Mallett - nickname: (geometrian)
v.14.1.5 released! The editing system caused an edited quad to be drawn twice, then 4 times, 8, 16, etc. This fixes that, and keeps the program running at what appears to be about 80fps.
October 22, 2007 2:50pm - Ian Mallett - nickname: (geometrian)
v.14.1 released, sporting an entirely new input system! YAY!
October 21, 2007 3:02pm - Ian Mallett - nickname: (geometrian)
Oh, yes, and the program doesn't rebuild the entire map each frame, just the relevant portion!
October 21, 2007 3:01pm - Ian Mallett - nickname: (geometrian)
v.14.0.0 released! This version fixes all the problems described below. (Though you still need to have PyOpenGL and Pygame). This works by calling a list of display lists. Cool!
August 25, 2007 12:58pm - Ian Mallett - nickname: (geometrian)
Sorry about that. I'm a one person dev. team and I don't have too much time. I must have forgotten to test saving.
August 24, 2007 3:42pm - Claudio Canepa - nickname: (claxo)
1. For other users: you need a recent wxPython ; 2.6 will fail, the current stable ( 2.8.4 ) worked for me.

2. Bug report: crash at saving, file doenst save. Last line traceback:
File "map", line 179, in save
import write; write.write_to_file(quads, normals, path, dimensionx, dimensio
NameError: global name 'normals' is not defined

Dude, why you dont test your packages ?
August 23, 2007 5:16pm - Anonymous - nickname: (pywiz32)
on old xp
August 23, 2007 5:16pm - Anonymous - nickname: (pywiz32)
still got GLError err = 1281
August 22, 2007 3:03pm - josephusm - nickname: (josephusm)
In relation to the previous message that threw up GLError err = 1281 when trying to execute GLTexImage2D(): Older cards depend on texture sizes with dimensions equal to powers of 2 (or if they are really old, powers of 2 and square). Try changing the width and height arguments to a really small power of 2 and see if that fixes anything. This was the case for us with our pyopengl app running on a Geforce2 MX
August 21, 2007 7:42pm - Ian Mallett - nickname: (geometrian)
Well, The program might not work on that OS. Note that's a "maybe" so it still could work. (There's a bunch of OS stuff in the program). Anyway, if the program runs, there's nothing to worry about.
August 21, 2007 12:21pm - John Jones - nickname: (john)
Why does it say that I'm running an unsupported OS?
August 21, 2007 11:02am - Ian Mallett - nickname: (geometrian)
My mistake. That does not need to be done. I was recompiling every single list for every list changed... which amounts to several thousand. Only recompiling the changed lists make it at least as fast as the vertex arrays version, but far more compatible. v.13.1 released!
August 20, 2007 5:11pm - Ian Mallett - nickname: (geometrian)
On my computer, at least, the display list compilation takes longer than expected, so the framerate for a map at any size drops to about 4. This is unacceptable. I'm going to have it recompile the list in a subprocess when the editing is done to fix this problem. I expect the release soon though.
August 19, 2007 10:44pm - Ian Mallett - nickname: (geometrian)
I've decided that version 12 should not be released. Instead, development will continue with a new version, 13. Hopefully, v.13 will be compatible with all graphics cards (even moderately old ones), and will feature much faster everything. The plan is to use a hierarchy of display lists. This way, instead of recompiling the whole map each frame (like in a previous release), only the portion that changed will be updated. This will be easily fast enough (est. 70fps) on moderately new machines. Tell me what you think!
August 18, 2007 6:59pm - Anonymous - nickname: (pywiz32)
yes, i have everything. will try 11.1 this evening.
August 18, 2007 4:40pm - Ian Mallett - nickname: (geometrian)
OK, see version 11.1. Did you get the program working?
August 18, 2007 3:51pm - Ash - nickname: (aash29)
readme mentions '' file, which I was unable to locate. Could you pls add it?
August 18, 2007 11:11am - Ian Mallett - nickname: (geometrian)
Ah, that's better. That means your gfx system passes! Well, do you have Pygame, PyOpenGL, and NumPy?
August 17, 2007 11:24pm - Anonymous - nickname: (pywiz32)
btw: my xp is about four years old, and i haven't chaned the graphics card
August 17, 2007 11:19pm - Anonymous - nickname: (pywiz32)
you're right. i think it is the graphics card. ran the prog on brand-new windows vista with nvidia graphics card, and even though the program crashed afterward (no error message) it got past building textures.
August 17, 2007 10:52pm - Ian Mallett - nickname: (geometrian)
I don't <i>think</i> that supports it either:
August 17, 2007 5:01pm - Stefan Jeremic - nickname: (stefan)
I get same error as pywiz32. My graphics card is GeForceFX 5200
August 17, 2007 4:05pm - Ian Mallett - nickname: (geometrian)
To everybody: I am currently porting this entire thing to use Vertex Buffer Objects, which are more complicated to program, but more universally supported and faster.
August 17, 2007 4:03pm - Ian Mallett - nickname: (geometrian)
It can't finish generating the data. I think the problem here is your graphics card, (see description). What kind of graphics card do you have? How new is it?
August 17, 2007 2:16pm - Anonymous - nickname: (pywiz32)
ugh... whenever i run the program (windows xp sp2 with python 2.4) it gets up to 'building textures...' and then spits out:

Traceback (most recent call last):
File "C:\Documents and Settings\Jerome.DANSCOMPUTER\Desktop\Jerome\downloads\Map Editor (11)\11\Map", line 207, in ?
if __name__ == '__main__': main()
File "C:\Documents and Settings\Jerome.DANSCOMPUTER\Desktop\Jerome\downloads\Map Editor (11)\11\Map", line 202, in main
File "C:\Documents and Settings\Jerome.DANSCOMPUTER\Desktop\Jerome\downloads\Map Editor (11)\11\Map", line 44, in load_textures
textures = get_textures.main(textures)
File "C:\Documents and Settings\Jerome.DANSCOMPUTER\Desktop\Jerome\downloads\Map Editor (11)\11\", line 15, in main
File "C:\Python24\lib\site-packages\pyopengl-3.0.0a6-py2.4.egg\OpenGL\", line 1624, in __call__
File "C:\Python24\lib\site-packages\pyopengl-3.0.0a6-py2.4.egg\OpenGL\", line 924, in wrapperCall
GLError: GLError(
err = 1281,
description = 'invalid value',
baseOperation = glTexImage2D,
pyArgs = [
cArgs = [
cArguments = (

any recomendations?
August 17, 2007 12:16pm - Ian Mallett - nickname: (geometrian)
Version 11 released.
July 28, 2007 5:47pm - Ian Mallett - nickname: (geometrian)
I don't understand John's error. If there is a hidden module called "Settings" it should work. If you used Winzip and selected all to extract, it didn't select Settings and therefore didn't unzip it. For convenience, I've updated the app. to have all unhidden files.

Simon's error is more straightforward. Segmentation faults happen when a process tries to read from a nonexistent memory cache (in this case on your GPU). This program uses "Vertex Arrays" for speed, which are not supported on older or Voodoo cards. All this is what someone told me, though, so I could be wrong.

Incidentally, thanks for helping me get this working.
July 28, 2007 12:27pm - Simon Oberhammer - nickname: (simonoberhammer)
ubuntu 7.4 not 7.10 - im not runnig a beta. got python 2.5. other opengl-python things like soya3d demos work.
July 28, 2007 12:26pm - Simon Oberhammer - nickname: (simonoberhammer)
@everybody who has ImportError's. In the top-level directory rename everything from *pyw to *py. This got me further.

But after selecting the screen resolution, this happend. ubuntu 7.10 i368

Adding data to list for processing...
Fatal Python error: (pygame parachute) Segmentation Fault
Aborted (core dumped)
July 28, 2007 4:00am - John Jones - nickname: (john)
Same error.
July 27, 2007 6:53pm - Ian Mallett - nickname: (geometrian)
Try downloading again. "Settings" is a hidden module. If it's not there, the download did not work right. If that doesn't fix it, let me know.
July 27, 2007 4:05am - John Jones - nickname: (john)
Traceback (most recent call last):
File "./MAP", line 13, in <module>
import Settings
ImportError: No module named Settings
July 26, 2007 3:10pm - Ian Mallett - nickname: (geometrian)
New version released, fixing the problem.
July 26, 2007 3:03pm - Ian Mallett - nickname: (geometrian)
This happens when you have a .pyc file that was compiled by a different version of Python you are trying to import from. I use 2.4, though most people usually have 2.5. To fix this immediately, show all hidden files and folders and delete all of the files with .pyc extensions. Then rerun the program. I'll release a new version later today without them.
July 26, 2007 5:32am - John Jones - nickname: (john)
Traceback (most recent call last):
File "./MAP", line 13, in <module>
import Settings
ImportError: Bad magic number in /home/xer/Desktop/10/Settings.pyc
July 21, 2007 11:49am - Ian Mallett - nickname: (geometrian)
This latest version uses vertex objects, which only are only really supported on newer GPUs, indeed that call tells the GPU to draw them. If your computer is rather old, that may explain it.
July 21, 2007 11:11am - RB[0] - nickname: (roebros)
Fatal Python error: (pygame parachute) Segmentation Fault

This application has requested the Runtime to terminate it in an un
Please contact the application's support team for more information.

This happens on the call to "glDrawElements(GL_QUADS,number*4,GL_UNSIGNED_INT,array)" in draw() in main() in MAP

BTW, It would be nice if your filenames didn't contain spaces, ie.(Map =, as it is difficult to get my command prompt to locate folders/files with spaces(I am on windows)
July 20, 2007 4:02am - Ian Mallett - nickname: (geometrian)
Version 5.0.0 works with display lists which are only rebuilt after each time a quad is changed. It should be changed soon. However, for the meantime, while this thing can draw immense maps (500x500+) the speed to update the display list can be very slow. Remember for your computer's sake with square maps that each increasing unit squares. Like:
1x1 = 1
2x2 = 4
3x3 = 9
4x4 = 16
25x25 = 625
500x500 = 250,000 don't make your maps giant. I recommend no more than 100x100 for editing, 50x50 for optimum, though I've never noticed ANY framerate decrease for viewing at 500x500 (because of display lists).
July 13, 2007 6:50pm - Ian Mallett - nickname: (geometrian)
I'm guessing it may be your system- I just tested it and it works fine. Also, what map dimensions were you trying for? My machine was made this year, but it can't handle anything over 20x20 without a noticeable drop in framerate. It's a semi-gaming machine too, so it has a good GPU and CPU. A non-graphic, randomly-generated map editor and viewer are in dev., though I don't know if anyone wants it.
July 13, 2007 6:44pm - Ian Mallett - nickname: (geometrian)

Either that or something else. Do other OpenGL programs work? Do you have OpenGL?

You might try TuxRacer- there's a port to windows, and it's OpenGL. If that works, so should this.
July 13, 2007 6:18pm - Anonymous - nickname: (pywiz32)
i'm using your program on win98 (yes, it can do 3d, even if it's slow) and every time I run it, is says:

Traceback (most recent call last):
File "C:\WINDOWS\Profiles\10324567\Desktop\jerome\downloads\Map_Editor\Map Editor\MAP", line 342, in ?
if __name__ == '__main__': main()
File "C:\WINDOWS\Profiles\10324567\Desktop\jerome\downloads\Map_Editor\Map Editor\MAP", line 340, in main
File "C:\WINDOWS\Profiles\10324567\Desktop\jerome\downloads\Map_Editor\Map Editor\MAP", line 222, in draw
OpenGL.GL.GLerror: [Errno 1281] invalid value
July 11, 2007 6:11pm - Ian Mallett - nickname: (geometrian)
Ah, yes. That would do it, wouldn't it? Thanks for catching that. New version released.
July 11, 2007 6:07pm - RB[0] - nickname: (roebros)
OK, I managed to get the importing working, just change:

dir='C:\\dev\\Python24\\Projects\\Map Editor\\Data'



Alas though, I get just a clear screen that wont render(it got hung up in Object.main) but that happens to me sometimes with 3d stuff, so I wouldnt worry about it.

The program does look cool though :)
July 11, 2007 5:13pm - Ian Mallett - nickname: (geometrian)
"another sugestion: PyOpenGL can be used with Numeric or Numpy" I don't use either in my program. I probably import them anyway, but they're unnecessary. If you got the same error too, that probably means something else is happening. It works flawlessly on my machine from download to execute. What version of pygame/python do you have? Most people have 2.5, but I have 2.4.
July 11, 2007 4:35pm - Claudio Canepa - nickname: (claxo)
The problem with is not about hiden files; it is the hardcoded data path that you use in 'map' and You can look in the pygame cookbook the recipe for getting the apppath and derive for this the data path.

another sugestion: PyOpenGL can be used with Numeric or Numpy, and PyOpenGL is picky about the version of numeric packages, so maybe doing conditional imports with try - except would be more friendly? FYI I tried with Numeric 24.2, seems to work ok.
July 11, 2007 3:33pm - Ian Mallett - nickname: (geometrian)
"Object" is a .py file in the "Data" (hidden) directory. If it's not there, that's your problem.
July 11, 2007 3:22pm - Ian Mallett - nickname: (geometrian)
That's weird. I test downloaded it and it works fine. Try downloading it again.
July 11, 2007 2:45pm - RB[0] - nickname: (roebros) - 2/5
Looks great, but got following error...

Traceback (most recent call last):
File "C:\Python25\downprogs\Map Editor\MAP", line 43, in <module>
import screendimfull, surface, Object
ImportError: No module named Object

our projects welcomes all python game, art, music, sound, video and multimedia projects. If they use pygame or not.
recent releases
Feb 21, 2017

Jan 31, 2017

Jan 24, 2017

Jan 18, 2017

Jan 7, 2017

Dec 30, 2016

Dec 8, 2016

Nov 28, 2016

Nov 27, 2016

... more!
for pygame related questions, comments, and suggestions, please see help (lists, irc)