Exemple #1
0
    print indent + '-+ ' + dtypestr + name + '(' + str(
        oid) + ')' + props + mprops + links

    # a formatting related variable
    single = 1

    # get inheritance targets, iterate over those
    for l in inhsrv.getTargets(oid):
        # the inh. target is not inheriting as MP, but as archetype
        if l.priority == 0:
            # so we'll format
            single = 0
            # recurse with the target property
            otree(l.dst, indent + ' |')

    if not single:
        print indent


# An example Object tree list for all the archetype base objects (id can change, name hopefully not)
for srcobj in [
        "Object", "MetaProperty", "Stimulus", "Flow Group", "Base Room",
        "Texture"
]:
    print "================ Object tree for " + srcobj + " ====================="
    otree(objsrv.named(srcobj), "")
    print

# see, this is the way to log from python (the python log calls are prefixed "Python:" in the log)
opde.log_info("Terminating opde")
Exemple #2
0
def debugFrameRequest(msg):
    opde.log_info(
        "Received a message for frame debugger. Will debug one frame")
    opde.log_info("Comand field: " + msg.command)
    opde.log_info("Comand params: " + str(msg.params))
    lsrv.debugOneFrame()
Exemple #3
0
def databaseProgressUpdate(msg):
    opde.log_info("Loading progress : " + str(msg.completed * 100))
Exemple #4
0
def exitRequest(msg):
    #    log_info("Received a message for exitRequest " + str(msg.event))
    opde.log_info("Termination requested!")
    lsrv.requestTermination()
Exemple #5
0
	# if the donor type is nonzero, we have encountered a MetaProperty!
	if (dtype == 1):
		dtypestr = "[M] "

	# print out the object info
	print indent + '-+ ' + dtypestr + name + '(' + str(oid)  + ')' + props + mprops + links 

	# a formatting related variable
	single = 1

	# get inheritance targets, iterate over those
	for l in inhsrv.getTargets(oid):
		# the inh. target is not inheriting as MP, but as archetype
		if l.priority == 0:
			# so we'll format
			single = 0
			# recurse with the target property
			otree(l.dst, indent + ' |')

	if not single:
		print indent

# An example Object tree list for all the archetype base objects (id can change, name hopefully not)
for srcobj in ["Object", "MetaProperty", "Stimulus", "Flow Group", "Base Room", "Texture"]:
	print "================ Object tree for " + srcobj + " ====================="
	otree(objsrv.named(srcobj), "")
	print

# see, this is the way to log from python (the python log calls are prefixed "Python:" in the log)
opde.log_info("Terminating opde");
Exemple #6
0
def databaseProgressUpdate(msg):
    opde.log_info("Loading progress : " + str(msg.completed  * 100))
Exemple #7
0
def debugFrameRequest(msg):
    opde.log_info("Received a message for frame debugger. Will debug one frame")
    opde.log_info("Comand field: " + msg.command)
    opde.log_info("Comand params: " + str(msg.params))
    lsrv.debugOneFrame()
Exemple #8
0
def exitRequest(msg):
#    log_info("Received a message for exitRequest " + str(msg.event))
    opde.log_info("Termination requested!")
    lsrv.requestTermination()