Pirate Skills Flags !!

11/10/2012 16:14 abdeen#1
Hello Elitepvpers Members .

i am working on Pirate skills , i just wanna to know Skills flags IDs

or a way to find them , how ?

Thanks :)
11/10/2012 17:25 pro4never#2
All flags are stored in stateff.ini
All skill ids are stored in magictype.dat
11/10/2012 17:38 abdeen#3
Quote:
Originally Posted by pro4never View Post
All flags are stored in stateff.ini
All skill ids are stored in magictype.dat
Thanks Pro , there another question please . how do i convert the id to const ulong ?

Like here is
PHP Code:
StatuseEffect.ini 
PHP Code:
17 Reflect NULL -
and in the source its like this

PHP Code:
ReflectMelee 0x20000
11/10/2012 18:45 |xabi|#4
120
121
11/10/2012 18:52 abdeen#5
Quote:
Originally Posted by |xabi| View Post
120
121
I`ll try them , thanks anyway ....
11/10/2012 19:57 pro4never#6
Quote:
Originally Posted by abdeen View Post
Thanks Pro , there another question please . how do i convert the id to const ulong ?

Like here is
PHP Code:
StatuseEffect.ini 
PHP Code:
17 Reflect NULL -
and in the source its like this

PHP Code:
ReflectMelee 0x20000
You need to understand how bit flags work.

I've written about it before but I'm so bored at work so here's the basic rundown.


All numbers stored on a computer are in binary. Lets post a quick conversion table for the example you used of reflect.


Decimal (base 10): 131072
Hexidecimal (base 16): 0x20000
Binary ( base 2): 100000000000000000

Now you'll notice that in stateff.ini it refers to Reflect as being 17. This means that the status effect controlling Reflect (on or off) is the same as

1 shifted to the left by 17 bits
1 << 17


This is important because status effects are essentially a 'pool'. They are a chunk of memory dedicated to certain bits being either active or inactive (1 or 0). This notation lets us quickly and efficiently run bit operations to determine or change specific effects within this section of memory. We are ONLY concerned with the status of this single bit. Hexidecimal (or even worse, decimal) values are very misleading to use as constants/enumerators as they mask what's going on behind the scenes and really offer zero benefit.
11/17/2012 16:54 abdeen#7
How to fix BlackbeardsRage and Cannon Barrage Skills ?