Randomizing damage multiplier upon knockout help

I am trying to make a battle royale game where you can choose a class with specific weapons and bonuses and one of them is so that whenever you get a knockout you get a random multiplier from 1.25x to 2.5x whenever you get a knockout. I already did the block code but I need it to only work when someone chooses that class by pressing a button.

1 Like

Make your trigger(If that’s what you’re using) wired to a button, so that if the button is pressed they get random damage multiplier

Welcome to the community, @Theaxolotl!

Do you mean you want it to trigger when someone kills another person?
Maybe something like this:
Lifecycle → Overlay(Button): Player Knocks Out → Show Overlay
Overlay → Trigger: Button Pressed → Trigger???
Overlay → Wire Repeater: Button Pressed
WR → Overlay: Pulse → Hide Overlay

Does this help?

I don’t fully get it but this explanation should help you understand what I am aiming for: Button wired to knockout manager button pressed activate manager, manager not active on game start scope: player then block code like this that sends signals to damage multipliers.
Screenshot 2023-11-19 9.21.05 AM

1 Like

I don’t think that wiring is really correct. Can you tell me what you want to do? So, do you want the player, when they kill someone, they get a random damage multiplier amount?

Yes but only if that player knocked someone out after they press the button and so it only does that for the people that press that specific button.

Ok, use an Overlay button that is not activated on game start. Make the Scope Player. Get a LIFECYCLE with settings of ‘Player Knocks Out’, and wire that to the Overlay so that it shows. Wire the overlay to your trigger so that when the overlay is pressed, the trigger is triggered. In the blocks, it will give a random damage boost. That help?

That is what I want to do but how do I make it only for the people who choose that class?

Make a property that is their team. So, wire the lifecycle to a checker to see if the property(Scope player) is your specific team. If it is, then show the overlay. @Theaxolotl

It’s not teams it is free for all but multiple people can have the same class but no one is on the same team.

Then… I don’t know. But, have a property as their class. Still use the property. Do the same thing, but the property is the class. That work?

I don’t really understand properties and how to do them.

Welcome to the forum! Here is a guide on properties.
TL;DR: Properties are basically stored values.

To make properties track classes, you would first have to place a property device then give the property a name. Scroll down and set the scope to “player” so each player can have a different value. Copy and paste this for multiple properties. To change it, you can use blockcode.

If you have an answer, mark a solution!

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