K4thos Posted February 15, 2019 Share Posted February 15, 2019 (edited) Quote 0x4089 OR(I:OrCount*)Returns true if any of the next 'OrCount' triggers returns true. from the IESDP description you may assume that OR works exactly the same in IWD2 as in other IE games. This is not the case. I've noticed that in IWD2 the first found trigger within Or declaration that returns true ends the Or loop. In other EE games all triggers within OR are checked 1 by 1 regardless if true match is found. It matters for things like targeting (object referencing set via See, Attacked etc.) and trigger priority (reversed). If this was already known and there is a topic that discusses obscure changes like this please leave a link here. edit: changed the topic name to more general one. Edited February 17, 2019 by K4thos Quote Link to comment
lynx Posted February 15, 2019 Share Posted February 15, 2019 I'm surprised at the opposite actually. Quote Link to comment
Jarno Mikkola Posted February 15, 2019 Share Posted February 15, 2019 So you are telling that the SCS would have been better within the IWD2 engine. Quote Link to comment
DavidW Posted February 15, 2019 Share Posted February 15, 2019 1 hour ago, Jarno Mikkola said: So you are telling that the SCS would have been better within the IWD2 engine. ? Quote Link to comment
Jarno Mikkola Posted February 15, 2019 Share Posted February 15, 2019 I am talking about processing speed here. No 5 minutes to render 1 fresh world stage at worst, cause the OR would allow things to check at priority stages... and so forth and so on. I'm sure you get that, now. Quote Link to comment
DavidW Posted February 15, 2019 Share Posted February 15, 2019 I don't think it would make any material difference, OR() blocks aren't a significant source of slowdown in SCS. Quote Link to comment
K4thos Posted February 17, 2019 Author Share Posted February 17, 2019 (edited) Another not so obvious scripting difference in IWD2 engine: SetGlobal and IncrementGlobal in IWD2 sets the variable during the same script run, not in the next one, like in other IE games. For example this code: IF Global("Marked","LOCALS",0) THEN RESPONSE #100 SetGlobal("Marked","LOCALS",1) FloatMessage(Player1,1) // Ettin Continue() END IF Global("Marked","LOCALS",0) THEN RESPONSE #100 SetGlobal("Marked","LOCALS",1) FloatMessage(Player1,2) // Beetle END prints only the first message. Edited February 17, 2019 by K4thos Quote Link to comment
K4thos Posted February 17, 2019 Author Share Posted February 17, 2019 (edited) Unlike other IE games (at least EE ones) IWD2 AttackedBy trigger works correctly with nested objects. This one sounds more like an engine bug in other engine variants though, so I've also reported it on Beamdog redmine. If anyone is aware about other triggers with the same problems please post them here. Edited February 17, 2019 by K4thos Quote Link to comment
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.