How do I make it so when you die your cash is divided by 2?

Please read the title.

Do you prefer wires, or channels?

1 Like

I’m attempting to do it in blocks

Inventory item manager. Have a property monitor the amount of items, and then detect on death, take the property, store it in another so it doesn’t mess up the property, divide that amount by two, clear inventory of cash, and grant the custom amount of property no. 2.

You will need a item manager, and property, a lifecycle, and a item granter.

Make it so the item manager updates a property. Let’s just call it cash. Then you put it in the property device. make sure that the property type is number, and the scope is player.

Then go to the lifecycle device. change the event to “Player Knocked Out”. Wire it on “Run wire pulse block” like this:

then go into the item granter, put it on cash, blocks and copy this code

1 Like

oh my bad, what @WhoAmI said. didn’t know you were typing

2 Likes

Simplified:

  1. Inventory item manager to regulate cash. Link it to property 1.
  2. On player knockout, set property 1=property 2.
  3. Clear Inventory Of All Cash
  4. Grant player custom amount: Property 2 divided by 2.

I just dropped in just now and typed up a quick answer lol. I think you were typing first.

1 Like

Thx @WhoAmI and @Lolo !

1 Like

That worked!

1 Like

I love how everybody gave examples but never said anything about my guide but with cash instead of energy.

1 Like

I was thinking of that but coudn’t find the guide

1 Like

Ok. For reference here it is:

You would of done cash and knockouts, but it doesn’t matter.

Thank you!

This topic was automatically closed 3 hours after the last reply. New replies are no longer allowed.