svartberg Posted March 8, 2015 Share Posted March 8, 2015 I'm making a mod to equip landmines, using the function "player.equipitem" The problem is it only equip one of the mines - once it is thrown (shot) it switches to fists instead of the remaining mines.(btw I get the same problem with grenades and other throwables) I want it to work properly like when you equip them ingame, e.g. you throw one and it equips the next one (instead of fists), any ideas ? Link to comment Share on other sites More sharing options...
TheBlob2 Posted March 8, 2015 Share Posted March 8, 2015 try putting a number after the equip function, like this player.equipitem (insert weapon ID here) 100 Link to comment Share on other sites More sharing options...
luthienanarion Posted March 8, 2015 Share Posted March 8, 2015 (edited) Passing a non-zero value as a second parameter to EquipItem prevents the item from being unequipped. There is no way to equip more than one mine at a time, because they are separate weapons and not ammunition. Edited March 8, 2015 by luthienanarion Link to comment Share on other sites More sharing options...
svartberg Posted March 11, 2015 Author Share Posted March 11, 2015 (edited) Cheers, ah ok too bad Ended up doing a workaround, by re-equipping the mine if the count got depleted by 1, so all good :tongue: Edited March 11, 2015 by svartberg Link to comment Share on other sites More sharing options...
vTemporalZEROv Posted March 13, 2015 Share Posted March 13, 2015 Hey, sorry to barge in, but I am looking to make a weapon that requires some script workings similar to what you are doing, think you could help me out or gimme some advice, swartberg? Link to comment Share on other sites More sharing options...
svartberg Posted March 13, 2015 Author Share Posted March 13, 2015 (edited) No worries mate, here's my code belowbasically it checks the mine count every frame, and if it got subtracted by one, and no weapon is equipped, then it means the mine got thrown. set mineCount to player.getitemcount mineType if (mineThrown == 0) if (mineCount == mineLastCount - 1) if (player.GetEquippedObject 5 == 0) set mineThrown to 1 ;printc "thrown" endif endif endif Edited March 13, 2015 by svartberg Link to comment Share on other sites More sharing options...
vTemporalZEROv Posted March 13, 2015 Share Posted March 13, 2015 Well the thing is I'm trying to make a weapon require all 3 specific weapons mods attached to it in order to be able to replace it with a different gun at a crafting bench, similar to weapon mod kits from fallout 3, but not nearly as complicated. Let's say the player has the gun with only 2 weapon mods on it out of the 3 possible mods, the option will be unavailable or grayed out in the crafting bench, but if all 3 are attached to it, then the player can choose to replace it with a different weapon, similar to the way a railway rifle or rock it launcher is made, it takes the gun with all 3 attachments on it, and gives the player a new one in place of it (it is a set weapon, not random) and this new weapon has no weapon mods on it, obviously, so you can further upgrade it. Think you can help me with that? Or is that too far beyond what you know? I'm just looking for people that can help me out with it cause I know absolutely no scripting with fallout. Link to comment Share on other sites More sharing options...
svartberg Posted March 13, 2015 Author Share Posted March 13, 2015 Ah mate you really shouldn't post it in this thread lol, make a new topic or something Link to comment Share on other sites More sharing options...
vTemporalZEROv Posted March 13, 2015 Share Posted March 13, 2015 I did x) But you know scripting so I couldn't resist asking. I will pm you if you wish instead. Link to comment Share on other sites More sharing options...
Recommended Posts