Create a free account to remove all ad content.

Author Topic:  is there a way to do this?  (Read 636 times)

0 Members and 1 Guest are viewing this topic.

.ok

  • Supreme Member
  • *
  • Posts: 2212
    • View Profile
is there a way to do this?
« on: August 16, 2015, 08:50:03 PM »
you can do it with mobspawners,but this is my scenario:
im making a kino der toten remake and ima have the chests and pack a punch.

i was able to get a chance card into my inventory but my question is....
is there a way of where i can do a dropchance system just like how u can in mobspawners,but for like a chest?

i wanna have it to where its like zombies,and when they hit the mystery box, they have a odd chance of getting a certian weapon or item.is there any way of doing this or no?




Zoidberg

  • Legendary Member
  • *
  • Posts: 1445
    • View Profile
  • Xbox: v Zoidberg v
  • Steam: v_Zoidberg_v
Re: is there a way to do this?
« Reply #1 on: August 16, 2015, 08:56:59 PM »
Not entirely sure what you mean, but I assume you're looking for something like this:

If
IsRandom [1,20]
Then
Inventory [x,y,z] [add] [item] [qty]
ElseIf
IsRandom [1,20]
Then
Inventory [x,y,z] [add] [item] [qty]
ElseIf
IsRandom [1,20]
Then
Inventory [x,y,z] [add] [item] [qty]
...


.ok

  • Supreme Member
  • *
  • Posts: 2212
    • View Profile
Re: is there a way to do this?
« Reply #2 on: August 16, 2015, 09:00:32 PM »
Not entirely sure what you mean, but I assume you're looking for something like this:

If
IsRandom [1,20]
Then
Inventory [x,y,z] [add] [item] [qty]
ElseIf
IsRandom [1,20]
Then
Inventory [x,y,z] [add] [item] [qty]
ElseIf
IsRandom [1,20]
Then
Inventory [x,y,z] [add] [item] [qty]
...

whats the 1 and 20 stand for

and why isnt this script displayed in inventory scripts lmao




Zoidberg

  • Legendary Member
  • *
  • Posts: 1445
    • View Profile
  • Xbox: v Zoidberg v
  • Steam: v_Zoidberg_v
Re: is there a way to do this?
« Reply #3 on: August 16, 2015, 09:01:57 PM »
The [1,20] means that it has 1 in 20 chances to return true, which is a 5% chance. Not sure what you mean by that second part.


.ok

  • Supreme Member
  • *
  • Posts: 2212
    • View Profile
Re: is there a way to do this?
« Reply #4 on: August 16, 2015, 09:04:41 PM »
The [1,20] means that it has 1 in 20 chances to return true, which is a 5% chance. Not sure what you mean by that second part.
what i mean by the 2nd part is, if this is a actual script then why not have craig or whoever add this to either the inventory or other scripts in game for when you go to choose a script to make or use




Zoidberg

  • Legendary Member
  • *
  • Posts: 1445
    • View Profile
  • Xbox: v Zoidberg v
  • Steam: v_Zoidberg_v
Re: is there a way to do this?
« Reply #5 on: August 16, 2015, 09:09:50 PM »
The IsRandom command? It is in the game, it's a conditional, so to insert it you first need to have inserted an If or ElseIf statement.