Christopher wrote:GPNMilano wrote:Christopher wrote:I worked a bit on my self on this StartUp and made it to load the avatar:
http://youtu.be/kgxlKFyVl4U
Thanks to Mystler for making the textures for me.
Christopher
Nice job Chris!
Might I ask how you managed to load the avatar, and would you be willing to share the code so I could complete mine? I toyed around with it. I'm assuming you loaded the avatar from the vault and spawned him with an NPCSpawner during the selection part of the python script. Or did you have the script read the clothing options for the specific avatars and then dress dummy avatars accordingly?
First of all, I didn't use a NPCSpawner. NPCs are no avatars, cause they don't have a plArmatureMod (you can try it out by calling npc.avatar.isAvatar() in python, where npc is the Sceneobject from the NPCSpawner). So I had to use a SpawnPoint. This way a real avatar spawn in the StartUp, which you can edit. The next step was to save the clothing options into a file if you enter your relto, which is saved to "AppData/Local/UruLive/Avatar/<KINumber>.clo" and then loaded loaded again if you enter the StartUp age. In the first version I tried to manage it with python, which caused the flickering of the avatar if you switch to a new player. In the second version Mystler managed to modify the client to save the clothing options to disk. I think he will upload his code on github soon.
This way you don't have to load the whole vault if you select an avatar.
Christopher
Ah, I see. Yeah. what I meant with the NPC, was to use an NPCSpawner but load a male or female avatar and dress him/her based on your clothing options that are saved in the vault. Adrael used this method but created the clothing options for Irena within python rather than reading it from the vault and spawned her to the NPCSpawner object.