5 private static Vector3
org;
9 public SpriteProvider
provider =
new SpriteProvider();
13 public static Vector3
V2 =
new Vector3(2f, 2f, 1f);
15 public override bool isPCC =>
true;
24 provider.onSetSprite = delegate(Sprite a)
27 mpb.SetTexture(
"_MainTex",
sr.sprite.texture);
31 mpb.SetTexture(
"_MainTex",
sr.sprite.texture);
54 return provider.currentFrame % 2;
66 public override void Kill()
76 if (
pcc.data.isUnique)
88 int tempLeft =
pcc.data.tempLeft;
89 int tempRight =
pcc.data.tempRight;
95 bool flag3 = num == 0 || num == 1;
98 p.tile = tempRight * (flag3 ? 1 : (-1));
100 p.x = org.x + mainHandPos2[num].x + mainHand2[num].x;
101 p.y = org.y + mainHandPos2[num].y + mainHand2[num].y;
102 p.z = org.z - renderTempEQ.offset.z + mainHandPos2[num].z + mainHand2[num].z;
103 renderTempEQ.
Draw(p);
113 bool flag2 = num == 0 || num == 1;
121 thing.dir = ((!flag2) ? 1 : 0);
123 p.x = org.x + mainHandPos[num].x + mainHand[num].x + (flag2 ? 0.01f : (-0.01f)) * (float)pref.
equipX;
124 p.
y =
org.y + mainHandPos[num].y + mainHand[num].y + 0.01f * (
float)pref.
equipY;
125 p.z = org.z - thing.renderer.data.offset.z + mainHandPos[num].z + mainHand[num].z;
131 p.x -= thing.renderer.data._offset.x * 2f;
148 bool flag5 = num == 1 || num == 3;
151 p.tile = tempLeft * (flag5 ? 1 : (-1));
152 p.matColor = 104025f;
153 p.x = org.x + offHandPos2[num].x + offHand2[num].x;
154 p.y = org.y + offHandPos2[num].y + offHand2[num].y;
155 p.z = org.z - renderTempEQ2.offset.z + offHandPos2[num].z + offHand2[num].z;
156 renderTempEQ2.
Draw(p);
170 bool flag4 = num == 1 || num == 3;
174 thing2.dir = ((!flag4) ? 1 : 0);
176 p.x = org.x + offHandPos[num].x + offHand[num].x + (flag4 ? 0.01f : (-0.01f)) * (float)pref2.
equipX;
177 p.
y =
org.y + offHandPos[num].y + offHand[num].y + 0.01f * (
float)pref2.
equipY;
178 p.z = org.z - thing2.renderer.data.offset.z + offHandPos[num].z + offHand[num].z;
184 p.x -= thing2.renderer.data._offset.x * 2f;
207 base.RefreshSprite();
MaterialPropertyBlock mpb
override void Draw(RenderParam p)
SourceFloor.Row sourceSurface
override void OnSetOwner()
override void OnRender(RenderParam p)
override void RefreshSprite()
override void NextFrame()
override void IdleFrame()
override bool IsDeadOrSleeping
static GameSetting setting
AnimationFrame[] animeWalk
virtual Thing RenderThing
void Draw(RenderParam p, int tile)
override void SetRenderParam(RenderParam p)
virtual bool InvertHeldSprite