Jump to content

Returning Throwing Weapons?


Recommended Posts

i've tried some things, since you can't put scripts on throwing weapons you have to do something different... i tried with a global script, didn't work and would be basically be the same as suggestion 1... just somewhat more elegant than entering a console command xD

 

suggestion 1, just use the console and add darts xD

 

suggestion 2

 

make an amulet and put this script on it ( i would suggest to not put any enchantments on the amulet so you give up an item slot for the respawning throwing items, but that's just what i would do =P )

begin your_script

short state
short equip

if ( menumode == 1 )
	return
endif

if ( Player->HasItemEquipped "YOUR_AMULET_ID" == 0 )
	set state to 0
		if ( equip == 1 )
			Player->RemoveItem YOUR_DART_ID 1
			set equip to 0
		endif
endif

if ( Player->HasItemEquipped "YOUR_AMULET_ID" == 1 )
	set state to 1
endif

if ( state == 1 )
	if ( Player->GetItemCount YOUR_DART_ID < 5 )
		Player->AddItem YOUR_DART_ID 1
	endif
	Player->Equip YOUR_DART_ID
	set equip to 1
endif

end

there is a glitch that leaves the last dart equipped which results in infinite darts but without refilling the inventory, and it doesen't even show there anymore, but still in the equipment slot bottom left, but removing a dart when unequipping the amulet, does also unequip the darts ( which this script does )

 

fun fact, while testing this i learned that if you throw daedric darts at enemies, they equip the ones that go in their inventory and throw them back at you xDD

 

even more edit: maybe it would be good to put "Player->Equip YOUR_DART_ID" on a timer so it does not get spammed every frame... but i don't know enough if that's a problem

 

some more edit i tried it with a timer, worked less constant, sometimes darts would not get auto equipped... but i'll add the script anyways

begin your_script

short state
short equip
float timer

if ( menumode == 1 )
	return
endif

if ( state == 1 )
	if ( Player->HasItemEquipped "YOUR_AMULET_ID" == 0 )
		set state to 0
			if ( equip == 1 )
				Player->RemoveItem YOUR_DART_ID 1
				set equip to 0
			endif
	endif
endif

if ( state == 0 )
	if ( Player->HasItemEquipped "YOUR_AMULET_ID" == 1 )
		set state to 1
	endif
endif

if ( state == 1 )
	if ( Player->GetItemCount YOUR_DART_ID < 5 )
		Player->AddItem YOUR_DART_ID 1
	endif
	if ( timer >= 1 )
		Player->Equip YOUR_DART_ID
		set timer to 0
	endif
		if ( equip == 0 )	
			set equip to 1
		endif
endif

set timer to ( timer + GetSecondsPassed )

end
Edited by FIMzzZzz
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...