Jump to content


Photo

Opcode #83 and Projectl.ids


9 replies to this topic

#1 Grammarsalad

Grammarsalad
  • Modders
  • 445 posts
  • Gender:Male

Posted 14 July 2016 - 11:14 AM

I'm sure that I'm missing something here, but bringing this up just to be sure.

 

I was using #83 to set a protection vs. the Sol's searing orb projectile in EE.  When I look at the actual object, I see that it is listed as projectile "258".  However, when I enter 258 into param2, I see that it protects vs. 'the new hold necromancy' (see the screenshot far left).  I thought that this was a hex vs decimal thing, but that didn't turn out to be correct.  Rather, 'the new hold necromancy' projectile is merely the next projectile as listed in projectl.ids.  If I set pram2 to 257, then it appears to correctly project against 'PFIRE3'.  I decided to check the first entry in the actual item, and I see that it is "1-none" whereas in projectl.ids I see "0x1 ARROW" (also in the screenshot to the right and center respectively.).  Doesn't 1 = 0x1?  Should the effect protect vs "258" or "257"?  

(edit: Okay, I don't know how to add attachments, but this can easily be checked for any item and projectl.ids...)

edit2: If I set param2 to "1" is says that it protects from "ARROW"


Edited by Grammarsalad, 14 July 2016 - 11:30 AM.


#2 Grammarsalad

Grammarsalad
  • Modders
  • 445 posts
  • Gender:Male

Posted 14 July 2016 - 11:24 AM

projectile.jpg



#3 lynx

lynx
  • Modders
  • 2990 posts
  • Gender:Male
  • Location:Ljubljana, Slovenija

Posted 14 July 2016 - 11:30 AM

yes, there's an offset of 1*. Why is that so confusing?

 

* none for missile.ids IIRC


GemRB - IE anywhere.
Mages needed! Looking for Planescape: Torment testers
Market android version IS NOT SUPPORTED ANYMORE: reported bugs will be ignored! Still looking for builders ...

#4 Grammarsalad

Grammarsalad
  • Modders
  • 445 posts
  • Gender:Male

Posted 14 July 2016 - 11:35 AM

yes, there's an offset of 1*. Why is that so confusing?

 

* none for missile.ids IIRC

Okay, so that is what that means...good to know



#5 Grammarsalad

Grammarsalad
  • Modders
  • 445 posts
  • Gender:Male

Posted 14 July 2016 - 11:37 AM

Wait, pretend that I am not a computer programmer.  What does that mean?

 

Edit: Ahh, I see that items read missile.ids...

 

That helps a bit, I suppose.


Edited by Grammarsalad, 14 July 2016 - 11:40 AM.


#6 kjeron

kjeron
  • Members
  • 66 posts

Posted 14 July 2016 - 11:44 AM

Don't know what it means to a programmer, but as a modder it means Opcode 83 and 197 (immunity and reflection) cannot effect a spell or ranged* weapon using Projectile "0", since a value of "0" in opcode 83/197 equals a value of "1" in a item/spells projectile field.

 

* Melee weapons default to Projectile "1" regardless of the value set.



#7 Grammarsalad

Grammarsalad
  • Modders
  • 445 posts
  • Gender:Male

Posted 14 July 2016 - 11:53 AM

Don't know what it means to a programmer, but as a modder it means Opcode 83 and 197 (immunity and reflection) cannot effect a spell or ranged* weapon using Projectile "0", since a value of "0" in opcode 83/197 equals a value of "1" in a item/spells projectile field.
 
* Melee weapons default to Projectile "1" regardless of the value set.

Thanks k.

#8 Avenger

Avenger
  • Modders
  • 3711 posts
  • Gender:Male
  • Location:Hungary

Posted 15 July 2016 - 09:54 PM

This projectile id -1 thing is indeed annoying, we inherited this from the original IE and there is no way to fix it without breaking everything already done.

@Kjeron - there is no projectile 0. A value of 0 would mean no projectile.

@Grammersalad - well, missile.ids is not read by the engine at all, it might have been used by some in-house editor at Bioware, and dltcep also uses it, only to display sane names. Modders are encouraged to update missile ids according to projectl.ids (mind the -1 difference)



#9 Fiann of the Silver Hand

Fiann of the Silver Hand
  • Modders
  • 387 posts
  • Gender:Male
  • Location:MURICA

Posted 15 July 2016 - 11:13 PM

@Grammersalad - well, missile.ids is not read by the engine at all, it might have been used by some in-house editor at Bioware, and dltcep also uses it, only to display sane names. Modders are encouraged to update missile ids according to projectl.ids (mind the -1 difference)

I think NI uses it in selection boxes to show the more descriptive names instead of the pro file names.

#10 kjeron

kjeron
  • Members
  • 66 posts

Posted 16 July 2016 - 01:36 AM

@Kjeron - there is no projectile 0. A value of 0 would mean no projectile.

Yes, but it's still a valid projectile value for items, spells, and projectile explosions.  Is there some other functional difference between the using a projectile value of 0 or 1 other than interaction with these 2 opcodes?  They are both hardcoded to effect an instant-hit, no-animation, no-sound, single-target.

 

The only other projectile field I know of that doesn't use the +1 offset(and thus cannot use the "no projectile" projectile value 0) is the Secondary Projectile(0x214) of an Area of Effect *.pro file, which makes sense as that field is visual-only, its projectile doesn't carry the effects.





Reply to this topic



  


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users