i’m still locked to my fps bottleneck, i tried to add to every object a simplest sensor set for detect the player position and change the mesh/material/texture (complete Obj in some case) .
this works fine if object are few.
But when the object are many this create a new bottleneck, due to computation of many scripts for many obj.
i wish to create a Radar sensor directly to camera, that switch LOD properties (HD,LD,OutZone)
i did this:
-indicitation is lost due to copy/paste-
cont = bge.logic.getCurrentController() own = cont.owner
sens = cont.sensors['RadarLodHD'] sens2 = cont.sensors['RadarLod2']
if sens.positive: if 'LodLD' in sens.hitObject: sens.hitObject['LodHD'] = True
else: if sens2.positive: if 'LodHD' in sens.hitObject: sens.hitObject['LodHD'] = False sens.hitObject['LodLD'] = True else: sens.hitObject['LodLD'] = False
(if both HD & LD are false the OBj should have an OutZone definition (a cube very low pixeled) but the huge problem is that the Properties “triggered” dont return False!
there is some easy script for set a properties[False] to all the object in scene if the sensor dont detect them ?