First of all: Hello and thanks for taking the time.
What I want to do:
I want to run with the knife out and on keystroke throw away every weapon, all my dosh, switch to the 9mm pistol and then issue the suicide command.
Old Idea:
Algorithm:
1. Throw all the cash (which should never be more than 9999).
2. Switch to weapon slot four (If there is no weapon in the slot it remains the weapon I started with - in this case the knife).
3. Switch to weapon slot three (If there is no weapon in the slot it remains the weapon that was switched to in step two).
4. Switch to weapon slot two (If there is no weapon in the slot it remains the weapon that was switched to in step three).
5. Switch to weapon slot one (If there is no weapon in the slot ...).
6. Throw away every throwable weapon until the 9mm pistol is selected.
7. Suicide.
Algorithm:
1. Throw all the cash (which should never be more than 9999).
2. Switch to best weapon which is either the strongest onperk weapon or if there is no onperk weapon the strongest offperk weapon (If you only have the knife and 9mm pistol it will select the pistol).
6. Throw away every throwable weapon until the 9mm pistol is selected.
7. Suicide.
Reasoning for new algorithm:
Problem:
It seems like the switching animation is taking too long and the suicide and throw dosh commands are issued before the switch is complete. When I have the knife out while pressing the key, no weapons will be thrown and the last weapon in my hand is the knife. Therefore it will be dropped instead of the 9mm pistol.
Any idea for a workaround or a better algorithm? Maybe a method to wait for example one second for the next command would solve the problem, but I have not found any.
And yes, I could manually switch to a throwable weapon and then press the key or if I don't have any to the 9mm pistol, but that takes longer. Ideally I want it to do every scenario automatically just by pressing one button.
Any feedback is greatly appreciated!
What I want to do:
I want to run with the knife out and on keystroke throw away every weapon, all my dosh, switch to the 9mm pistol and then issue the suicide command.
Old Idea:
Spoiler!
Algorithm:
1. Throw all the cash (which should never be more than 9999).
2. Switch to weapon slot four (If there is no weapon in the slot it remains the weapon I started with - in this case the knife).
3. Switch to weapon slot three (If there is no weapon in the slot it remains the weapon that was switched to in step two).
4. Switch to weapon slot two (If there is no weapon in the slot it remains the weapon that was switched to in step three).
5. Switch to weapon slot one (If there is no weapon in the slot ...).
6. Throw away every throwable weapon until the 9mm pistol is selected.
7. Suicide.
Code:
<keyhere>=tosscash 9999 | switchweapon 4 | switchweapon 3 | switchweapon 2 | switchweapon 1 | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | suicide
Algorithm:
1. Throw all the cash (which should never be more than 9999).
2. Switch to best weapon which is either the strongest onperk weapon or if there is no onperk weapon the strongest offperk weapon (If you only have the knife and 9mm pistol it will select the pistol).
6. Throw away every throwable weapon until the 9mm pistol is selected.
7. Suicide.
Code:
<keyhere>=tosscash 9999 | SwitchToBestWeapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | throwweapon | suicide
Reasoning for new algorithm:
Spoiler!
I found the "SwitchToBestWeapon" and "SwitchToBestMeleeWeapon" commands and experimented a little. It does not matter what weapon is held, the "SwitchToBestWeapon" command will always switch to the strongest onperk weapon. If there are no onperk weapons it will switch to the strongest offperk weapon instead which is ALWAYS throwable. When this strongest weapon will be thrown, the game will switch to second best weapon and if that one is thrown to the thirdbest weapon and so forth. The "SwitchToBestMeleeWeapon" command does not seem to work right though, because even when a Machete is bought, it will still switch to the knife which is not throwable and interrupts the process.
I decided to take the whole idea of throwing the melee weapons out, because I can't think of any way it would switch to a melee weapon if there is another one but the knife (i.e. fireaxe) and to a non-melee weapon if there is only the knife. This is necessary because otherwise once all weapons are thrown the 9mm pistol will be selected BEFORE the throwable melee weapons.
I decided to take the whole idea of throwing the melee weapons out, because I can't think of any way it would switch to a melee weapon if there is another one but the knife (i.e. fireaxe) and to a non-melee weapon if there is only the knife. This is necessary because otherwise once all weapons are thrown the 9mm pistol will be selected BEFORE the throwable melee weapons.
Problem:
It seems like the switching animation is taking too long and the suicide and throw dosh commands are issued before the switch is complete. When I have the knife out while pressing the key, no weapons will be thrown and the last weapon in my hand is the knife. Therefore it will be dropped instead of the 9mm pistol.
Any idea for a workaround or a better algorithm? Maybe a method to wait for example one second for the next command would solve the problem, but I have not found any.
And yes, I could manually switch to a throwable weapon and then press the key or if I don't have any to the 9mm pistol, but that takes longer. Ideally I want it to do every scenario automatically just by pressing one button.
Any feedback is greatly appreciated!
Last edited: