Skip to content

General mod Questions thread

1484951535470

Comments

  • RaduzielRaduziel Member Posts: 4,714
    @subtledoctor That's an alternative, but what would be the ridiculously annoying route?

    Thanks!
  • kjeronkjeron Member Posts: 2,368
    It would be easier to trigger the bonus when attacked in melee, than when attacking in melee, as every attack against you can be tracked, but attacks you make can only be detected if they hit.
    op177->Op232, Caster/When Attacked, have the subspell target "Original Caster" with it's effect and a small, Enemy-only AoE projectile.
  • RaduzielRaduziel Member Posts: 4,714
    edited March 2019
    @kjeron A couple of questions, if I may:

    1) Why the opcode 177 and the projectile? And where would they enter? I'm failing to understand it. When you said "attacked in melee" I was thinking about:

    Spell A: Opcode 232, p1 = 2 (NearestEnemyOf), p2 = 7 (AttackedBy ('Target')) (...) resource = Spell B

    Spell B: Opcode 321 (Spell B ), Opcode 325 -> all of them with target = 9 timing = 0 duration = 7

    ---

    2) Speaking about Opcode 232, why when we want a thing applied recurrently we use the Condition HP < 102% instead of Condition 10 (every round)?

    ---

    Thanks!
    Post edited by Raduziel on
  • [Deleted User][Deleted User] Posts: 0
    edited March 2019
    The user and all related content has been deleted.
    Post edited by [Deleted User] on
  • kjeronkjeron Member Posts: 2,368
    Raduziel wrote: »
    1) Why the opcode 177 and the projectile? And where would they enter? I'm failing to understand it. When you said "attacked in melee" I was thinking about:
    When using op232 in a spell, it is best to always apply it through op177, as op232 will otherwise block any further attempt to apply that spell, including any effects that proceed it in the spells effect stack when it is applied. This issue does not exist when op232 is used in items.
    Raduziel wrote: »
    Spell A: Opcode 232, p1 = 2 (NearestEnemyOf), p2 = 7 (AttackedBy ('Target')) (...) resource = Spell B
    "AttackedBy()" triggers on any hostile action, at any range. Setting the range in the subspell will produce a feedback message "One of the spells has failed" every time it triggers out of range. Controlling the range through a projectile avoid this issue.
    Raduziel wrote: »
    2) Speaking about Opcode 232, why when we want a thing applied recurrently we use the Condition HP < 102% instead of Condition 10 (every round)?
    Condition 10 crashes when it would trigger.
  • RaduzielRaduziel Member Posts: 4,714
    @kjeron

    Let me see if I understood it:

    Considering a header with target = 5 (self), range = 0 and casting time = 0 for all spells.

    On the CLAB -> Spell A: Opcode 177, p1 = kitmagicnumber, p2 = 9, target = 2, timing = 1, resource = Effect A.

    Effect A: Opcode 232, p1 = 2, p2 = 7, target = 2, timing = 1, resource = Spell B.

    Spell B: Opcode 321, Opcode 325, target = 9, timing = 0, duration = 7 --- here the custom projectile with Enemy Only and 1 unit radius enters.

    Is that correct?
  • kjeronkjeron Member Posts: 2,368
    Effect A: Opcode 232, p1 = 0 (Caster), p2 = 7, resource = Spell B. (target and timing are controlled by op177).
    Projectile radius (trap/explosion): test increments of 16 until you find a radius you like. 16 units = 1 foot.
  • GoidaGoida Member Posts: 118
    Okay, a new question. I have some spells in the back of the store that put the stuff Gorion throws at Sarevok, Tamoco and Co. on that last night to shame. Sure, he tried, but magic missiles and a sphere of something aren't really up to snuff these days. I'd like to rewrite his actions in the cutscene with a few nuclears. What would be the Weidu action for this, to avoid replacing the entire cutscene script?
  • GoidaGoida Member Posts: 118
    edited March 2019
    Also does anybody have suggestions for how to keep down Self-targeted effects of a spell with multiple targets? Each casting, i.e. each target, comes with a special effect, and I only need one. I've tried putting an immunity to this effect inside the Self-centered subspell, but the problem is that the visual is part of the spell's AOE - it's the fragments I need. The subspell itself is empty. Thus, the projectile still happens for every casting, even if the non-existent effects are stopped, which means a truckload more fragments than I like.

    Edit: okay, solved. The trick is to use two subspells for fragments and other AOE effects. The first is without a projectile, casts the second and applies a brief immunity to itself. The second spell is the one that comes with the spectacular AOE, fragments, fireball puffs and anything else you like. This way even spells with 10 targets will only apply their Self-targeted effects once instead of 10 times. Or you can make it somewhat random, e.g. a healing spell cast at Living actor with +1 target for every 3 levels and a Self or Party-targeted subspell that heals some damage to them as well, with a 50% chance inside.
  • RaduzielRaduziel Member Posts: 4,714
    @kjeron Thanks!

    ---

    May I use Opcode 104 with P1 = 50, P2 = 2, Target = 1 and Timing = 9 to permanently halve the amount of XP a creature gains?

    And can I give to a kit an amount of starting proficiencies (and the pace that new ones are gained) different then that of the baseclass?

    Thanks!
  • kjeronkjeron Member Posts: 2,368
    Raduziel wrote: »
    May I use Opcode 104 with P1 = 50, P2 = 2, Target = 1 and Timing = 9 to permanently halve the amount of XP a creature gains?
    What it really does is reduce the creatures effective XP by half, which includes it's current XP and all XP it gains. If the effect were ever removed, their XP would return to it's full value.
    Raduziel wrote: »
    And can I give to a kit an amount of starting proficiencies (and the pace that new ones are gained) different then that of the baseclass?
    Nope - limited to class.
  • The user and all related content has been deleted.
  • RaduzielRaduziel Member Posts: 4,714
    Raduziel wrote: »
    can I give to a kit an amount of starting proficiencies (and the pace that new ones are gained) different then that of the baseclass?

    You could reproduce the entire proficiency system in a dialogue and let certain kits get extra proficiencies that way. :lol:

    Unless the sake of daughter depends on that I prefer to let this boat sail hahaha

    @kjeron Thanks!
  • RaduzielRaduziel Member Posts: 4,714
    Is there a way to sum two base-classes usability flags?
  • [Deleted User][Deleted User] Posts: 0
    edited March 2019
    The user and all related content has been deleted.
  • RaduzielRaduziel Member Posts: 4,714
    Yup, class usability.

    It is for a quick-mod I'm building, not a proper project - more like a quick tutoral. I'll just pick one and move on. I thought that would be just a matter of summing two hex entries.

    Thanks, @subtledoctor !
  • The user and all related content has been deleted.
  • RaduzielRaduziel Member Posts: 4,714
    @subtledoctor Thanks :)

    ---

    Can someone explain those stats to me, please:

    77 MENTALSPEED
    78 PHYSICALSPEED

    Thanks!
  • kjeronkjeron Member Posts: 2,368
    MENTALSPEED is casting speed modifier (opcode 189)
    PHSYICALSPEED is attack speed modifier (opcode 190, Proficiency) (not APR)
  • RaduzielRaduziel Member Posts: 4,714
    Thanks!

    Is there a STAT for Movement Rate?

    My bet was no PHYSICALSPEED, but was wrong.
  • kjeronkjeron Member Posts: 2,368
    Raduziel wrote: »
    Is there a STAT for Movement Rate?
    Not AFAIK. I suspect it's not really a creature's stat, as it is tied directly to the animation.
  • RaduzielRaduziel Member Posts: 4,714
    kjeron wrote: »
    Raduziel wrote: »
    Is there a STAT for Movement Rate?
    Not AFAIK. I suspect it's not really a creature's stat, as it is tied directly to the animation.

    Damn. Thanks.

    Is there any way to check with Opcode 318 if the creature's movement is greater than the original value (or 9)?
  • kjeronkjeron Member Posts: 2,368
    Raduziel wrote: »
    Is there any way to check with Opcode 318 if the creature's movement is greater than the original value (or 9)?
    Not aside from haste.
  • RaduzielRaduziel Member Posts: 4,714
    kjeron wrote: »
    Raduziel wrote: »
    Is there any way to check with Opcode 318 if the creature's movement is greater than the original value (or 9)?
    Not aside from haste.

    Damn. Thanks.
  • RaduzielRaduziel Member Posts: 4,714
    Ok, here's something that I'm sketching and I would like some thoughts.

    The objective: Make Free Action respect Haste, Improved Haste and positive Movement Modifier

    The plan:

    1) Scan for all items and spells that give a positive Movement Modifier. Patch them with Opcode 328 so they can set STATE_HASTED while equipped/while the duration lasts. For the spells, those that give Opcodes 16 or 317 are not necessary (as they already set this).

    2)

    2.1) In the Free Action spell and equipped Free Action items, remove all effects related to Haste (remove icon, prevent icon, protection from string, opcode 101 and relevant opcodes 206).

    2.2) Remove Opcode 126 from those.

    2.3) Add as the last effect Opcode 318 checking for STATE_HASTED and granting immunity to this.spl or this.itm if this state is a match.

    2.4) Readd Opcode 126, so it gets below Opcode 318.

    ---

    Viable?
  • _Luke__Luke_ Member, Mobile Tester Posts: 1,535
    @Raduziel

    I don't think you can set STATE_HASTED with opcode #328 (AFAIK, only opcodes #16 and #317 can set STATE_HASTED.....)
  • RaduzielRaduziel Member Posts: 4,714
    edited March 2019
    Luke93 wrote: »
    @Raduziel

    I don't think you can set STATE_HASTED with opcode #328 (AFAIK, only opcodes #16 and #317 can set STATE_HASTED.....)

    @Luke93

    Damn. It is a downer, for sure. There must be some way to refrain FreeAction-ish spells and effects from setting the movement modifier when it is > 9.

    I'm open to ideas, everyone.

    (Pretty sure that @subtledoctor will say something related to SPLPROT - apparently he can even bake a cake with SPLPROT)

    ---

    Quick question:

    Is there any difference between using " or ~ ?

    And / or \ ?

    Thanks.
    Post edited by Raduziel on
  • _Luke__Luke_ Member, Mobile Tester Posts: 1,535
    edited March 2019
    Raduziel wrote: »
    (Pretty sure that @subtledoctor will say something related to SPLPROT - apparently he can even bake a cake with SPLPROT)

    If there's no stat for Movement Rate, then I fear SPLPROT.2da is of no help (unless I'm missing something of course.....)
  • _Luke__Luke_ Member, Mobile Tester Posts: 1,535
    edited March 2019
    Raduziel wrote: »
    Is there any difference between using " or ~ ?

    None, probably. For instance, you can write
    WRITE_LONG	0x008	RESOLVE_STR_REF ("Blah")		// Unidentified name
    
    or
    WRITE_LONG	0x008	RESOLVE_STR_REF (~Blah~)	// Unidentified name
    
  • RaduzielRaduziel Member Posts: 4,714
    Luke93 wrote: »
    Raduziel wrote: »
    Is there any difference between using " or ~ ?

    None, probably. For instance, you can write
    WRITE_LONG	0x008	RESOLVE_STR_REF ("Blah")		// Unidentified name
    
    or
    WRITE_LONG	0x008	RESOLVE_STR_REF (~Blah~)	// Unidentified name
    

    Actually yesterday/this morning I've discovered that there is a problem.

    Dumb me opened all the kits' components files in Notepad++ and did Replace All " -> ~

    Not happy with this stupidity I did the same replacing \ for /.

    A lot of things crashed.

    Altering in scripts, for example, can't use ~. They need ". Example:
    ACTION_IF GAME_IS ~bgee iwdee eet~ BEGIN
    
    <<<<<<<< .../inlined.baf
    
    IF
    	CheckStat(Player1,0,XP)
    	Kit(Player1,RATormFC)
    	TriggerOverride(Player1,Global("RAHPFIX","LOCALS",0))
    THEN
    	RESPONSE #100
    		ApplySpellRES("RAHPFIX",Player1)
    		ActionOverride(Player1,SetGlobal("RAHPFIX","LOCALS",1))
    		Continue()
    END
    

    All is fine.
    ACTION_IF GAME_IS ~bgee iwdee eet~ BEGIN
    
    <<<<<<<< .../inlined.baf
    
    IF
    	CheckStat(Player1,0,XP)
    	Kit(Player1,RATormFC)
    	TriggerOverride(Player1,Global(~RAHPFIX~,~LOCALS~,0))
    THEN
    	RESPONSE #100
    		ApplySpellRES(~RAHPFIX~,Player1)
    		ActionOverride(Player1,SetGlobal(~RAHPFIX~,~LOCALS~,1))
    		Continue()
    END
    

    Satan released upon Earth.

    A similar thing happens with / and \
    COPY_EXISTING_REGEXP ~.*\.itm~ override
    

    All is fine.
    COPY_EXISTING_REGEXP ~.*/.itm~ override
    

    You and your mom got drunk and started making out.
Sign In or Register to comment.