Object spawning cv2

can someone send a picture where if you press a button then it removes 50 rr currency and spawns in shield? i feel like this isnt a hard thing to do but im not good with circuits, so…

1 Like

Room Currency cannot be removed via circuits, it can only be removed by purchasing in-room Keys or Consumables

If you are in Rooms V1, the only way to have custom control over room currency is to use a custom int cloud variable

If you are in Rooms V2, Room Currency does not exist, instead you get full control over Inventory Items, which can act as Currency, Keys, or Consumables depending on how you set them up

Either way, regardless of what you do, this is a really simple task:

Rooms V1: As replicator does not exist, you need to pool objects underneath the map. After the button is pressed, first check if any shield objects are in the pool, if there is, then teleport the shield object to the player/equip the shield object to the player. If the teleport/equip succeeds, subtract 50 currency from the player (This way the player only loses currency if the equip was a success)
*Returning an object to this pool should be as simple as teleporting it to the pool. The pool can just be defined as a box with a trigger volume, where you use Trigger Volume Get Objects to see what the pool contains

Rooms V2: Replicator existing makes this much easier, have a replicator that spawns shields, then, whenever a player presses the button, attempt to replicate a new shield. If it fails, dont do anything, if it succeeds, equip the shield to the player. If the equip fails, either try again or return the object to the replicator. If the equip succeeds, subtract 50 currency from the player