Full Version : changing bow special moved..
xmlspawner >>Scripting Support >>changing bow special moved..


<< Prev | Next >>

Sunshine- 07-15-2006
I tried to change the special moves on bow.cs


I placed this

public override WeaponAbility PrimaryAbility{ get{ return WeaponAbility.ParalyzingBlow; } }
public override WeaponAbility SecondaryAbility{ get{ return WeaponAbility.MortalStrike; } }


CODE
using System;
using Server.Network;
using Server.Items;

namespace Server.Items
{
[FlipableAttribute( 0x13B2, 0x13B1 )]
public class Bow : BaseRanged
{
 public override int EffectID{ get{ return 0xF42; } }
 public override Type AmmoType{ get{ return typeof( Arrow ); } }
 public override Item Ammo{ get{ return new Arrow(); } }

 public override WeaponAbility PrimaryAbility{ get{ return WeaponAbility.ParalyzingBlow; } }
 public override WeaponAbility SecondaryAbility{ get{ return WeaponAbility.MortalStrike; } }

 public override int AosStrengthReq{ get{ return 30; } }
 public override int AosMinDamage{ get{ return 16; } }
 public override int AosMaxDamage{ get{ return 18; } }
 public override int AosSpeed{ get{ return 25; } }

 public override int OldStrengthReq{ get{ return 20; } }
 public override int OldMinDamage{ get{ return 9; } }
 public override int OldMaxDamage{ get{ return 41; } }
 public override int OldSpeed{ get{ return 20; } }

 public override int DefMaxRange{ get{ return 10; } }

 public override int InitMinHits{ get{ return 31; } }
 public override int InitMaxHits{ get{ return 60; } }

 public override WeaponAnimation DefAnimation{ get{ return WeaponAnimation.ShootBow; } }

 [Constructable]
 public Bow() : base( 0x13B2 )
 {
  Weight = 6.0;
  Layer = Layer.TwoHanded;
 }

 public Bow( Serial serial ) : base( serial )
 {
 }

 public override void Serialize( GenericWriter writer )
 {
  base.Serialize( writer );

  writer.Write( (int) 0 ); // version
 }

 public override void Deserialize( GenericReader reader )
 {
  base.Deserialize( reader );

  int version = reader.ReadInt();

  if ( Weight == 7.0 )
   Weight = 6.0;
 }
}
}


But when you click the special move it goes right back off and you can not use the move...any suggestions?
on how I can fix this please

ArteGordon- 07-15-2006
that looks like the default bow.cs. Did you try to replace the moves with something else or do you mean that your default bow special moves dont work?

Sunshine- 07-15-2006
Yes I am stupid sorry ..posted my test shard and forgot that is not the latest copy


public override WeaponAbility PrimaryAbility{ get{ return WeaponAbility.ArmorIgnore; } }
public override WeaponAbility SecondaryAbility{ get{ return WeaponAbility.MovingShot; } }

Those are the ones I added and replaced

public override WeaponAbility PrimaryAbility{ get{ return WeaponAbility.ParalyzingBlow; } }
public override WeaponAbility SecondaryAbility{ get{ return WeaponAbility.MortalStrike; } }


but they will not work ...all I did was remove PB and MS with the 2 I listed



ArteGordon- 07-15-2006
the problems is that the special abilities for weapons are hardcoded on the clientside. When you try to select the ability on the client, it still sends the hardcoded ability id back and when that doesnt match with the ability that you have assigned on the server, then it ignores it.

bottom line is that I dont know a simple way around it.

Sunshine- 07-16-2006
QUOTE (ArteGordon @ July 15, 2006 06:47 pm)
the problems is that the special abilities for weapons are hardcoded on the clientside. When you try to select the ability on the client, it still sends the hardcoded ability id back and when that doesnt match with the ability that you have assigned on the server, then it ignores it.

bottom line is that I dont know a simple way around it.

Ok thanks hun appreicate it as always.......Thanks soo very much for always being soo kind to me even when I am totally ditsy