A "species" tag for modders. (For stuff like racial specific speech for SAIL, text, gui's, etc)

Discussion in 'Other' started by Littleman9Mew2, Jan 1, 2017.

  1. Littleman9Mew2

    Littleman9Mew2 Zero Gravity Genie

    I was looking at some of the popular mods and interesting ones such as AVIAN and inside the assets, but I noticed something....troublesome. The game can't detect what race the player is from a "if-then" standpoint. In LUA yes, but not in JSON. For example, if in a mod I want SAIL to have a floran accent while playing on a floran. I can do this, but it changes it for all the races including the floran. I can only specify SAIL to speak in a very general form as possible. I could insert <species> in the text, but all that would do is add the players race into the dialogue and that wont be as fun as SAIL speaking in slur with florans or a southern accent with novakids.

    So the idea is:

    Add some sort of "species" tag so that the event would only play, or json would execute if the player is playing that species.

    For example, if SAIL said something to an avian character in the intro mission, the code would be:

    Here, SAIL would say "Wake up avian. You have overslept."
    Instead of "Wake up. You have overslept."

    Code:
        {
          "startTime" : 5.99,
          "endTime" : 9.5,
          "drawables" : [
            {
              "image" : "/ai/portraits/<species>portrait.png:talk.<frame>"
            }
          ],
          "animationFrames" : 2,
          "species":"avian"
          "text" : "Wake up avian. You have overslept.",
          "textPosition" : {
            "position" : [34, 21],
            "vAnchor" : "top",
            "wrapWidth" : 218
          },
          "keyframes" : [
            {
              "timecode" : 0,
              "zoom" : 1.0,
              "position" : [366.5, 100]
            },
            {
              "timecode" : 0.1,
              "alpha" : 1.0,
              "zoom" : 1.0,
              "position" : [366.5, 100],
              "frame" : 0,
              "textPercentage" : 0
            },
            {
              "timecode" : 1.5,
              "frame" : 8,
              "textPercentage" : 1
            }
          ]
        }
    
     
  2. Partonetrain

    Partonetrain Phantasmal Quasar

    I don't think JSON works like that. It only holds data.
     
  3. Las La

    Las La Orbital Explorer

    From my understanding, prior to 1.0, you could do this for SAIL dialog, in particular, for the techstation interface. This was then removed / not implemented for 1.0.
    The only place I think it can be done now in json, is in the /ai/*.aimission files.
    It's one of the reasons why the AVIAN ai mod just replaces the SAIL on all races, because we couldn't find a way or a nice way to make it race specific.
     

Share This Page