Results 1 to 6 of 6

Thread: [SUG] More Buff/Debuff triggers (example height, bloodmoon day, biome, etc)

  1. #1
    Community Moderator Red Eagle LXIX's Avatar
    Join Date
    Jan 2014
    Location
    NJ,USA,North America,Earth,Sol System
    Posts
    3,280
    Rep Power
    1

    Lightbulb [SUG] More Buff/Debuff triggers (example height, bloodmoon day, biome, etc)

    [SUG] More Buff/Debuff triggers (example height, bloodmoon day, biome, etc)
    Ideally if it is used as a variable around the player, should be some way to trigger or remove buffs with that information.

    Examples:
    height/depth
    biome
    current day (count)
    blood moon day (true/false)
    skill levels
    player level
    moving/not moving
    current weather
    currently held item/block
    currently located in light/dark
    inside/outside (exceeded EnclosureDetectionThreshold or not)
    standing/crouched
    hunted/stealthed
    number of deaths
    number of Zed kills
    number of player kills
    time since last death
    days survived
    number of item slots filled on toolbelt
    number of item slots filled in inventory
    has or does not have bedroll

    Basically any player and/or environmental variable should be able to be used as a trigger for buffs and debuffs.
    This would allow a lot player requests to be filled.

    Example if we could set buffs by height, being below a certain height could add a buff that slowly taps the oxygen level of the player similar to being in water but at a slower pace when in an enclosed (inside) space.

    A buff that works on bloodmoons could be used to make the player more susceptible to infection on blood moons perhaps by automatically updating stage 1 infection to stage 2 during a blood moon.
    Last edited by Red Eagle LXIX; 10-13-2017 at 02:39 PM.

  2. #2
    Community Moderator Red Eagle LXIX's Avatar
    Join Date
    Jan 2014
    Location
    NJ,USA,North America,Earth,Sol System
    Posts
    3,280
    Rep Power
    1
    And another:
    IsItemWorn (true/false) (example is player wearing a rebreather)

  3. #3
    Fun Pimps Staff Gazz's Avatar
    Join Date
    Jun 2014
    Location
    In your brains. Thinking your thoughts.
    Posts
    8,731
    Rep Power
    2
    Quote Originally Posted by Red Eagle LXIX View Post
    Example if we could set buffs by height, being below a certain height could add a buff that slowly taps the oxygen level of the player similar to being in water but at a slower pace when in an enclosed (inside) space.
    I don't think that is a good condition because if you dig a giant open pit, why should you suffocate in it?

  4. #4
    Community Moderator Red Eagle LXIX's Avatar
    Join Date
    Jan 2014
    Location
    NJ,USA,North America,Earth,Sol System
    Posts
    3,280
    Rep Power
    1
    Quote Originally Posted by Red Eagle LXIX View Post
    height/depth
    inside/outside (exceeded EnclosureDetectionThreshold or not)
    Quote Originally Posted by Gazz View Post
    Quote Originally Posted by Red Eagle LXIX View Post
    Example if we could set buffs by height, being below a certain height could add a buff that slowly taps the oxygen level of the player similar to being in water but at a slower pace when in an enclosed (inside) space.
    I don't think that is a good condition because if you dig a giant open pit, why should you suffocate in it?
    buffif="height < 45", debuffif="outside = 1"

    Just a fake sample, pretty moot though without access to more variables (that are already a part of the game) hard to try such things.
    I know buffs have issues in edge cases and with transitions from one to another (drowning and burning come to mind). I imagine those issues will be worked out eventually, or workarounds can be done. I had such issues with antibiotics tweaks way back when buffs were first introduced and my workaround then was to create intermediary buffs.
    Last edited by Red Eagle LXIX; 10-13-2017 at 04:25 PM.

  5. #5
    Colony Founder Pille's Avatar
    Join Date
    Apr 2015
    Location
    Milky Way
    Posts
    1,645
    Rep Power
    1
    I like your suggestion but it cannot be used to simulate an oxygen system.

    Quote Originally Posted by Red Eagle LXIX View Post
    buffif="height < 45", debuffif="outside = 1"

    Just a fake sample.
    So you would suffocate if you enter a house located in the open pit?

    @Gazz
    Is there are reason why we don't have access to these variables?
    Last edited by Pille; 10-13-2017 at 04:32 PM.

  6. #6
    Community Moderator Red Eagle LXIX's Avatar
    Join Date
    Jan 2014
    Location
    NJ,USA,North America,Earth,Sol System
    Posts
    3,280
    Rep Power
    1
    I wrote a sample, including a variable buffs used (similar to metabolize food) to give an example.
    All using variables we don't have access to, and so a moot buff that does nothing.

    Note: I am not going to backfix and show the changes necessary all the buffs and I am not saying this is a perfect example given it is a fake sample without actual access to the state of the play (thus no way to test, adjust, work on the other buffs, etc).

    Code:
    <buff id="metabolizeOxygen" buffif="height lequal 45", debuffif="outside equals 1" actions="increment(CTRairuse, 1, 1, 0, 0);max(CTRairuse, 100)"/>
    <buff id="noAir" buffif="CTRairuse equals 100" debuffif="CTRairuse lequal 99"
    	type="drowning" icon="ui_game_symbol_oxygen" name_key="drowning" description_key="drowningDesc" tooltip_key="drowningTooltip">
    	<modify id="1" stat="health" amount="-14" rate="4"/>
    </buff>
    May have issues or incorrect points still because, well, no real way to test

    - - - Updated - - -

    Quote Originally Posted by Pille View Post
    So you would suffocate if you enter a house located in the open pit?

    @Gazz
    Is there are reason why we don't have access to these variables?
    Oooh, good point, might require more tweaks to get around that issue.

    Perhaps houses will require ventilation (real ones have many natural vents).

    That would require another buff addition: The ability to create new AOE effects. Like one that decrements CTRairuse in AOE around windows or vents.

    OR it could just be switched to one that increase the radiation level of the player (as one of the requests for bedrock dwelling suggested). Then the inside/outside would not be necessary in the buff, just the depth.

    -

    Next I'll ask for all those be available to the HUD stuff too (although with buffs they would all be indirectly available to the HUD).
    Last edited by Red Eagle LXIX; 10-13-2017 at 04:57 PM.

Tags for this Thread

Posting Permissions

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