ok so after a bit more messing around it seems your script just adds and the outline and hides it when it is not active which means if you have copies of the same obj you need to generate an outline for each where as mine just used the same outline for all objs with the same name
is there any way to add an obj to the scene.objectsInactive ?
the other way around would be to just move the outline around where needed but if you had a LOT of outlines from lots of different thing would it impact the games performance any more than having them all in the inactive layer?
(forgot to capture mouse cursor…)
New objects use the generated outline from saved dictionary during gameplay.
New objects can be spawned in during gameplay.
Some objects now have hit box, which will instead receive the mouse ray.
In result the logic spike on those models is minimal.
Should update the first post.
Should write a explanation/tut how to use it.
bug> other than C?
What does it say in console?
Are you still using old version of blender?
I mean most of your bugs don’t make sense…
In blender you can store a random variable in bge.logic ( or logic like you use).
It’s just like a dictionary. You just name it, bge.logic.thisIsMyVariable = {}, and you are done.
Certainly some comments are needed.
But yeah, I would like to avoid tedious work of documenting every line.
Especially when the function name says it or it is plain syntax. Like defaultDict or getVertex.
Thats why I try to use sensible way of coding beforehand so that the code comments itself.
But I could do it, not that i have better things to do during lectures.
Just tell me what is too much hacked.
a ya sorry i will test stuff more from now on before posting and more so when i am tired lol
it seems to be from importing from the testmodels.blend so heres the error from a file with just a cube and following the info.txt
it keeps repeating
GenNewOutlineGenTime: 0.002000093460083008
GenNewOutline
GenTime: 0.0
GenNewOutline
GenTime: 0.0010008811950683594
GenNewOutline
GenTime: 0.0
GenNewOutline
GenTime: 0.0
GenNewOutline
GenTime: 0.003000020980834961
GenNewOutline
GenTime: 0.0009999275207519531
GenNewOutline
Could not be found "Cube"
Python script error - object 'Empty.002', controller 'Python':
Traceback (most recent call last):
File "useCaseExample.py", line 109, in <module>
File "useCaseExample.py", line 18, in main
File "useCaseExample.py", line 103, in init
File "useCaseExample.py", line 58, in outline
File "E:\blender stuff\games\scripts oonoutline oonoutline (2).blend\outline
.py", line 51, in makeOutline
File "E:\blender stuff\games\scripts oonoutline oonoutline (2).blend\outline
.py", line 19, in makeUniqueMeshCopy
IndexError: list index out of range
ok so after some time and a lot of messing around trying to understand the changes lol
it seems that you can’t import something with a material name other than ‘Material’ or ‘Material.NNN’ (N is a number) otherwise the obj will be the color of the outline
also i tried mixing my script with the newer one to better understand it but i keep getting the same glitch but with any name thats not ‘Material.001’ and at a few points the outline had no color so it looked like a harshly shadowed what ever