Jump to content

Welcome to our forums!

Sign In or Register to gain full access to our forums. By registering with us, you'll be able to discuss, share and private message with other members of our community.

Photo

Turn Tail - Hotkey to drop equipped bags

2.9.9.16 Hotkey Bags Unequip Timed Action

  • Please log in to reply
12 replies to this topic

#1 The_Real_Al

The_Real_Al

    Often Mistaken for Alf

  • Members
  • PipPipPip
  • 69 posts

Posted 16 September 2013 - 02:30 PM

Did you ever run into a horde after shopping at the groceries?

 

Are you into B&E but unable to choose between the flatscreen and the piano?

 

Have you ever wondered how to easily access your inventory and get rid of that piano while frantically using your mouse to smash said horde?

 

If you can answer all three questions with 'yes' then this little script might just be the solution for you.

 

Description:

This mod adds a hotkey ( 'x' by default) to swiftly dump an equipped bag in order to reduce encumberance. It will only acknowledge bags and only those equipped in your hands or on your back. The order is Primary Hand -> Secondary Hand -> Back; one push for each item.

 

Installation:

1. Copy zip to the PZ root-directory, right click on the file and select 'Extract Here'.

2. Hit 'Yes' if asked to overwrite folders.

3. Delete zip.

 

Future Plans:

Probably a weight-flavoured system. Or even better menu-based which allows for dragging the order.

 

Known Issues:

Not working with .10 Desura build

Attached Files


  • Aricane, kinyoshi, Banjo and 2 others like this

#2 Banjo

Banjo

    Vault-Tec Comptroller

  • Members
  • PipPipPip
  • 96 posts

Posted 16 September 2013 - 02:53 PM

What an awesome idea! I wanted a way to drop equipped bags when I'm suddenly surrounded mid loot-run!

 

I'm torn thinking that this should only drop primary and secondary "hand"-carried bags, and still force the player to go into the menus like normal to remove a backpack... the downside to strapping on a big overstuffed hiking pack? :)

 

At any rate, I love the concept and look forward to giving this a try. In fact, I'll be using this permanently, I think!



#3 RoboMat

RoboMat

    Just a Wheelie-Bin

  • Members
  • PipPipPip
  • 3105 posts

Posted 16 September 2013 - 03:08 PM

Cool idea!


“Shallow men believe in luck or in circumstance. Strong men believe in ZombRand().” ― RoboMat W. Emerson
Check out my mods on pz-mods.net.

#4 Aricane

Aricane

    Eater of the Stone

  • Members
  • PipPipPip
  • 435 posts

Posted 16 September 2013 - 05:14 PM

Great job



#5 The_Real_Al

The_Real_Al

    Often Mistaken for Alf

  • Members
  • PipPipPip
  • 69 posts

Posted 18 September 2013 - 12:56 PM

Thanks guys. Got my bright moments i suppose. No more dying of hybris while looting.

 

still force the player to go into the menus like normal to remove a backpack... the downside to strapping on a big overstuffed hiking pack

I believe that would defeat the purpose of the hotkey. E.g. running around in the dark with weapon/flashlight as prim/sec hand. I made the action take double the time for the backpack though.

 

Also:

I ran into a problem when using it on the second floor of a building.

The bag appears above the player as if it was thrown onto the ceiling. You can still pick it up but it might be located on a wall or even outside the building hanging in mid-air and thus become unreachable.

 

Does anybody know about special issues with the z-coordinate?



#6 RoboMat

RoboMat

    Just a Wheelie-Bin

  • Members
  • PipPipPip
  • 3105 posts

Posted 18 September 2013 - 01:01 PM

I use:

 

    self.character:getCurrentSquare():AddWorldInventoryItem(item, 0.0, 0.0, 0.0);

 

didn't have a complaint so far...

 

I thought that these aren't absolute coordinates but rather offsets on the current tile... but who knows :P


“Shallow men believe in luck or in circumstance. Strong men believe in ZombRand().” ― RoboMat W. Emerson
Check out my mods on pz-mods.net.

#7 The_Real_Al

The_Real_Al

    Often Mistaken for Alf

  • Members
  • PipPipPip
  • 69 posts

Posted 18 September 2013 - 01:33 PM

Problem solved, new file is up. 

 

Offsets it is: I kept defining it a la x = getplayer():getx and inserted x/y/z into addworldinventoryitem(). Still wonder why it doesn't like the absolute z. Worked fine on the ground floor.



#8 RoboMat

RoboMat

    Just a Wheelie-Bin

  • Members
  • PipPipPip
  • 3105 posts

Posted 18 September 2013 - 01:38 PM

I think the offsets are values from 0 to 1 so if your player is on the ground floor the Z of the item will be zero, but if you are on the second floor the offset will be z+1 and because the item is on the second floor already it will be moved to the floor above.

 

As I said afaiu the item takes the coordinates of tile it is spawned on (notice the "self.character:getCurrentSquare()") and offsets the item from there ;)


“Shallow men believe in luck or in circumstance. Strong men believe in ZombRand().” ― RoboMat W. Emerson
Check out my mods on pz-mods.net.

#9 The_Real_Al

The_Real_Al

    Often Mistaken for Alf

  • Members
  • PipPipPip
  • 69 posts

Posted 18 September 2013 - 02:40 PM

Ha! And i thought variables x/y/z would just override getCurrentSquare. Silly me. 8-)



#10 Monkeyfizz

Monkeyfizz

    Newbie

  • Members
  • Pip
  • 4 posts

Posted 05 October 2013 - 11:47 PM

Quick question, does this work for Desuras build of PZ? If it does can someone help me out because I can't get it to work. :(



#11 The_Real_Al

The_Real_Al

    Often Mistaken for Alf

  • Members
  • PipPipPip
  • 69 posts

Posted 06 October 2013 - 11:04 PM

I fear it doesn't. Got some fancy errors as well that tell me nothing.

warning C7583: Initialization of uniform variables requires #version 120 or later

 

and a couple of

warning C7011: implicit cast from "int" to "float"



#12 Styxx42

Styxx42

    Newbie

  • Members
  • Pip
  • 4 posts

Posted 18 December 2013 - 11:27 PM

Great addition.

First post here I believe and I wanted to make sure it was for a good reason.

This is a great idea.

Thanks



#13 Strider

Strider

    "Am I not Entertained?"

  • Members
  • PipPipPip
  • 623 posts

Posted 27 January 2014 - 03:58 PM

Good job. 







Also tagged with one or more of these keywords: 2.9.9.16, Hotkey, Bags, Unequip, Timed Action