GI JOE RPG Launch
  1. #1111
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    27,095
    Blog Entries
    1
    Share your project file and directions to what element you are coding

    If you are using AI to write the code for you it wont work. These AI tools do not know enough about FG to help you.

  2. #1112
    Quote Originally Posted by Koshaker View Post
    I was trying to use the built-in FGButton function on the constitution parameter, so that after the roll " {body_current} + d6s6 " it would trigger the script from "Result handler function name"



    but its give me error about " String "Frontier:Scripts/RollResult.lua" :2: FindNode: Invalid parameter 1

    i used GPT to find out, what can i do to solve this problem, but it was useless.

    biggest part of time, i spend by trying use "rRoll.aDice" and save result by this function.
    use Debug.chat(rSource) to view the contents of that variable and determine the source of the problem.
    Ruleset Wizard
    The Ruleset Development Environment
    www.rulesetwizard.com
    Ruleset Wizard Tutorials
    Damned's Ruleset Wizard Tutorials

  3. #1113
    screen.png

    first of all, i want to code at least one skill check, after that, i gonna use it for all others rools. Actualy i think it have to be some sort of big red button with text like "PUSH" wich can use any others rolls.
    Attached Files Attached Files

  4. #1114

  5. #1115
    yes, sure. here
    Attached Files Attached Files

  6. #1116

  7. #1117
    I tried to follow your advice and save the roll results in a character's field. First, I attempted to use a Number Field, and then I tried using a Label. Later, I read that it's possible to create a virtual field that works only during the session, if I understood correctly. Unfortunately, I couldn't progress beyond the first step of your suggestion due to my limited programming knowledge.

    1.
    function SaveRollResult(rRoll, rSource, rTarget)
    local playerNode = DB.findNode(rSource.sCTNode)
    if playerNode then
    playerNode.getChild("lastRoll").setValue(rRoll.nTo tal)
    end
    end
    2.
    function SaveRollResult(rRoll, rSource, rTarget)
    local playerNode = DB.findNode(rSource.sCTNode)
    if playerNode then
    local rollResultNode = playerNode.getChild("lastRoll")
    if not rollResultNode then
    rollResultNode = playerNode.createChild("lastRoll", "number")
    end
    rollResultNode.setValue(rRoll.nTotal)
    else
    print("Ошибка: Не удалось найти узел игрока.")
    end
    end


    there was others, but looks pretty same

  8. #1118
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    27,095
    Blog Entries
    1
    And you want to roll #d6 and count 1s and 6s and reroll any remaining dice one more time.
    Add all the 1s and all the 6s and compare them and declare a result?

  9. #1119
    Absolutely correct! However, it would be preferable if the reroll was a separate button that the player could use at will. Essentially, it gives the player the chance to risk getting either a critical success or a critical failure.

  10. #1120

Page 112 of 114 First ... 1262102110111112113114 Last

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
DICE PACKS BUNDLE

Log in

Log in