#(niklas_) adjust random number from 1 to 6

13 messages · Page 1 of 1 (latest)

tacit pumice
#

I want to define a number from 1 to 6 for a luckgame...

When a player right clicks a block this should happen:

2 numbers are defined (from 1 to 6)

if the one number is more then the other a script should run.

soooooo what I need to know:

  • how do I define the numbers?
  • how do I compare those?
fossil mistBOT
wicked swallowBOT
#

(niklas_) adjust random number from 1 to 6

wicked swallowBOT
#

Hi I'm AutoThreadBot! Don't mind me, I'll just be adding the helper team to this thread so they can see it. A human will get to you soon.

tacit pumice
#

wurfelspiel:
type: world
events:
on player right clicks block location_flagged:wurfelspieler:
- narrate "Möchtest du Würfeln? (Kostet 2)"
- if <player.money> >= 2:
- define nummer <list[1|2|3|4|5|6].as_decimal>
- define nummer2 <list[1|2|3|4|5|6].as_decimal>
- narrate "Würfel spieler: <[nummer]> Würfel Gastgeber <[nummer2]>"
- if <[nummer]> > <[nummer2]>:
- money give quantity:4
- if <[nummer]> == <[nummer2]>:
- money give quantity:2
- if <[nummer]> < <[nummer2]>:
- stop
- else:
- narrate "Du hast keine 2"

#

this doesnt work....

jaunty crownBOT
dull loom
#

<list[1|2|3|4|5|6].as_decimal> you're trying to parse a list as a decimal

#

!t util.random.int

jaunty crownBOT
tacit pumice
#

thx