/usr/games/magicor-editor is in magicor 1.1-4.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | #!/usr/bin/python
#
# Magicor Level Editor
# Copyright 2006 Peter Gebauer. Licensed as Public Domain.
# (see LICENSE for more info)
from optparse import OptionParser
import sys, os
sys.path.append(".")
##-->win
def change_to_correct_path(): #taken from pygame wiki cookbook
import os, sys
exe_base_dir = os.path.abspath(os.path.dirname(sys.argv[0]))
os.chdir(exe_base_dir)
sys.path.append(exe_base_dir)
if sys.platform=='win32':
change_to_correct_path() #usefull when running from another dir, desktop or appbar
##<--win
from magicor import getConfig
from magicor.editor.gtkgui import GtkEditor
parser = OptionParser()
##-->win
if sys.platform=='win32':
parser.add_option("-c", "--config", dest="configPath",
default = ".",
help="use this config path, default is magicor directory.")
baseConf=".\magicor-editor.conf"
else:
parser.add_option("-c", "--config", dest="configPath",
default = "/etc/magicor-editor.conf",
help="use this default config, default /etc/magicor-editor.conf")
baseConf="~/.magicor/magicor-editor.conf"
##<--win
(options, args) = parser.parse_args()
paths = [options.configPath, baseConf] ##@@
conf = getConfig(paths)
##-->win
if sys.platform=='win32': # not clean but...
conf["user_path"]='.'
conf["data_path"]='data'
##<--win
GtkEditor(conf, args and args[0] or None)
|