Taking and Receiving

Hi, I am making a cops and robbers game and I want to do it so that when the robbers get tagged the money they have goes to the cops. (Team 2) Is there anyway I can do this?

1 Like

You’ll need to use a property or an item inventory manager to track how much money the player has. Then, with a tag zone has a trigger wired to it, you can get it so the cops get the money.

1 Like

Yes, have it that when a thief is tagged out it sets a global property to the amount of money the thief has, then removes all money using a item manager. Then when a cop tags a thief, wait half a second and then grant the amount of money equal to the property amount.

1 Like

wait so do I use a property or an item inventory manager? I tried the item inventory manager and it just said take it away, not give it to the other team. (Cops)

Have one item manager tracking how much cash the player has. Then have a second property that is used when transferring the money.

1 Like

ok thank you I am going to try that

1 Like

It’s not letting me attach the wire from the tag zone to the property. Is the device called the property? Or is it called something else?

You are going to need to use block code inside of triggers to make it work.

Sorry, this is my first time doing this, what do you mean by block code? I would take the tag zone and wire it to a different device, right? Sorry for all of the questions.

If you click into a trigger you will find a tab called blocks, you can then use this to set the global money property to the player money property.

Wait so would I do a wire at all? So if I did if someone gets tagged activate trigger? Then the trigger makes it so that one team gets the money that the one player had?

You would not activate the trigger, you would trigger the trigger. So make it that when player is tagged, it triggers the trigger that sets the global money property to the players money property.

Question, do you have the money as the actual cash item or as just a property. And do you want the cash to go to just the cop who tagged the thief or to all cops.

just a property, and I want the cash ro go to all the cops

So there is one global property that all cops share for cash? But robbers have individual cash property’s?

yes, only because it adds up at the end for the robbers but I want to make it so the robbers get their money given to the cops if they get tagged

1 Like

it’s still not workking I have the wire as tag zone to trigger and when someone is tagged trigger the trigger. The property scope is applied to global. And the trigger tab, blocks, says when the trigger is triggered get the property “money”

1 Like

Show us the whole setup with screenshots, step by step. Is that fine with you?

yeah:


This is the property

This is the wire


And then this was the trigger, with the blocks tab

1 Like

Ok let me try to explain how you can fix this.

First off, you’ll want a player-based property, we’ll call it “cash”. This is how much money each individual person has. It should be connected to your inventory item manager for actual cash.

Secondly, you’ll want a team-based property called “teamCash”. This is the one connected to scoring. We’ll come back to updating it later.

Third, you’re gonna want another player-based property called “previousCash”. This is very important.

Now, we’re going to make the system to update the properties. Add a channel in your “cash” property for when the value of the property changes. We’ll wire this to a trigger to run the following code:

Set Property { "teamCash"
Value        { [get property { "teamCash" ] + { [get property { "cash" - get property { "previousCash" ]

Set Property { "previousCash"
Value        { get property { "cash"

If you don’t quite understand that, I’m sure somebody else can provide real screenshots :slight_smile:

Now, the only other thing we need to do is handle tagging. For this, we need another property “transferCash”, but this should be global.

The tag device should be wired to an item granter (when player gets tagged → run wire pulse block), and the wire pulse block in that item granter should run the following code:

Set Property { "transferCash"
Value        { get property { "cash"

Grant Player Custom Amount of Selected Item { [0 - get property { "cash"]
Broadcast Message On Channel { "TransferCashToCops"

And now that message can be picked up by a relay (specific team for the cops team), to wire to a trigger to run the following code:

Set Property { "teamCash"
Value        { "teamCash" + "transferCash"

And that’s it! I’m 90% sure this should work, but I haven’t logged on to gimkit in a while lol. Happy Gimkitting!

5 Likes