did you add it to itemassistant.java?
|
Hi, I was wondering how I would add a special bar to the toxic staff of the dead. I've added it the weapon interface, which is this:
Spoiler for Code:
I then added case 340: for the special bar on weaponinterfaces.java and client.java, I've set my toxic staff to use the TOXIC_STAFF interface in my items.json file, I added in a CombatSpecial.java for the toxic staff,
Within weaponinterfaces.java I also set it to check if it's a regular staff or a toxic staff as follows:
Spoiler for Code:
I've added in a definiton for TOXIC_STAFF in weaponinterface.java which is as follows:
Spoiler for Code:
I am fairly positive all IDs I am using are correct, I went in and checked interface 328 to confirm.
I also added this in for the toxic staff so it used correct animations when attacking, but I do not believe it has any affect on the special bar appearing. (FightType.java)
Spoiler for Code:
I have also created a ToxicStaffCombatMethod for the special attack.
So, I do not know what I am missing, if anyone could help me out with telling me where I need to add something I would greatly appreciate it.
did you add it to itemassistant.java?
I wish i could help more than this but its all i got; try looking for an item id with a special bar & see where that id is used. If you must, remove that id and compile/run your source to see if the bar goes away. Then you know where to add your item id. dont be scared to break your code to learn more about it. Aslong as you know how to fix it
Alright I tried this, in CombatSpecial.java there is the Armadyl Godsword definition, as follows:
Spoiler for Code:
If I remove the CombatSpecial.java entry, it removes the special bar ingame, the entry I have for the toxic staff is this:
Spoiler for Code:
I've tried to change it around, editing some numbers for my TOXIC_STAFF_OF_THE_DEAD, and looking at how other items have their specials defined, but still nothing. I'll keep trying though, thanks for the input.
EDIT: When I change my WeaponInterfaces.java entry to match the entry for the whip, I get a special bar, so I now need to figure out why my other entry didn't work.
When I switched it to a different interface, 6103, the staff interface without autocast, the special bar appeared, but the interface with autocast doesn't. If anyone knows why this may be please tell me, I couldn't see a difference when I looked into the editor and inspected each of the models/spirits/texts for both interfaces.
Knowing it's a ruse base look at CombatSpecial.java under com.ruse.world.content.weapon.CombatSpecial.java should look something like this:
It's defined like this
But the problem isn't with combatspecial.java, it's within weaponinterfaces.java, at the moment I have TOXIC_STAFF defined like this:
Spoiler for Code:
Which is interface 328 w/ it's IDs, and it doesn't apply a special bar.
But if I use interface 6103, defined like this:
Spoiler for Code:
It puts the special bar, I've also tried it with the whip interface and a special bar was there as well. The problem with using 6103 is it lacks the autocast option, which the toxic staff should have.
I've checked the interfaces numerous times and I am fairly certain I am using the correct IDs for 328, so I do not know why it isn't showing a special attack bar while all the other interfaces are.
Same issue for me, I can add the special attack bar but not have the spec bar and the autocast options. Does anyone have the correct id or whatever to fix this?
« Previous Thread | Next Thread » |
Thread Information |
Users Browsing this ThreadThere are currently 1 users browsing this thread. (0 members and 1 guests) |