def setAvatars(self, avatars):
        avList = []
        for avNum, avName, avDNA, avPosition, nameState in avatars:
            nameOpen = int(nameState == 1)
            names = [avName, '', '', '']
            if nameState == 2: # PENDING
                names[1] = avName
            elif nameState == 3: # APPROVED
                names[2] = avName
            elif nameState == 4: # REJECTED
                names[3] = avName

            dna = HumanDNA()
            dna.makeFromNetString(avDNA)                
            avList.append(PotentialAvatar(avNum, names, dna, avPosition, nameOpen))
            
        while len(avList) < 4:
            avList.append(OTPGlobals.AvatarSlotAvailable)       
            
        self.cr.handleAvatarsList({0: avList})
    def setAvatars(self, avatars):
        avList = []
        for avNum, avName, avDNA, avPosition, nameState in avatars:
            nameOpen = int(nameState == 1)
            names = [avName, '', '', '']
            if nameState == 2:  # PENDING
                names[1] = avName
            elif nameState == 3:  # APPROVED
                names[2] = avName
            elif nameState == 4:  # REJECTED
                names[3] = avName

            dna = HumanDNA()
            dna.makeFromNetString(avDNA)
            avList.append(
                PotentialAvatar(avNum, names, dna, avPosition, nameOpen))

        while len(avList) < 4:
            avList.append(OTPGlobals.AvatarSlotAvailable)

        self.cr.handleAvatarsList({0: avList})
    def setAvatars(self, avatars):
        avatarList = {}
        data = []

        for avNum, avName, avDNA, avPosition, nameState in avatars:
            nameOpen = int(nameState == 1)
            names = [avName, '', '', '']
            if nameState == 2:  # PENDING
                names[1] = avName
            elif nameState == 3:  # APPROVED
                names[2] = avName
            elif nameState == 4:  # REJECTED
                names[3] = avName

            dna = HumanDNA()
            dna.makeFromNetString(avDNA)

            data.append(
                PotentialAvatar(avNum, names, dna, avPosition, nameOpen))

        avatarList[1] = data + [OTPGlobals.AvatarSlotAvailable
                                ] * (OTPGlobals.AvatarNumSlots - len(data))
        self.cr.handleAvatarsList(avatarList)