Jump to content

what is wrong with IntListSet() IntListGet()?


pxd2050

Recommended Posts

import JsonUtil
Function HairColorP(Actor ActorRef)
	ActorBase ActorB = ActorRef.GetActorBase()
	int hp = ActorB.GetIndexOfHeadPartByType(3)
	string hpname = ActorB.GetNthHeadPart(hp).GetPartName()
	int HairTintColor = NiOverride.GetNodePropertyInt(ActorRef,false,hpname,7,-1)
	int Red = GetRed(HairTintColor)
	int Green = GetGreen(HairTintColor)
	int Blue = GetBlue(HairTintColor)
	int color = (65536*Red + 256*Green + Blue)/2
	ColorForm haircolor = ActorB.GetHairColor()
	haircolor.setcolor(Color)
	ActorB.SetHairColor(haircolor)
	ActorRef.QueueNiNodeUpdate()
	IntListSet(ActorRef,"HairColor",0,color)
	IntListSet(ActorRef,"HairColor",1,Red)
	IntListSet(ActorRef,"HairColor",2,Green)
	IntListSet(ActorRef,"HairColor",3,Blue)
EndFunction

Function HairColor(actor ActorRef)
	HairColorP(ActorRef)
	int red0 = IntListGet(ActorRef, "HairColor",1)
	int red1 = IntListGet(ActorRef, "HairColor",4)
	debug.notification(red0)
	debug.notification(red1)

what is wrong with IntListSet() IntListGet()?

debug.notification(red0)

debug.notification(red1)

Other things are correct except debug result: red0 = 0 red1 =0

Edited by pxd2050
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...