FG Spreadshirt Swag

Thread: Cycler

  1. #1
    Xarxus's Avatar
    Join Date
    Mar 2019
    Location
    Rome (Italy)
    Posts
    253

    Cycler

    Can anyone tell me where I can find an example of a cycler to use outside the options?

    Thanks in advance
    FGU ULTIMATE License
    Click here for RPG Music or here for Dwarves songs on Spotify

  2. #2
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    17,272
    Blog Entries
    9
    I put one in a custom ruleset I'm still developing. But I used RulesetWizard to create it. I use it for toggling through damage types associated with weapons and defenses. I can pull out the code if you want to see it.

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

  3. #3
    Xarxus's Avatar
    Join Date
    Mar 2019
    Location
    Rome (Italy)
    Posts
    253
    Sure, you'd make me happy, if it's not too much trouble.
    I would like it very much.
    FGU ULTIMATE License
    Click here for RPG Music or here for Dwarves songs on Spotify

  4. #4
    There are a couple in the combat tracker for each effect

  5. #5
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    17,272
    Blog Entries
    9
    Here's the snippet
    Code:
    <button_stringcycler name="protectionType">
            <frame>
              <name>fielddark</name>
              <offset>0,0,0,0</offset>
            </frame>
            <bounds>300,31,32,25</bounds>
            <parameters>
              <defaultlabelres>sub_item_defense_protectionType_DefaultLabel</defaultlabelres>
              <labelsres>sub_item_defense_protectionType_Label_B|sub_item_defense_protectionType_Label_E|sub_item_defense_protectionType_Label_S</labelsres>
              <values>beam|electric|sonic</values>
            </parameters>
          </button_stringcycler>
    I attached the complete xml file it is used it too.
    Attached Files Attached Files
    Last edited by LordEntrails; November 2nd, 2023 at 23:51.

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

  6. #6
    Xarxus's Avatar
    Join Date
    Mar 2019
    Location
    Rome (Italy)
    Posts
    253
    Really ty LordEntrails!
    FGU ULTIMATE License
    Click here for RPG Music or here for Dwarves songs on Spotify

  7. #7
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    17,272
    Blog Entries
    9
    Quote Originally Posted by Xarxus View Post
    Really ty LordEntrails!
    Of course. This is one of the few code examples I can help with since I'm normally just look at code as magic!

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

  8. #8
    Xarxus's Avatar
    Join Date
    Mar 2019
    Location
    Rome (Italy)
    Posts
    253
    However you have been of great help to me, believe me
    FGU ULTIMATE License
    Click here for RPG Music or here for Dwarves songs on Spotify

  9. #9
    Xarxus's Avatar
    Join Date
    Mar 2019
    Location
    Rome (Italy)
    Posts
    253
    Is there a way to not use tags for initialization, leaving the task to the code?
    FGU ULTIMATE License
    Click here for RPG Music or here for Dwarves songs on Spotify

  10. #10
    Xarxus's Avatar
    Join Date
    Mar 2019
    Location
    Rome (Italy)
    Posts
    253
    Ok, nevermind. I've found this in CoreRPG
    Code:
    <button_stringcycler name="cycler">
    	<anchored width="100">
    		<top offset="5" />
    		<left anchor="right" offset="-117" />
    	</anchored>
    	<font>optionbody</font>
    	<sourceless />
    	<script>
    		function onDragStart(button, x, y, draginfo)
    			return window.onDragStart(draginfo);
    		end
    		function onValueChanged()
    			window.onValueChanged();
    		end
    	</script>
    </button_stringcycler>
    AnD this
    Code:
    ...
    cycler.initialize(aCustom.labels, aCustom.values, aCustom.baselabel);
    ...
    cycler.setStringValue(sValue);
    ...
    FGU ULTIMATE License
    Click here for RPG Music or here for Dwarves songs on Spotify

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
  •  
5E Character Create Playlist

Log in

Log in