Forum > Serverside Modding

Custom Stances

(1/1)

reidospalas:
Hey guys, i'm doin' some own jobs and i didn't know how to solve this issue, i want make some spells requires custom stances spells that i made.
Exemple > Priest Shadowform, to use some custom spells requires player be on shadowform to cast it.
Thats work in same way but using custom Stances, i tried adding new stances on SpellAuraEffects.cpp, then added Shapesshifts masks values for each new Form case, but didn't worked too,


Someone know how to make it possible?

Thats what exactly what i was trying to make
I've trying adding the mask values for it, but it was requering all the stances forms and didn't worked while in new form_stance


[COLOR="silver"]- - - Updated - - -[/COLOR]

If someone know how to make it possible i'll pay for this job

Official post: http://www.ac-web.org/forums/showthread.php?234446-(PAID)-Custom-Stances-requires

schlumpf:
note that masks are limited in bit width. the fact you added 0x21 = 33 implies that the mask variable is more than 32 bits. It likely is not. Thus rather than requiring your new bit, it requires crap.

You can try putting your new value somewhere in between. Based on that screenshot, 5 and x17, x18 are unused. If they are, you can reuse those ids.

reidospalas:
The problem wasn't with masks, but the flags won't work ingame, i tried using my custom one and it just attach all forms like on screenshot

reidospalas:
BUMP!!

Grymskvll:
Did you try what Schlumpf suggested and just use one of the unused shapeshift IDs? I just tried it and it seemed to work fine.

How did you even set the Stances mask for Void missile to such a high value (assuming you did it right)? I tried setting a spell to use a 33rd shapeshift ID, but all the editors/converter I tried refused the value because of the reason Schlumpf mentions.

Are you setting the mask properly? For example, to use the 5th shapeshift ID, you set the Stances mask to:

--- Code: ---Stances = 1 << (5-1)
Result:
dec 16
hex 0x10
bin 0001 0000 i.e. the 5th bit

--- End code ---

Or for multiple forms:

--- Code: ---Stances = (1<<(5 - 1)) | (1<<(32 - 1))
Result:
dec 2147483664
hex 0x80000010
bin 10000000000000000000000000010000 i.e. the 5th and 32nd bits

--- End code ---

Bit calculation: https://www.wolframalpha.com
Dec to hex (for inputting in Spell.dbc): https://www.binaryhexconverter.com/decimal-to-hex-converter
Dec to bin (if you want to verify): https://www.binaryhexconverter.com/decimal-to-binary-converter

Navigation

[0] Message Index

Go to full version