Jump to content

Wolfmark

Premium Member
  • Posts

    71
  • Joined

  • Last visited

Everything posted by Wolfmark

  1. The aiCount parameter for RemoveItem can be -1, which means "all items". There's no need to call GetItemCount() to obtain the number and then call RemoveItem() with that number. A faster solution: 1. Create a form list with all ObjectTypeXXX keywords and all scrap components (c_XXX records). Add few other common keywords, like UnscrappableObject, BobbleheadKeyword, FeaturedItem etc... 2. Call RemoveItem() with this form list and -1 for aiCount parameter. 3. I would create a new form list with all other vanilla items that don't have a keyword or components. Like all holotapes, all keys, all books etc... 4. Call RemoveItem() with this second form list and -1 for aiCount parameter. (you can merge the first and second form lists) This should remove most of junk items + weapons + ammo + armor + chems + holotapes + keys + notes. With only 1-2 RemoveItem() calls. There are few exceptions, for example some ammo records don't have ObjectTypeAmmo keyword (flares, gamma rounds...). Then if F4SE is installed: 5. Create an empty form list property. 6. Use ObjectReference.GetInventoryItems() to get the base forms for all remaining items and move them to the form list. This is the slow part and this is why is better to remove as much as possible in first 1-4 steps... 7. Call RemoveItem with the new form list and -1 for aiCount parameter. Without F4SE installed the idea is to minimize the number of notification messages: 5. I would create a form list with most vanilla items that were not included in steps 1-4. 6. RemoveItem with this form list and -1 for aiCount parameter. 7. RemoveAllItems() for remaining items.
  2. You don't need a mod for this. Drop some weapons on the ground and then store them into workshop. Then retrieve them from workshop, drop them again, use again the Store option etc... Do this 2-3 times with 10 weapons.
  3. Probably you mixed mods created for different game versions. Or you use a mod that is not for your game version. The actor.ws script file is from game version 1.22 or lower, but some other script that calls the function RemoveAllNonAutoBuffs is from game version 1.30+.
  4. Some mods may store some data in the save file. But the data is discarded when the mod is uninstalled, so there's no problem. Some things are computed only when a new game is started, like the XP required for leveling. If you start a game with a mod that alters these levels then uninstalling the mod won't revert back to vanilla values. There's a mod named Fast Travel from Anywhere that can corrupt the save file. For example the game expects that you can leave a house only through the door and when you do this an important quest is started. If you fast travel from the house instead then that quest is not started and you'll find out much later. But usually the mods that alter lighting, change textures, models etc... have nothing to do with save files.
  5. You should start with some mods that have menu entries, like Friendly HUD, More Quick Slots, Sort Everything etc... Also see the w3strings encoder / decoder tool. See this forum for more details. The short version: 1. Create an XML file describing the menu. Few examples are included in the game, you can find others in existing mods. The XMLs are located in bin\config\r4game\user_config_matrix\pc folder. Let's say you'll have 3 entries, all sliders (see audio.xml for examples, also you'll find few others in other menus): a slider for armor durability reduction, with valid values between 0.0 and 1.0; variable named armorLoseValuea slider for weapons durability reduction when the difficulty is not hardcore, with valid values between 0.0 and 0.4; variable named weaponLoseValue a slider for weapons durrability when hardcore mod is used, with valid values between 0.0 and 0.4; variable named weaponLoseValueHardcore 2. Create the w3strings files with the strings used by your menu. Probably you'll spend some time here until you'll figure the required keys :smile: 3. Add the variables specified in menu file to user.settings file, with their default values. For example something like this: [modEquipmentDurability] armorLoseValue = 0.6 weaponLoseValue = 0.26 weaponLoseValueHardcore = 0.1 No scripting required so far. If the menu works then you'll have to use the variables configured in menu. There are many examples in existing scripts for getting the value of a variable. Search game's script files for GetInGameConfigWrapper. For your mod(s), you don't have to change anymore the DURABILITY_ARMOR_LOSE_VALUE, DURABILITY_WEAPON_LOSE_VALUE and DURABILITY_WEAPON_LOSE_VALUE_HARDCORE constants. Instead you should change only the ReduceItemDurability function from inventoryComponent.ws script file. Something like this: if(IsItemWeapon(itemId)) { chance = theGame.params.DURABILITY_WEAPON_LOSE_CHANCE; if(theGame.GetDifficultyMode() == EDM_Hardcore) { value = StringToFloat(theGame.GetInGameConfigWrapper().GetVarValue('modEquipmentDurability', 'weaponLoseValueHardcore')); } else { value = StringToFloat(theGame.GetInGameConfigWrapper().GetVarValue('modEquipmentDurability', 'weaponLoseValue')); } } else if(IsItemAnyArmor(itemId)) { chance = theGame.params.DURABILITY_ARMOR_LOSE_CHANCE; value = StringToFloat(theGame.GetInGameConfigWrapper().GetVarValue('modEquipmentDurability', 'armorLoseValue')); }where modEquipmentDurability is the group for your variables (defined in XML files, added to user.settings) and weaponLoseValue, weaponLoseValueHardcore and armorLoseValue are the names of the variables defined in the XML files.
  6. Upload it, but first you should be sure that it really works. Don't credit me.
  7. Don't remove anything from that file. Actually don't change anything else. The game only loads a script file once. If it finds the gameParams.ws inside a mod then will load it from there and will ignore the original file, from game's scripts folder. If the same script file is modified by two or more mods then the game will load only one version. This is a conflict and the game won't start (compilation errors) or will start but one mod won't work etc... Conflicts can be detected and fixed using a tool named Script Merger. Is a must have if you use script mods. This tool will merge multiple versions of the same script file and will create a new one with all the changes. This new version will be the one used by the game because will be included in a mod with higher priority than the other mods. Lucky for you the gameParams.ws script file is not modified by too many mods.
  8. 1. Create a folder named mods, next to bin, content, DLC etc... The path should be WITCHER_3_INSTALL_DIR/mods. 2. Create the following folders inside the "mods" folder: modExtendedDurability/content/scripts/game 3. Copy the file gameParams.ws from WITCHER_3_INSTALL_DIR/content/content0/scripts/game to modExtendedDurability/content/scripts/game 4. Edit the copied gameParams.ws script file with a text editor and change the values for DURABILITY_ARMOR_LOSE_VALUE (0.6), DURABILITY_WEAPON_LOSE_VALUE (0.26), DURABILITY_WEAPON_LOSE_VALUE_HARDCORE (0.1). Do not edit the original gameParams.ws script file, edit the one you copied to modExtendedDurability. Decreasing the values will increase the life of the equipment. In hardcore the swords are more durable (0.1 lose instead of 0.26 lose) because you must hit the enemies multiple times.
  9. See playerWitcher.ws script file. Some recipes are added in OnSpawned, the schematics are added in AddStartingSchematics, Wolf Hour potion is added in ApplyPatchFixes etc...
  10. The game is ok, you don't need to reinstall it. Only the save games created after Junior quest are corrupted. If you have a save before Junior's house (or during that quest) then you're lucky, otherwise you need to start from beginning. The mod has a forum with the quests that break if you fast travel when the game doesn't expect this. Read it, there are 4-5 quests...
  11. Remove those two script files. They were moved / renamed since patch 1.10.
  12. First update the telemetryKyeword.ws file. You probably updated the game to patch 1.12, but still have the file from patch 1.11. You'll find the updated one in the miscellaneous downloads section from All Quest Objectives on Map mod. Then use Script Merger tool to fix the conflict between All Quest Objectives on Map mod and the other mod that changes the mapMenu.ws file.
  13. Something went wrong when you updated the game. In version 1.08 the CCameraRotationControllerDrift was defined in game\cameras\combat\customCameraControllers.ws file. In version 1.10 the class is defined in game\cameras\exploration\driftCamera.ws file. For some reason you have the customCameraControllers.ws file from 1.08 and driftCamera.ws file from 1.10+. A quick fix in this case is to edit the customCameraControllers.ws file and to remove the the last 3 lines. In this way you convert it to 1.10+ version. But who knows what other files you still have from 1.08? Even if you don't see a compilation error it doesn't mean that you still don't have files from a previous version. Is better to remove the entire scripts folder and to verify game's integrity (if you're using Steam or GOG). The missing files will be downloaded again (the scripts folder has 20 MB).
  14. Check the script files. For example the starting alchemy recipes and crafting schematics are added in W3PlayerWitcher::OnSpawned (playerWitcher.ws) function: // Add starting alchemy recipes AddAlchemyRecipe('Recipe for Swallow 1',true,true); AddAlchemyRecipe('Recipe for Cat 1',true,true); AddAlchemyRecipe('Recipe for White Honey 1',true,true); AddAlchemyRecipe('Recipe for Samum 1',true,true); AddAlchemyRecipe('Recipe for Grapeshot 1',true,true); AddAlchemyRecipe('Recipe for Specter Oil 1',true,true); AddAlchemyRecipe('Recipe for Necrophage Oil 1',true,true); AddAlchemyRecipe('Recipe for Alcohest 1',true,true); // CRAFTING ITEM SCHEMATICS AddStartingSchematics();and // New mutagen recipes, added here to work with old saves AddAlchemyRecipe('Recipe for Mutagen red',true,true); AddAlchemyRecipe('Recipe for Mutagen green',true,true); AddAlchemyRecipe('Recipe for Mutagen blue',true,true); AddAlchemyRecipe('Recipe for Greater mutagen red',true,true); AddAlchemyRecipe('Recipe for Greater mutagen green',true,true); AddAlchemyRecipe('Recipe for Greater mutagen blue',true,true); AddCraftingSchematic('Starting Armor Upgrade schematic 1',true,true);The Wolven Hour potion is added in W3PlayerWitcher::ApplyPatchFixes function (playerWitcher.ws): //potion reducing level requirement if(FactsQuerySum("LevelReqPotGiven") < 1) { FactsAdd("LevelReqPotGiven"); inv.AddAnItem('Wolf Hour', 1, false, false, true); }Search for a file named temp.ws for few examples, so you don't have too look in the XML files for every item name.
  15. When you want to modify a script file you must copy it into a mod folder, but also you must keep the same relative path. In this case: 1. First create the folder for a new mod: let's say mods\modIncreaseRewards. 2. The scripts inside mods must be in content\scripts folder, so create these folders too. 3. The r4game.ws file is inside game folder, so you must create this folder too. The result should be mods\modIncreaseRewards\content\scripts\game. This is where you copy the r4game.ws file before you can change it.
  16. In r4game.ws is an event handler named OnGiveReward. Copy the file to a new mod, find this code (line 968): multiplier = thePlayer.GetRewardMultiplier( rewardName ); inv.AddMoney( (int)(rewrd.gold * multiplier) ); thePlayer.RemoveRewardMultiplier(rewardName); and change it to multiplier = thePlayer.GetRewardMultiplier( rewardName ); // mod start: +50% more gold if (target == thePlayer) { multiplier = multiplier * 1.5; } // mod end inv.AddMoney( (int)(rewrd.gold * multiplier) ); thePlayer.RemoveRewardMultiplier(rewardName); Don't edit the file from game's scripts folder!
  17. I can't test it, but try this: 1. Create the mods\modNoQuen\content\scripts\game\player path. 2. Copy the content\content0\scripts\game\player\r4player.ws file in the folder you've just created. 3. Edit the r4player.ws file with a text editor. Search for "event OnSpawned" and add "DisableRadialSlot('Quen', 'modNoQuen');" after variables declaration. Something like this: event OnSpawned( spawnData : SEntitySpawnData ) { var atts : array<name>; var skill : ESkill; var i : int; var item : SItemUniqueId; DisableRadialSlot('Quen', 'modNoQuen'); AddAnimEventCallback('ThrowHoldTest', 'OnAnimEvent_ThrowHoldTest'); AddAnimEventCallback('OnWeaponDrawReady', 'OnAnimEvent_OnWeaponDrawReady'); AddAnimEventCallback('OnWeaponHolsterReady', 'OnAnimEvent_OnWeaponHolsterReady'); etc... Disable all other mods while testing.
  18. Test the latest version (v4) and see if you still have problems. The v3 had problems only when using magic as far as I know...
×
×
  • Create New...