public void Draw(Graphics g,int x, int y,Direction dir,ItemDescriptor weapon) { if(weapon==null) { if((int)dir<4) { leftArm.Stationary[dir].Draw(g,x,y); torso.Stationary[dir].Draw(g,x,y); legs.Stationary[dir].Draw(g,x,y); rightArm.Stationary[dir].Draw(g,x,y); } else { rightArm.Stationary[dir].Draw(g,x,y); torso.Stationary[dir].Draw(g,x,y); legs.Stationary[dir].Draw(g,x,y); leftArm.Stationary[dir].Draw(g,x,y); } } else { if((int)dir>=6 || (int)dir==0) handFile[weapon.HandIndex+(int)dir].Draw(g,x,y+offset); if(weapon.NumHands==1) { if((int)dir<4) { leftArm.Stationary[dir].Draw(g,x,y); torso.Stationary[dir].Draw(g,x,y); legs.Stationary[dir].Draw(g,x,y); rightArmed1.Stationary[dir].Draw(g,x,y); } else { rightArmed1.Stationary[dir].Draw(g,x,y); torso.Stationary[dir].Draw(g,x,y); legs.Stationary[dir].Draw(g,x,y); leftArm.Stationary[dir].Draw(g,x,y); } } else { if((int)dir<4) { leftArmed2.Stationary[dir].Draw(g,x,y); torso.Stationary[dir].Draw(g,x,y); legs.Stationary[dir].Draw(g,x,y); rightArmed2.Stationary[dir].Draw(g,x,y); } else { rightArmed2.Stationary[dir].Draw(g,x,y); torso.Stationary[dir].Draw(g,x,y); legs.Stationary[dir].Draw(g,x,y); leftArmed2.Stationary[dir].Draw(g,x,y); } } if((int)dir>=1 && (int)dir<6) handFile[weapon.HandIndex+(int)dir].Draw(g,x,y+offset); } }
public void Draw(Bitmap b, int x, int y, Direction dir,ItemDescriptor weapon) { if(weapon==null) { if((int)dir<4) { Bmp.Draw(leftArm.Stationary[dir].Image,b,x,y); Bmp.Draw(torso.Stationary[dir].Image,b,x,y); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(rightArm.Stationary[dir].Image,b,x,y); } else { Bmp.Draw(rightArm.Stationary[dir].Image,b,x,y); Bmp.Draw(torso.Stationary[dir].Image,b,x,y); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(leftArm.Stationary[dir].Image,b,x,y); } } else { if((int)dir>=6 || (int)dir==0) Bmp.Draw(handFile[weapon.HandIndex+(int)dir].Image,b,x,y+offset); if(weapon.NumHands==1) { if((int)dir<4) { Bmp.Draw(leftArm.Stationary[dir].Image,b,x,y); Bmp.Draw(torso.Stationary[dir].Image,b,x,y); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(rightArmed1.Stationary[dir].Image,b,x,y); } else { Bmp.Draw(rightArmed1.Stationary[dir].Image,b,x,y); Bmp.Draw(torso.Stationary[dir].Image,b,x,y); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(leftArm.Stationary[dir].Image,b,x,y); } } else { if((int)dir<4) { Bmp.Draw(leftArmed2.Stationary[dir].Image,b,x,y); Bmp.Draw(torso.Stationary[dir].Image,b,x,y); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(rightArmed2.Stationary[dir].Image,b,x,y); } else { Bmp.Draw(rightArmed2.Stationary[dir].Image,b,x,y); Bmp.Draw(torso.Stationary[dir].Image,b,x,y); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(leftArmed2.Stationary[dir].Image,b,x,y); } } if((int)dir>=1 && (int)dir<6) Bmp.Draw(handFile[weapon.HandIndex+(int)dir].Image,b,x,y+offset); } }
public void Draw(Bitmap b, int x, int y, Direction dir, ItemDescriptor weapon) { if (weapon == null) { if ((int)dir < 4) { Bmp.Draw(leftArm.Stationary[dir].Image, b, x, y); Bmp.Draw(torso.Stationary[dir].Image, b, x, y); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(rightArm.Stationary[dir].Image, b, x, y); } else { Bmp.Draw(rightArm.Stationary[dir].Image, b, x, y); Bmp.Draw(torso.Stationary[dir].Image, b, x, y); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(leftArm.Stationary[dir].Image, b, x, y); } } else { if ((int)dir >= 6 || (int)dir == 0) { Bmp.Draw(handFile[weapon.HandIndex + (int)dir].Image, b, x, y + offset); } if (weapon.NumHands == 1) { if ((int)dir < 4) { Bmp.Draw(leftArm.Stationary[dir].Image, b, x, y); Bmp.Draw(torso.Stationary[dir].Image, b, x, y); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(rightArmed1.Stationary[dir].Image, b, x, y); } else { Bmp.Draw(rightArmed1.Stationary[dir].Image, b, x, y); Bmp.Draw(torso.Stationary[dir].Image, b, x, y); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(leftArm.Stationary[dir].Image, b, x, y); } } else { if ((int)dir < 4) { Bmp.Draw(leftArmed2.Stationary[dir].Image, b, x, y); Bmp.Draw(torso.Stationary[dir].Image, b, x, y); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(rightArmed2.Stationary[dir].Image, b, x, y); } else { Bmp.Draw(rightArmed2.Stationary[dir].Image, b, x, y); Bmp.Draw(torso.Stationary[dir].Image, b, x, y); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(leftArmed2.Stationary[dir].Image, b, x, y); } } if ((int)dir >= 1 && (int)dir < 6) { Bmp.Draw(handFile[weapon.HandIndex + (int)dir].Image, b, x, y + offset); } } }
public void Draw(Graphics g, int x, int y, Direction dir, ItemDescriptor weapon) { if (weapon == null) { if ((int)dir < 4) { leftArm.Stationary[dir].Draw(g, x, y); torso.Stationary[dir].Draw(g, x, y); legs.Stationary[dir].Draw(g, x, y); rightArm.Stationary[dir].Draw(g, x, y); } else { rightArm.Stationary[dir].Draw(g, x, y); torso.Stationary[dir].Draw(g, x, y); legs.Stationary[dir].Draw(g, x, y); leftArm.Stationary[dir].Draw(g, x, y); } } else { if ((int)dir >= 6 || (int)dir == 0) { handFile[weapon.HandIndex + (int)dir].Draw(g, x, y + offset); } if (weapon.NumHands == 1) { if ((int)dir < 4) { leftArm.Stationary[dir].Draw(g, x, y); torso.Stationary[dir].Draw(g, x, y); legs.Stationary[dir].Draw(g, x, y); rightArmed1.Stationary[dir].Draw(g, x, y); } else { rightArmed1.Stationary[dir].Draw(g, x, y); torso.Stationary[dir].Draw(g, x, y); legs.Stationary[dir].Draw(g, x, y); leftArm.Stationary[dir].Draw(g, x, y); } } else { if ((int)dir < 4) { leftArmed2.Stationary[dir].Draw(g, x, y); torso.Stationary[dir].Draw(g, x, y); legs.Stationary[dir].Draw(g, x, y); rightArmed2.Stationary[dir].Draw(g, x, y); } else { rightArmed2.Stationary[dir].Draw(g, x, y); torso.Stationary[dir].Draw(g, x, y); legs.Stationary[dir].Draw(g, x, y); leftArmed2.Stationary[dir].Draw(g, x, y); } } if ((int)dir >= 1 && (int)dir < 6) { handFile[weapon.HandIndex + (int)dir].Draw(g, x, y + offset); } } }
public void Draw(Bitmap b, int x, int y, bool underwater, bool male, bool isZombie, bool crouch, bool flying, Direction dir, ItemDescriptor weapon) { BodyPart head = torso; BodyPart legs = this.legs; int offset = 0; if (flyable) { head = flyHead; if (flying) { legs = flyLegs; } } else if (underwater) { if (isZombie) { if (zombie) { head = zombieHead; } } else { head = torso; } } else { if (isZombie) { if (zombie) { head = zombieHead; } } else if (male) { head = maleHead; } else { head = femHead; } } if (crouch) { legs = crouchLegs; offset = (int)(5 * PckImage.Scale); } if (weapon == null) { BodyPart armLeft = rightArm; BodyPart armRight = leftArm; if ((int)dir < 4) { armLeft = leftArm; armRight = rightArm; } Bmp.Draw(armLeft.Stationary[dir].Image, b, x, y + offset); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(head.Stationary[dir].Image, b, x, y + offset); Bmp.Draw(armRight.Stationary[dir].Image, b, x, y + offset); } else { if ((int)dir >= 6 || (int)dir == 0) { Bmp.Draw(handFile[weapon.HandIndex + (int)dir].Image, b, x, y + offset); } BodyPart armLeft = leftArmed2; BodyPart armRight = rightArmed2; //switch arms if one handed if (weapon.NumHands == 1) { armLeft = leftArm; armRight = rightArmed1; } //switch arms if direction if ((int)dir < 4) { BodyPart tmp = armLeft; armLeft = armRight; armRight = tmp; } Bmp.Draw(armRight.Stationary[dir].Image, b, x, y + offset); Bmp.Draw(legs.Stationary[dir].Image, b, x, y); Bmp.Draw(head.Stationary[dir].Image, b, x, y + offset); Bmp.Draw(armLeft.Stationary[dir].Image, b, x, y + offset); if ((int)dir >= 1 && (int)dir < 6) { Bmp.Draw(handFile[weapon.HandIndex + (int)dir].Image, b, x, y + offset); } } }
public void Draw(Graphics g, int x, int y, bool underwater, bool male, bool isZombie, bool crouch, bool flying, Direction dir, ItemDescriptor weapon) { BodyPart head = torso; BodyPart legs = this.legs; int offset = 0; if (flyable) { head = flyHead; if (flying) { legs = flyLegs; } } else if (underwater) { if (isZombie) { if (zombie) { head = zombieHead; } } else { head = torso; } } else { if (isZombie) { if (zombie) { head = zombieHead; } } else if (male) { head = maleHead; } else { head = femHead; } } if (crouch) { legs = crouchLegs; offset = (int)(5 * PckImage.Scale); } if (weapon == null) { BodyPart armLeft = rightArm; BodyPart armRight = leftArm; if ((int)dir < 4) { armLeft = leftArm; armRight = rightArm; } armLeft.Stationary[dir].Draw(g, x, y + offset); legs.Stationary[dir].Draw(g, x, y); head.Stationary[dir].Draw(g, x, y + offset); armRight.Stationary[dir].Draw(g, x, y + offset); // if((int)dir<4) // { // leftArm.Stationary[dir].Draw(g,x,y+offset); // legs.Stationary[dir].Draw(g,x,y); // head.Stationary[dir].Draw(g,x,y+offset); // rightArm.Stationary[dir].Draw(g,x,y+offset); // } // else // { // rightArm.Stationary[dir].Draw(g,x,y+offset); // legs.Stationary[dir].Draw(g,x,y); // head.Stationary[dir].Draw(g,x,y+offset); // leftArm.Stationary[dir].Draw(g,x,y+offset); // } } else { if ((int)dir >= 6 || (int)dir == 0) { handFile[weapon.HandIndex + (int)dir].Draw(g, x, y + offset); } BodyPart armLeft = leftArmed2; BodyPart armRight = rightArmed2; //switch arms if one handed if (weapon.NumHands == 1) { armLeft = leftArm; armRight = rightArmed1; } //switch arms if direction if ((int)dir < 4) { BodyPart tmp = armLeft; armLeft = armRight; armRight = tmp; } armRight.Stationary[dir].Draw(g, x, y + offset); legs.Stationary[dir].Draw(g, x, y); head.Stationary[dir].Draw(g, x, y + offset); armLeft.Stationary[dir].Draw(g, x, y + offset); /* * if(weapon.OneHanded) * { * if((int)dir<4) * { * leftArm.Stationary[dir].Draw(g,x,y+offset); * legs.Stationary[dir].Draw(g,x,y); * head.Stationary[dir].Draw(g,x,y+offset); * rightArmed1.Stationary[dir].Draw(g,x,y+offset); * } * else * { * rightArmed1.Stationary[dir].Draw(g,x,y+offset); * legs.Stationary[dir].Draw(g,x,y); * head.Stationary[dir].Draw(g,x,y+offset); * leftArm.Stationary[dir].Draw(g,x,y+offset); * } * } * else * { * * if((int)dir<4) * { * leftArmed2.Stationary[dir].Draw(g,x,y+offset); * legs.Stationary[dir].Draw(g,x,y); * head.Stationary[dir].Draw(g,x,y+offset); * rightArmed2.Stationary[dir].Draw(g,x,y+offset); * } * else * { * rightArmed2.Stationary[dir].Draw(g,x,y+offset); * legs.Stationary[dir].Draw(g,x,y); * head.Stationary[dir].Draw(g,x,y+offset); * leftArmed2.Stationary[dir].Draw(g,x,y+offset); * } * } */ if ((int)dir >= 1 && (int)dir < 6) { handFile[weapon.HandIndex + (int)dir].Draw(g, x, y + offset); } } }
public void Draw(Bitmap b,int x,int y,bool underwater,bool male,bool isZombie,bool crouch,bool flying,Direction dir,ItemDescriptor weapon) { BodyPart head=torso; BodyPart legs=this.legs; int offset=0; if(flyable) { head = flyHead; if(flying) legs=flyLegs; } else if(underwater) { if(isZombie) { if(zombie) head=zombieHead; } else head=torso; } else { if(isZombie) { if(zombie) head=zombieHead; } else if(male) head=maleHead; else head=femHead; } if(crouch) { legs=crouchLegs; offset=(int)(5*PckImage.Scale); } if(weapon==null) { BodyPart armLeft=rightArm; BodyPart armRight=leftArm; if((int)dir<4) { armLeft=leftArm; armRight=rightArm; } Bmp.Draw(armLeft.Stationary[dir].Image,b,x,y+offset); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(head.Stationary[dir].Image,b,x,y+offset); Bmp.Draw(armRight.Stationary[dir].Image,b,x,y+offset); } else { if((int)dir>=6 || (int)dir==0) Bmp.Draw(handFile[weapon.HandIndex+(int)dir].Image,b,x,y+offset); BodyPart armLeft=leftArmed2; BodyPart armRight=rightArmed2; //switch arms if one handed if(weapon.NumHands==1) { armLeft=leftArm; armRight=rightArmed1; } //switch arms if direction if((int)dir<4) { BodyPart tmp = armLeft; armLeft=armRight; armRight=tmp; } Bmp.Draw(armRight.Stationary[dir].Image,b,x,y+offset); Bmp.Draw(legs.Stationary[dir].Image,b,x,y); Bmp.Draw(head.Stationary[dir].Image,b,x,y+offset); Bmp.Draw(armLeft.Stationary[dir].Image,b,x,y+offset); if((int)dir>=1 && (int)dir<6) Bmp.Draw(handFile[weapon.HandIndex+(int)dir].Image,b,x,y+offset); } }