Jump to content

changing fire mode


chimeric929

Recommended Posts

NVSE required

 


short nFrame

begin gamemode
 ref rWeaponNew
 if GetKeyPressed 56 && nFrame < 60
   set nFrame to 0
   if player.GetEquipped Shotgun1 ; shotgun 1 to shotgun 2
     set rWeaponNew to Shotgun2
   elseif player.GetEquipped Shotgun2 ; shotgun 2 to shotgun 1
     set rWeaponNew to Shotgun1
   endif
; more wepon checks...

   if rWeaponNew != 0
     ; equip selected weapon to player assuming he have it in inventory. if not, this will get slightly compilated and will require item removal, addition, messing with health % item counts etc. too lazy to write that now. Not sure if it's possible to disable equip animation
     player.EquipItem rWeaponNew
   endif
 endif
 set nFrame to nFrame+1
end

Link to comment
Share on other sites

NVSE required

 


short nFrame

begin gamemode
 ref rWeaponNew
 if GetKeyPressed 56 && nFrame < 60
   set nFrame to 0
   if player.GetEquipped Shotgun1 ; shotgun 1 to shotgun 2
     set rWeaponNew to Shotgun2
   elseif player.GetEquipped Shotgun2 ; shotgun 2 to shotgun 1
     set rWeaponNew to Shotgun1
   endif
; more wepon checks...

   if rWeaponNew != 0
     ; equip selected weapon to player assuming he have it in inventory. if not, this will get slightly compilated and will require item removal, addition, messing with health % item counts etc. too lazy to write that now. Not sure if it's possible to disable equip animation
     player.EquipItem rWeaponNew
   endif
 endif
 set nFrame to nFrame+1
end

 

thank you

Link to comment
Share on other sites

  • 2 weeks later...
  • Recently Browsing   0 members

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