# How do you play certain event by small possibility?

I know how to play an event by 50percent and 25percent chance but can you make it happen by for ex. 7 percent? help would be appreciated!

Thereās lots of ways to pull it off! I used to use a custom macro that went a bit like this. Iād offer the macro but I hadnāt used it in forever. However this works for simple 7/100 chance. Thereās better ways to pull this off but this is an easy one if your scale is straightforward.

1 Like

Is that āappendā used only for showing purposes? (Iām noob sorry)

Yep, the only part you need is the part I squared in red. The print was just proof it works. Itās a simple operation but I usually proof test what I tell people here in case I overlook something. Still entirely possible I overlook things though! I do recommend making it a macro if you use this often.

This is good for simple operations, but if you need weighted randomness or say a drop rate system youāll need to use a different way.

(Last question sorry!)

just to make sure, so is this correct that I overlap the triggerbox, an event occurs by 14% chance?

Hum, I guess you have 86% chance of firing the event. You must use a value of 86 for your int var.
You could alternatively use the node ārandom bool with weightā that goes from 0 to 1 (100%) . A weight of 0.07 will fire at 7% chance

2 Likes

You got it! As long as the value in that variable Percent 14 is 14.

Indeed Iāve mistaken the sign

2 Likes