Switching 2 items whilst always remaining equipped

Silver100

Member
Hi,

Hope you can help, (think I put this on wrong forum initially)

I'm trying to create a way to have 'always equipped' with a weapon i.e. sword switch rifle. I'm using the old input system

Just to alternate between the 2 items using just one button to alternate between those 2 states and never enter unequip.

However I'm struggling to get rid of a 3rd unequipped state.

I have only 2 default load outs so would assume just 2 states but unequip is still happening.

Under item abilities I have my set up as :

use enabled
Equip Unequip enabled
Equip next enabled
toggle set to off (experimented with on too and default on/off) doesn't make a difference.

Basically at the moment I'm attempting with one button set up created from using;

The string 'Equip Next item' input value; from project settings input Manager as joystick button 3 (Xbox Y button) But this is not working still have the unequipped state as you scroll through clicking.

Any idea the best way for this set up or able to screen shot a set up that would allow this if possible?

Thanks


Report Edit Delete
 
By default the EquipUnequip ability will always unequip the next item. To get around this you can assign the weapon that you always want to be equipped to a new slot and have a second set of EquipUnequip abilities. In the demo scene the grenade uses this method. You can throw the grenade at any time regardless of what weapons are equipped.
 
I did try this earlier but it seemed to merge with the same load out set if that makes sense. I think I may be just struggling getting to grips with item slots and item sets. The other idea I had was creating a seperate script as toggle switch x2 items assigning equip next and an equip previous item, to lock the sword and rifle in a loop, I would somehow need to work a way to code that. Default settings are nice simple and flexible I will keep experimemting. Thanks
 
Thanks Ill take a look at this. I have managed to get a work around so at least is equipped on opening scene, the main thing is the player being equipped on the opening scene as it drops from a helicopter and not having to cycle too much or easily enter unequip state. I have Set rifle as 1st load out item, sword second and switched off toggle off. So now its immediate rifle to sword then unequip.
 
Top