argent77 Posted March 30, 2018 Posted March 30, 2018 (edited) I'm trying to make a consumable item that does only work outdoors. So I tried to use opcode 318 (Protection from spell) with splprot.2da type 0x106 (areatype) where area type doesn't match bit 0 (OUTDOORS). NOT_OUTSIDE 0x106 0x01 9 But it doesn't seem to work. I also tried different match operators without success. Does this particular type even work?For now I have to resort to the helper creature approach, but I'd rather do without it. Edited March 31, 2018 by argent77 Quote
subtledoctor Posted March 30, 2018 Posted March 30, 2018 318/324/326 check the splprot status of the target of the spell. I'm not sure whether/how you can reasonably use areatype with a target. (You can do a bit of fun target hacking, like I have a 248 on-hit effect wherevthe resulting .eff uses target 9 (original caster) and the resulting .spl uses target 2 (preset target) so now the on-hit effect evaluates the state/stat/etc. of the caster, to conditionally cast a spell at the target.) Quote
argent77 Posted March 30, 2018 Author Posted March 30, 2018 I'm not so sure if target is really always needed. There are also checks for time of day and current chapter, which both don't really need a target. Unfortunately there are no area type checks in any of the vanilla EE games, so I can't really say if the problems lies with the splprot type or my implementation of it. Quote
Jarno Mikkola Posted March 30, 2018 Posted March 30, 2018 (edited) Unfortunately there are no area type checks in any of the vanilla EE games, so I can't really say if the problems lies with the splprot type or my implementation of it. Erhm, the druid call lightning has ... the games .spl flag's has outdoors only flag. Edited March 30, 2018 by Jarno Mikkola Quote
Roxanne Posted March 30, 2018 Posted March 30, 2018 I'm trying to make a consumable item that does only work outdoors. So I tried to use opcode 318 (Protection from spell) with splprot.2da type 0x106 (areatype) where area type doesn't match bit 0 (OUTDOORS). NOT_OUTSIDE 0x106 0x01 9 But it doesn't seem to work. I also tried different match operators without success. Does this particular type even work? For now I have to resort to the helper creature approach, but I'd rather do without it. Does this not work? Quote
argent77 Posted March 30, 2018 Author Posted March 30, 2018 Not in my case. In addition to "Outdoors" I'm using a custom area type (added via areatype.ids) that has to be checked too. Using splprot.2da area type check would be perfect for my needs, if I could figure out how to make it work. Quote
Avenger Posted March 30, 2018 Posted March 30, 2018 I... think there is a bug with the area type check Quote
argent77 Posted March 31, 2018 Author Posted March 31, 2018 I... think there is a bug with the area type check That's too bad. It means I have to keep using the helper creature for a while. Quote
Jarno Mikkola Posted March 31, 2018 Posted March 31, 2018 I... think there is a bug with the area type check That's too bad. It means I have to keep using the helper creature for a while. Depending on what you mean, you could use the area's own script as the "mark", as you can extend the script file with the needed scripting to do the actions... but that might be exactly what you try to avoid, I suppose. Quote
subtledoctor Posted March 31, 2018 Posted March 31, 2018 There are other things you could do. You could extend the area scripts fir whatecer areas you're talking about to apply a spellstate to PCs while they are there. And then use 326/splprot to filter by that spellstate. Still uses scripting, but it doesn't rely on firing a script (through a creature) as part of a spell being cast. Which for some reason I like to avoid. Quote
Galactygon Posted April 3, 2018 Posted April 3, 2018 There are a limited number of splstates (255) so I would only use new slots sparingly. Quote
subtledoctor Posted April 3, 2018 Posted April 3, 2018 Well, whose fault is that? There are about 100 free spellstates, and about 6 mods which add them. The situation is okay, for the time being. Quote
argent77 Posted April 3, 2018 Author Posted April 3, 2018 (edited) Using a helper creature works well enough for now. There is a random delay between using the item and the helper creature script being fired, but it's small enough to be tolerable. I'll switch over using splprot effects when the area type check has been fixed. Edited April 3, 2018 by argent77 Quote
hook71 Posted April 14, 2018 Posted April 14, 2018 @argent77 - Could you test if this works better in the 2.5.15.1 build (current beta for BG:EE)? Quote
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.