Jump to content

Bladestorm Games

Members
  • Posts

    109
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Bladestorm Games

  1. So I ran into an issue. I am working on a 2nd item modifier that grants percent damage bonus, the item displays the text correctly, but doesn't seem to grab the value: Here is my code: [ui_display.xml] <append xpath="ui_display_info/item_display"> <item_display_info display_type="modGemstoneBrutality" display_group="modAttire"> <display_entry name="EntityDamage" display_type="Percent" title_key="statEntityDamage" display_leading_plus="true" /> <display_entry name="EntityDamage" display_type="Decimal1" title_key="statEntityDamage" display_leading_plus="true" /> </item_display_info> </append> [item_modifiers.xml] <append xpath="/item_modifiers"> <item_modifier name="modWeaponGemstoneBrutalityT4" installable_tags="weapon,tool" modifier_tags="gemstone_brutality" blocked_tags="noMods" type="attachment"> <property name="Extends" value="modGeneralMaster"/> <property name="CustomIcon" value="modWeaponGemstoneBrutality"/> <property name="DisplayType" value="modGemstoneBrutality"/> <property name="DescriptionKey" value="modWeaponGemstoneBrutalityBasicDesc"/> <effect_group tiered="false"> <passive_effect name="EntityDamage" operation="perc_add" value=".25,.3"/> </effect_group> </item_modifier> </append> Note #1: I dont intend to have the 2nd display_entry line, just there for display testing incase display_type="Decimal1" would have worked. Note #2: I used "gunBowT0PrimitiveBow" in the items.xml, and "rangedBow" in the ui_displays.xml, as a random reference on how they display their Entity Damage.
  2. Hi, I've got a question regarding DisplayType, and if there is a way for a custom item to display it's values, like Armor, Resist, CritResist, w/e "stat" is on the item. If I had a custom item that had only Armor Rating, Explosion Resist, and Armor Crit Resist. How can I display those 3 "stats"? Currently I am doing this: <property name="DisplayType" value="modArmor"/> <effect_group tiered="false"> <passive_effect name="PhysicalDamageResist" operation="base_add" value=".1,1"/> <passive_effect name="ElementalDamageResist" operation="base_add" value="0,.5" tags="heat,electrical"/> <passive_effect name="BuffResistance" operation="base_add" value="0.01,0.03" tags="buffFatiguedTrigger,buffArmSprainedCHTrigger,buffLegSprainedCHTrigger,buffLaceration,buffInfectionCatch,buffInjuryStunned01CHTrigger,buffInjuryBleedingTwo,buffInjuryBleedingBarbedWire,critResistDisplay"/> </effect_group> Which results with this: Only thing not being displayed is Armor Crit Resist (BuffResistance). Thanks for the read!
  3. Hi, I'm working on adding an AoE (Area of Effect) attack for the Machete's Power Attack. My first plan was to alter the strike/swing hitbox, but I cant seem to figure out a few things (I swear I saw a video that showed the enable/disable of weapon's swing/hitbox) 1) I've looked up Console Commands to see if there is a command to see weapon swings/hitbox, for ease of testing. (Cant find command) 2) I've searched Youtube for a video that shows weapon swings, but cant seem to find it. [METHOD #1] So my plan was to mess with a weapon's "MaxRange" and its "SwingDegrees" and "SwingAngle" to see if I can make a 360 degree swing, and use "MaxRange" to increase the range/size of the swing/hitbox. Enabling visual weapon swing/hitbox would help to see what changing those variable's values would do. So for testing I'm pretty much messing with these values, but not getting a 360 degree attack: <configs> <set xpath="/items/item[@name='meleeWpnBladeT0BoneKnife']/property[@class='Action1']/property[@name='SwingDegrees']/@value">360</set> <set xpath="/items/item[@name='meleeWpnBladeT0BoneKnife']/property[@class='Action1']/property[@name='SwingAngle']/@value">-60</set> <set xpath="/items/item[@name='meleeWpnBladeT0BoneKnife']/effect_group[@name='meleeWpnBladeT0BoneKnife']/passive_effect[@name='MaxRange']/@value">5.0</set> </congigs> [METHOD #2] Since I'm having trouble with that method, here is my temporary method: 1) Strike an enemy 2) Apply a buff to enemies around you 3) buff deals damage Weapon for Testing AoE Buff: <configs> <append xpath="/items/item[@name='meleeWpnBladeT0BoneKnife']/effect_group[@name='Power Attack']">"> <triggered_effect trigger="onSelfSecondaryActionRayHit" action="AddBuff" target="selfAOE" range="5" target_tags="zombie,animal" buff="buffProcAoECleave"/> </append> </configs> AoE Buff: <configs> <append> <buff name="buffProcAoECleave" hidden="true"> <stack_type value="replace"/> <duration value="0.5"/> <effect_group> <passive_effect name="HealthChangeOT" operation="base_add" value="-150"/> </effect_group> </buff> </append> </configs> This method works, but the only issue is, sometimes this buff isnt applied to some enemies. I feel like it has to due with the Buff's duration being less than 1 second, and how "HealthChangeOT" might work. So basically from this post I'm hoping to get some advise on how to make Method 1 work, and also why the buff might not always apply from Method 2 Thanks for reading!
  4. I just quickly wrote this, so it isnt tested, but it should work: Edit: Just tested it with a Bone Knife and it works for me (for testing on a bone knife I changed "meleeToolAxeT1IronFireaxe" to "meleeWpnBladeT0BoneKnife") your_mod/config/items.xml <config> <!-- Add Decapitation chance for Iron Axe / Fireaxe --> <append xpath="/items/item[@name='meleeToolAxeT1IronFireaxe']"> <effect_group> <passive_effect name="DismemberChance" operation="base_add" value="90"/> </effect_group> </append> </config>
  5. Thanks for the reply! I tested your method and it works, thanks! Localization.txt Key,File,Type,UsedInMainMenu,NoTranslate,english perkArcheryRank1LongDesc_TEST,progression,perk Agi,,,"This is some \n Test Text for a national \n test of Line Break testing.\nTest 1 2 3 Testing in session." progression.xml: <configs> <set xpath="/progression/perks/perk[@name='perkArchery']/effect_group/effect_description[@level='1']/@long_desc_key">perkArcheryRank1LongDesc_TEST</set> </configs> Here is the result: Quick edit / note: it seems that for the changes to take place in Localization.txt, I had to start a saved game, exit the saved game, and start it again for the Description to actually show up.
  6. Hello, does anyone know the new method for line break when used in an item's text description? I used to use "\n" and it would work, but now it doesn't? Example: <!--This is in progression.xml --> <configs> <set xpath="/progression/perks/perk[@name='perkArchery']/effect_group/effect_description[@level='1']/@long_desc_key">Bow Novice\n 10% More Damage, Shoot Spread, Faster Aim, and Reload with Bows.\nCrafting Quality: 2</set> </configs>
  7. Fixed the syntax error. Sorry, just double checking: you're saying that if "EntityTagCompare" and "IsAlive" returns true, the SECOND triggered_effect fires off? Wouldn't it be the first triggered_effect? Thanks for this info! Here is the edit: <effect_group> <triggered_effect trigger="onSelfKilledOther" action="ModifyCVar" cvar="roll_range" operation="set" value="randomint(5,15)"/> <triggered_effect trigger="onSelfKilledOther" action="ModifyStats" stat="Health" operation="add" value="@roll_range"/> </effect_group>
  8. Just a post checking if my usage of the "requirement" element is correct: Here is the example code: <!-- Method #1 - Requirements are before the trigger_effect --> <passive_group> <requirement name="EntityTagCompare" target="other" tags="zombie,animal"/> <requirement name="IsAlive" target="other"/> <requirement name="RandomRoll" seed_type="Random" min_max="0,100" operation="LTE" value="10"/> <triggered_effect trigger="onSelfKilledOther" action="ModifyStats" stat="Stamina" operation="add" value="10"/> </passive_group> <!-- Method #2 - Requirements are within the trigger_effect --> <passive_group> <triggered_effect trigger="onSelfKilledOther" action="ModifyStats" stat="Stamina" operation="add" value="10"> <requirement name="EntityTagCompare" target="other" tags="zombie,animal"/> <requirement name="IsAlive" target="other"/> <requirement name="RandomRoll" seed_type="Random" min_max="0,100" operation="LTE" value="10"/> </triggered_effect> </passive_group> I understand that in Method #2, the requirements must be met for that specific triggered_effect to occur. Question #1) In Method #1, those requirements must be met for the triggered_effect to occur, but that means anything AFTER the triggered_effect will also need to have met the requirements? So If I wanted to do something like: "On hitting an enemy, Recover 10 Stamina and a 25% chance to recover 5 life" <passive_group> <requirement name="EntityTagCompare" target="other" tags="zombie,animal"/> <requirement name="IsAlive" target="other"/> <!-- Needs to pass the EntityTagCompare, and IsAlive requirements --> <triggered_effect trigger="onSelfAttackedOther" action="ModifyStats" stat="Stamina" operation="add" value="10"/> <requirement name="RandomRoll" seed_type="Random" min_max="0,100" operation="LTE" value="25"/> <!-- The first 2 requirements still apply to this triggered_effect, correct?? --> <triggered_effect trigger="onSelfAttackedOther" action="ModifyStats" stat="Health" operation="add" value="5"/> </passive_group> Question #2) Kind of a side question, is this the way to do a value range? Say I wanted to do something like this: "When you kill an enemy to recover 5 to 15 Stamina" <triggered_effect trigger="onSelfKilledOther" action="ModifyStats" stat="Health" operation="add" value="randomint(5,15)"/>
  9. No errors in the log, and the xpath is loaded, based on viewing the config dump.
  10. Thanks, this fixed the error issue, but now the issue is I'm not hearing the custom sounds (if i replace the sound to be placed with something like "breakleg" it plays that sound. Example: <!-- This plays the sound--> <triggered_effect trigger="onSelfBuffStart" action="PlaySound" sound="breakleg"/> <!-- This Does Not play the sound--> <triggered_effect trigger="onSelfBuffStart" action="PlaySound" sound="PoisonProc"/> <!-- sounds.xml snip for PoisonProc --> <config> <append xpath="/Sounds"> <SoundDataNode name="PoisonProc"> <AudioSource name="Sounds/AudioSource_Impact"/> <Noise ID="1" noise="7" time="3" muffled_when_crouched="0.5"/> <AudioClip ClipName="#@modfolder:Resources/sounds_poisons.unity3d?snd_poison_proc"/> <LocalCrouchVolumeScale value="0.3"/> <CrouchNoiseScale value="0.5"/> <NoiseScale value="1"/> <MaxVoices value="5"/> <MaxRepeatRate value="0.01"/> </SoundDataNode> </append> </config> Something is probably not right with how I have the SoundDataNode setup, but i am using a few references, so I'm not really sure why it doesnt play.
  11. Hello, I am trying to add custom sounds to my mod. I have followed a video guide and a text guide, and looked how other mods load sounds, but something is failing. (Link to Video Guide: https://youtu.be/ptBaRB7nFbY ) (Link to Text Guide: https://7d2dsdx.github.io/Tutorials/index.html?HowtoaddCustomSounds.html ) Here is the error I am receiving: The top part is while loading the world, bottom part is when triggering the sound. Here is my sound.xml code: <!-- ########## --> <!-- Custom SFX --> <!-- <AudioClip ClipName="#[NAME OF BUNDLE]?[NAME OF FILE IN BUNDLE]"/> --> <config> <append xpath="/Sounds"> <SoundDataNode name="PoisonApply"> <AudioSource name="Sounds/AudioSource_WeaponFire"/> <Noise ID="2" noise="11" time="3" muffled_when_crouched="0.5"/> <AudioClip ClipName="#@modfolder:Resources/sounds_poisons.unity3d?snd_poison_apply"/> <LocalCrouchVolumeScale value="0.3"/> <CrouchNoiseScale value="0.5"/> <NoiseScale value="1"/> <MaxVoices value="5"/> <MaxRepeatRate value="0.01"/> </SoundDataNode> <SoundDataNode name="PoisonProc"> <AudioSource name="Sounds/AudioSource_WeaponFire"/> <Noise ID="2" noise="11" time="3" muffled_when_crouched="0.5"/> <AudioClip ClipName="#@modfolder:Resources/sounds_poisons.unity3d?snd_poison_proc"/> <LocalCrouchVolumeScale value="0.3"/> <CrouchNoiseScale value="0.5"/> <NoiseScale value="1"/> <MaxVoices value="5"/> <MaxRepeatRate value="0.01"/> </SoundDataNode> </append> </config> The file "sounds_poisons.unity3d" directory is: D:\SteamLibrary\steamapps\common\7 Days To Die\mods\arpg_mode\Resources What am I doing wrong / missing? Thanks.
  12. Looks like this section is related to the issue: And here is the XML for the item mod: <configs> <append xpath="/item_modifiers"> <item_modifier name="modOintmentPoisonRegular" installable_tags="weapon" modifier_tags="poison" blocked_tags="noMods" type="attachment"> <property name="CustomIcon" value="ointmentPoisonRegular"/> <property name="Stacknumber" value="1"/> <property name="Group" value="Mods"/> <property name="DropMeshfile" value="#Other/Items?Misc/sack_droppedPrefab.prefab"/> <triggered_effect trigger="onSelfDamagedOther" action="AddBuff" target="other" buff="buffPoisonDoT"/> <triggered_effect trigger="onSelfDamagedOther" action="ModifyCVar" target="other" cvar="poisonCounter" operation="add" value="5"/> </item_modifier> </append> </configs>
  13. Hey so I am working on a custom item modifier, Poison Ointment, pretty much everything is up (recipe craft, item icon, debuff). The issue I am running into is, when I apply the item modifier to a weapon, it results in a "NullReferenceException. Object reference not set to an instance of an object". Searching google, it seems people say "NullReferenceException" is Unity's general way of saying something went wrong. So I'm not sure what I'm missing that would cause this issue. Here is a video to see what is going on: https://youtu.be/7W8CJiIwrvg
  14. I've looked at both buffInjuryBleeding and perkDeepCuts, and understand how they function, but my question was more of whether I need to assign/initialize custom variables someplace first, before using them, since "poisonDuration" and "poisonCounter" are not actually in the game, I'm just curious if I need to initialize them someplace first before using them. I want to note here that I dont want to use the bleed variables(bleedAmount, bleedCounter, etc) in the poison debuff code, because Im sure if an enemy is poisoned and bleeding, there will be issues with sharing similar variables.
  15. Hello everyone, I am trying to attempt/theorize a Poison debuff that applies damage over time. I am using the Bleeding debuff as a guide on how to make a Poison version of the Bleed debuff. The question I have is, if I change this code: <triggered_effect trigger="onSelfBuffUpdate" action="RemoveBuff" buff="buffInjuryBleeding"> <requirement name="CVarCompare" cvar="$bleedDuration" operation="LTE" value="0"/> </triggered_effect> To this: <triggered_effect trigger="onSelfBuffUpdate" action="RemoveBuff" buff="buffPoisonDoT"> <requirement name="CVarCompare" cvar="$poisonDuration" operation="LTE" value="0"/> </triggered_effect> will the CVar of "poisonDuration" function? Or does it fail, because I havent declared a poisonDuration variable in some other file? I hope the question I'm asking makes sense, basically I'm replacing vars like "bleedDuration" and "bleedCounter" with "poisonDuration" and "poisonCounter" but I'm wondering if that would even work or would it fail because I need to declare those variables somewhere first?
  16. Sorry for the late responce, I went to bed and just woke up. I gotta use that more often! Very useful to see how things are finalized. Yeah this solved the issue, now only Power Attacks gain the increase for Block Damage and Stamina Loss. I guess with my code, like you said, it was adding it to all effect groups which the first effect group seems to be default values (which i'd be adding to) Thanks! Also side note, there are multiple effect_groups in perkBrawler in progression.xml. If I wanted to target and insert code into the 2nd effect_group, I'd probably have to do something like: <insertAfter xpath="/progression/perks/perk[@name='perkBrawler']/effect_group[2]/requirement[1]"> <triggered_effect trigger="onSelfSecondaryActionRayHit" action="PlaySound" sound="stonedestroy3"/> <passive_effect name="StaminaLoss" operation="perc_add" level="1,5" value=".2,1" tags="secondary"/> <passive_effect name="BlockDamage" operation="perc_add" level="1,5" value="20,100" tags="secondary"/> </insertAfter> (Checking the ConfigDump, it seems the code above does work, view spoiler for image of the effect of the code) (Noting that it does insert the code with undesired indentation) Again, thanks. Learning a lot with this session.
  17. I've adjusted the code, but this didnt fix the issue. Still having Regular Attacks inherit the StaminaLoss & BlockDamage. Thanks though!
  18. Hi, Im trying to make it so that knuckle items use 20% increased Stamina Use and deal 200% Block Damage on Power Attacks. I was able to pull this off in the items.xml, but I'd have to copy and paste the code for each Knuckle Item. I wanted to simplify that, so I've added this code into the progression.xml, which should effect all Knuckle weapons: <append xpath="/progression/perks/perk[@name='perkBrawler']/effect_group"> <requirement name="ItemHasTags" tags="perkBrawler"/> <passive_effect name="StaminaLoss" operation="perc_add" level="1,5" value=".2,1" tags="perkBrawler, secondary"/> <passive_effect name="BlockDamage" operation="perc_add" level="1,5" value="2,10" tags="perkBrawler, secondary"/> </append> Quick note, I needed the "requirement" line because without it, all weapons would be effected by the passive_effects. (With this line I could probably remove the "perkBrawler" from the tags.) The issue I'm running into with the code above, is with Regular Attacks, they seem to be inheriting the passive_effects. I was hoping I could add "secondary" to the tags attribute so that only Power Attacks get the passive_effects. What do i need to add/change to make the passive_effects only work with Power Attacking? Just for fun I'll provide my item.xml method incase anyone wanted to critique it / add suggestion to it:
  19. Hey guys, I'm trying to make a custom consumable item, but having trouble with finding out how to edit the Tooltip values (When you click on a consumable it shows the values of Health, Food, Stamina, Water, Regen, etc. on the item) Here is a visual image of what I'm trying to accomplish: https://i.imgur.com/lgkdWL5.png (Note: I already have the item applying the Health, Water, Cure, Stam Regen... just the tooltip isnt displaying the proper values) I think it has to do with DisplayType. For example if you changed "Food" to "Water" the item's tooltip values would change: <property name="DisplayType" value="water"/> VS <property name="DisplayType" value="food"/> If I'm correct and it has to do with "DisplayType" where would I setup a custom DisplayType for my specific item? Thanks!
×
×
  • Create New...