Difference between revisions of "Interaction Tuning Resource"

From SimsWiki
Jump to: navigation, search
 
Line 85: Line 85:
 
|}
 
|}
  
==Field Examples:==
+
==Code Examples:==
 
+
NOTE: All elements below have both ''type(t)'' and ''name(n)'' (A few elements can omit the name).
+
  
 
===<code>_saveable(''type(t), name(n)'')</code>===
 
===<code>_saveable(''type(t), name(n)'')</code>===

Latest revision as of 13:16, 6 October 2018

Template:WorkInProgress

The fields defined in an interaction tuning resource

This table is a list of all possible fields found in an interaction tuning resource.

Field Name (name[XMLType=type(t)]) Description Types (t)
_saveable[V] Unknown Purpose enabled, disabled
outcome[V] Instructions on what to do after an interaction succeeds or fails single, test_based
outcome[V=single].single[U].actions[U] Specifies a single action to take for the outcome None
outcome[V=single].single.actions.continuation[L] Specifies an interaction to queue after this interaction completes None
outcome[V=single].single.actions.continuation.[U].affordance[T] The decimal identifier of an interaction to queue None
outcome[V=single].single.actions.continuation.[U].si_affordance_override[T] The decimal identifier of a super interaction to queue an interaction under None
outcome[V=single].single.actions.continuation.[U].target[E] Which sim the interaction is queued for (TargetSim, Actor) None
outcome[V=single].single.actions.force_outcome_on_exit[T] Species whether an outcome is forced or not upon the interaction completing (True, False) None
outcome[V=test_based].test_based.tested_outcomes.[U].potential_outcomes[L].[U].outcome[U] Specifies a potential outcome for this interaction None
outcome[V=test_based].test_based.tested_outcomes.[U].tests[L].[L] Specifies tests that must pass in order for this outcome to occur None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V] Specifies a test test_based_score_threshold, sim_info
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=test_based_score_threshold].test_based_score_threshold[U] Specifies a value based test None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=test_based_score_threshold].test_based_score_threshold.test_based_score[T] The decimal identifier of something with a value a commodity, statistic, etc. None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=test_based_score_threshold].test_based_score_threshold.threshold[U] Specifies the threshold needed to be met None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=test_based_score_threshold].test_based_score_threshold.threshold.comparison[E] Specifies the check type (GREATER_OR_EQUAL, LESS_OR_EQUAL) None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info[U] Specifies sim attributes. Age, Species, etc. None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.species[V] Specifies a sims species test specified, unspecified
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.species[V=specified].specified[U].species[L] Specifies a sim species must be in the list None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.species[V=specified].specified[U].species[L].[E] Enum value of species (HUMAN, DOG, CAT) None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.species[V=unspecified].unspecified[U].species[L] Specifies a sim species must not be in the list None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.species[V=unspecified].unspecified[U].species[L] Enum value of species (HUMAN, DOG, CAT) None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.ages[V] Specifies a sims age test specified, unspecified
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.ages[V=specified].specified[U].ages[L] Specifies a sim ages must be in the list None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.ages[V=specified].specified[U].ages[L].[E] Enum value of ages (BABY, TODDLER, CHILD, TEEN, YOUNGADULT, ADULT, ELDER) None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.ages[V=unspecified].unspecified[U].ages[L] Specifies a sim ages must not be in the list None
outcome[V=test_based].test_based.tested_outcomes.[U].tests.[L].[V=sim_info].sim_info.species[V=unspecified].unspecified[U].species[L] Enum value of ages (BABY, TODDLER, CHILD, TEEN, YOUNGADULT, ADULT, ELDER) None
progress_bar_enabled[U] Enables/Disabled the progress bar on the interaction None
progress_bar_enabled.bar_enabled[T] Enables/Disabled the progress bar on the interaction (True, False) None

Contents

[edit] Header Example:

[edit] Resource Header(class(c), itemType(i), module(m), stringId(s))

<I c="ImmediateSuperInteraction" i="interaction" m="interactions.base.immediate_interaction" n="ExampleSuperInteractionOne" s="12345">
Property Name Description
class(c) The python class that will run the interaction
itemType(i) The resource type, in this case interaction meaning it is an Interaction Tuning Resource
module(m) The python namespace to the class
stringId(s) The tuning resource identifier, for usage within python. It should be the resource Key in decimal notation.

[edit] Code Examples:

[edit] _saveable(type(t), name(n))

[edit] t=enabled

  <V t="enabled" n="_saveable">
    <Unknown Code>
  </V>
  

[edit] t=disabled

  <V t="disabled" n="_saveable" />
  

[edit] outcome(type(t), name(n))

[edit] t=single

  <V t="single" n="outcome">
    <U n="single">
      <U n="actions"> <!-- List of actions to perform on sims -->
        <L n="continuation">
          <U>
            <T n="affordance">10451411205084654091</T>    <!-- The Decimal Identifier of the interaction to push in the queue of this sim -->
            <T n="si_affordance_override">9553480838726705593</T>    <!-- The Decimal Identifier of the Super Interaction to make this interaction a sub of -->
                                                                     <!-- If the interaction is between two Teen/YA/Adult/Elder sims use sim_chat) -->
                                                                     <!-- If the super interaction has the field "visible" set to "false" this interaction 
                                                                          will interaction will be invisible -->
            <E n="target">TargetSim</E>    <!-- The target of this outcome (Actor/TargetSim) -->
          </U>
          <U>
            <T n="affordance">10451411205084654091</T>
            <T n="si_affordance_override">9553480838726705593</T>
            <E n="target">Actor</E>
          </U>
        </L>
        <T n="force_outcome_on_exit">True</T> <!-- If True, one of the above outcomes WILL be picked when the interaction ends -->
      </U>
    </U>
  </V>

[edit] t=test_based

  <V t="test_based" n="outcome">
    <U n="test_based">
      <L n="tested_outcomes">
        <U>
          <L n="potential_outcomes">
            <U>
              <U n="outcome">
                <E n="outcome_result">FAILURE</E>    <!-- The type of this outcome (FAILURE, SUCCESS) -->
                <L n="continuation">
                  <U>
                    <T n="affordance">17979319336372264984</T>    <!-- The Decimal Identifier of the interaction to push in the queue of this sim if this outcome occurs -->
                  </U>
                </L>
		<V t="enabled" n="cancel_si">    <!-- Indicates if the Super Interaction should be cancelled upon picking this outcome, and which participants for -->
		  <L n="enabled">    <!-- In this case, the Super Interaction will be cancelled for both the initiator sim 
                                          and the sim they are performing the interaction on -->
		    <E>Actor</E>
		    <E>TargetSim</E>
		  </L>
		</V>
                <V n="animation_ref" t="enabled">
                  <U n="enabled">
                    <T n="factory">164587</T>    <!-- The Decimal Identifier of the animation to play upon performing this interaction-->
                    <U n="overrides">    <!-- Any animation overrides -->
                      <V n="balloons" t="enabled">    <!-- In this case we are overriding the balloon that appears above the target sims head and setting it to pick an image
                                                           from the DISTRESS category of balloons -->
                        <L n="enabled">
                          <U>
                            <L n="balloon_choices">
                              <U>
                                <V n="item" t="balloon_icon">
                                  <U n="balloon_icon">
                                    <E n="balloon_type">DISTRESS</E>
                                    <V n="icon" t="participant">
                                      <U n="participant">
                                        <L n="participant_type">
                                          <E>TargetSim</E>
                                        </L>
                                      </U>
                                    </V>
                                  </U>
                                </V>
                              </U>
                            </L>
                            <L n="balloon_target">
                              <E>Actor</E>
                            </L>
                          </U>
                        </L>
                      </V>
                      <V n="reactionlet" t="enabled">
                        <U n="enabled">
                          <V n="selector" t="single_ref">
                            <U n="single_ref">
                              <T n="factory">161076</T>    <!-- The Decimal Identifier of a reaction animation to play upon picking this outcome -->
                              <U n="overrides">
                                <V n="balloons" t="enabled">
                                  <L n="enabled">
                                    <U>
                                      <L n="balloon_choices">
                                        <U>
                                          <V n="item" t="balloon_category">
                                            <T n="balloon_category">159031</T>    <!-- The Decimal Identifier of a reaction balloon category to show upon the sim reacting -->
                                          </V>
                                        </U>
                                      </L>
                                      <L n="balloon_target">
                                        <E>TargetSim</E>
                                      </L>
                                    </U>
                                  </L>
                                </V>
                              </U>
                            </U>
                          </V>
                        </U>
                      </V>
                    </U>
                  </U>
                </V>
              </U>
            </U>
          </L>
          <L n="tests">    <!-- These determine whether or not to choose this outcome -->
            <L>
              <V t="test_based_score_threshold">    <!-- This can be used to check commodities, statistics, relationship levels, anything numbers related. -->
                <U n="test_based_score_threshold">
                  <T n="test_based_score">13299080933458659880</T>    <!-- The Decimal Identifier of the resource being checked (i.e. statistic tuning, commodity tuning, etc.) -->
                  <U n="threshold">
                    <E n="comparison">LESS_OR_EQUAL</E>
                    <T n="value">14</T>
                  </U>
                </U>
              </V>
              <V t="sim_info">    <!-- This checks the sim info of the sim looking for an interaction outcome -->
                <U n="sim_info">
                  <V n="ages" t="specified">    <!-- This checks age, all valid ages are listed here, default value is (TEEN, YOUNGADULT, ADULT, ELDER) -->
                    <L n="specified">
                      <E>BABY</E>
                      <E>TODDLER</E>
                      <E>CHILD</E>
                      <E>TEEN</E>
                      <E>YOUNGADULT</E>
                      <E>ADULT</E>
                      <E>ELDER</E>
                    </L>
                  </V>
                  <V n="species" t="specified">    <!-- This checks species, all valid species are here -->
                    <U n="specified">
                      <L n="species">
                        <E>HUMAN</E>
                        <E>DOG</E>
                        <E>CAT</E>
                      </L>
                    </U>
                  </V>
                  <E n="who">TargetSim</E>    <!-- Which sim is this being check for? (Actor, TargetSim) -->
                </U>
              </V>
            </L>
          </L>
        </U>
      </L>
    </U>
  </V>


TS4PR Tuning Resources by Name

Interaction | Buff | Trait |

Personal tools
Namespaces

Variants
Actions
Navigation
game select
Toolbox