1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Help me create Flow

Discussion in 'General Discussion' started by mrwinfree, Feb 25, 2018.

  1. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
    Good morning all and thank you in advance for any assistance.

    Okay, I have resigned myself to the reality that I will need to learn some basic coding techinques. So, here are a few things I really need help with:
    Cure/damage spells (fixed dice with level based addition to total)
    Damage spells (# of dice based on caster level)
    Buff spells (duration based on caster level)

    How to incorporate Templates in the Flow to appear automagically when an AoE spell/ability is used.

    Special abilities with limited use based on class level (fervor, wild shape, channel positive energy, etc) @vanith provided an example but if I have two characters using this Flow, according to Vanith they both will pull from this fixed pool of uses.

    Okay, that should be enough to keep me busy for a while. I will be self-educating on Java Scripting but as I really do not want to become a coder, my heart just isn't into it! I'd rather stick to Nursing.
     
    #1 mrwinfree, Feb 25, 2018
    Last edited: Feb 25, 2018
  2. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    That's not correct, each will get their own pool.

    Not clear on what you are trying to create, can you clarify that more?
     
  3. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
    Yes, I think I can. I want functional spells. I want functional magic items. I want functional special abilities. Currently these items in the Rules Library do not function.

    I want to populate the Flow with the spells, special abilities, supernatural abilities, equipment, etc for those most commonly used by my player group. Prior to 7.x I had a fairly workable list of effects (spell, ability, etc) which I was able to deploy as needed.

    Since the change to the feature/flow system, I have not been able to create any functional 'Flow' I had been hoping for more detail in the D20 Guide but that remains a WIP. So from my standpoint of a 'non-coder', the functionality of D20pro has acutally diminished. I can see the potential for great things but I have returned to using this software essentially as a map that can be shared across the internet.

    I apologize if I misunderstood the content of the post from @vanith and now that I try to find it again, alas I cannot. no biggie. I do see several spells posted by @Nezzeraj and I will look to those for examples too. Thanks for support. I am just getting frustrated.
     
  4. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
  5. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    upload_2018-2-25_16-17-49.png

    should work alright.
     
  6. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
    I tried that. Made the change to getCasterTotalLevels() The spell cast without a hitch, however the duration, when viewed in the Mini Window > Effects, continues to read 0 (zero). In the Decision Window > Apply GM Feature, when I click on the effect it opens to show a Flow screen which then shows the effect of +4 strength enhancement but there is no duration box visible here. I don't know if that is germane but thought I would throw it out there.
     
  7. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
    Screenshot of effect on mini.
     

    Attached Files:

  8. vanith

    vanith Member

    Joined:
    Jan 22, 2011
    Messages:
    151
    Likes Received:
    8
    To weigh in, I'm not doubting Krillon's excellent skills with his scripting. I've never gotten that script to work with dealing with pulling levels and applying a duration. Try hard coding it to a duration and see if that helps. I know that when you start pulling in scripts, you have to check your script library in the rules Library to see if that exists. I have it in my library, but I don't dabble in it because that's a rabbit hole that I get lost and confused in really fast.
    upload_2018-2-25_23-20-11.png
     
  9. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    ha, I'm but a layman, I don't have skillz :p

    the script should read.

    upload_2018-2-26_1-46-47.png
     
  10. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    and yes, anytime you see someone use a function call such as getCasterTotalLevels(), you need to make sure that function call actually exists in your Rules Library -> Scripts.
     
  11. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    I believe that was a bug (since squashed in 3.7.10).
    The duration was there, just not shown properly.
     
  12. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
    Sorry but I just realized I missed the first step when I started this Thread!
    D20pro: 7.2.10
    OS: X 10.13.3
    The problem is reproducible. I think it is an I/O (idiot operator) Error.
    The problem: I cannot create functional spells/magic items/special abilities in this Feature/Flow system.

    Okay, now that is out of the way. Let us return to the lesson at hand.
    @Krilion_GD, I have no doubt of your skillz (sic). Mine however are severely lacking. I did check the script library, as was suggested, for the getCasterTotalLevels(), it was there and returned as Valid when I clicked the validate button. I'm hearing you that the duration display is a bug that was fixed only in this instance, it is not.

    @vanith I appreciate your input and your examples. I too lack Alice's adventurous spirit when it comes to coding! I think your suggestion of hard coding is probably the best answer at this time. I was hoping to automate some of the mundane issues like advancing level-dependent variables. But it worked the old way, so to the old way I return, at least for game night purposes.

    I think for the time being, I shall continue to peruse the D20pro Guide and follow along on these forums and Discord. I will jump back in when the waters are not so far over my head.
    Thanks All.
    Mickey
     
  13. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    that was an 'I think it is/was' off the top of my head (it may be that it's fixed in 3.7.3 and not 3.7.2.10). I'll ask Owlbear when I speak to him.

    bear in mind if you hardset the number that number will be used by anything that uses that spell (whether that is a benefit or loss to that token respective of level or not).
     
  14. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    Your welcome to ping me on Discord, be happy to screen share a tut for you if you like.
     
    mrwinfree likes this.
  15. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
    Okay, after conversation with @Krilion_GD I have made a stab at scripting. So I used info from @vanith as well and created a valid script. However, it doesn't work. I use this as a Trait for my cleric. it can be used, it creates a template that selects the characters within its radius. Then when executed, it does not heal damage as expected. Can someone take a look and help me figure out where this is going sideways. Thanks.
     

    Attached Files:

  16. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    sure, happy to take a look.. I'll grab it and look in the morning over coffee
     
  17. mrwinfree

    mrwinfree Member

    Joined:
    May 1, 2016
    Messages:
    71
    Likes Received:
    2
    great thanks.
     
  18. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    So your Feature can be simplified as

    upload_2018-3-9_6-40-28.png

    Then the trait to fire it, written as

    upload_2018-3-9_6-36-5.png

    upload_2018-3-9_6-36-25.png

    added to the token and toggled to 'use'

    upload_2018-3-9_6-37-13.png

    fired using the 'B' hot key

    upload_2018-3-9_6-37-58.png

    upload_2018-3-9_6-42-13.png

    and people get healing

    upload_2018-3-9_6-42-55.png
     
  19. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    oh and usage is decremented on the token

    upload_2018-3-9_6-44-42.png
     
  20. Krilion_GD

    Krilion_GD Community Manager
    Staff Member

    Joined:
    Aug 1, 2011
    Messages:
    2,044
    Likes Received:
    136
    files
     

    Attached Files:

Share This Page