Index for element ID

Am I correct in thinking that the index for element ID starts at 0, not at 1?

Thanks.
Isn't normal attack element -1? I thought I remembered one script that had to treat normal attacks as -1 for some reason.
AFAIK, 0 is for none. The entries on the database don't use the 0 index, if it says 1 it uses the index 1.
Well I know that params, exparams and sparams, begin at 0, so that PHA is 3, even though it's the 4th on the list (I've just been using it, that's why that example comes to mind), and I seem to be getting odd results with elements beginning at 1, which is why I thought they might be 0 as well.
Well, you don't specify those params in the database, they're already there. I was talking about the ones that you specify on the database. 🙂


Technically, they all do start with 0. It's just that for those entries, 0 is either reserved (like in the case of elements) or totally unused (for most of the other entries that y ou specify).
I do need to use them for Yanfly's Element Absorb script where I have to specify the element by its ID.  Which is why I need to know precisely if element IDs start at 0 or at 1, as I'm getting slightly odd things happening, and I want to eliminate one possible source of the error.
Technically, they start at -1, but -1 is for physical attack, and 0 is for none. For the script you mentioned I've had no problem with it as long as I use the same id as listed in the system tab of the database for the element.
Thanks for the clarification.

That's one possible cause crossed off the list then.

Original thread: https://forums.rpgmakerweb.com/threads/index-for-element-id.41680/