Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Nostale
You last visited: Today at 17:27

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Tutoriel] random box

Discussion on [Tutoriel] random box within the Nostale forum part of the MMORPGs category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Jul 2017
Posts: 397
Received Thanks: 60
[Tutoriel] random box

Hi, I open this topic for you to share a tutorial on a comment creates a random box.

to start you have to choose the case you want ending with a break.

example:



Once this is done, you must mark the code. You have several ways of doing thingsbut I'm going to show you my way.



Here is for example my whole code for the boxes of the raid caligor.

as soon as you put your code, you will have to go to your database, in item
you go to the item you have chosen. and you put the number of the box you have chosen in effect so 7000 and the same in effect value
redbull2905 is offline  
Old 09/21/2018, 02:42   #2
 
Tbp123's Avatar
 
elite*gold: 0
Join Date: Feb 2015
Posts: 62
Received Thanks: 15
or better use RollGeneratedItem with some changes instead?...
Tbp123 is offline  
Old 09/21/2018, 15:26   #3
 
elite*gold: 0
Join Date: Feb 2018
Posts: 27
Received Thanks: 11
First of all, don't hardcode the random item because if you add a new item you will need to change the random function because it's not going to be 13 items so at least use:
Random rnd = new Random();

short[] itemArray = { 1, 2, 3, 4 };
short item = itemArray[rnd.Next(itemArray.Count())];

short[] amountArray = { 10, 20, 30};
short amount = amountArray[rnd.Next(amountArray.Count())];

// Code to add item, amount to player
PepBDev is offline  
Reply


Similar Threads Similar Threads
[Released] Monster legends (Random Gold) (Random Food) (Random Exp)
02/03/2015 - Facebook - 6 Replies
Monster legends New Tools !! *1 - Random Gold *2 - Random Food *3 - Random Exp All Tested And Working 100% Without Any Problem :handsdown: !!! Link
DC Random 8 -> 100 Gems + Random 3M --> 18 M Food + Random 3M --> 18M Gold
01/24/2015 - Dragon City - 25 Replies
DC Random 8 -> 100 Gems + Random 3M --> 18 M Food + Random 3M --> 18M Gold Dragon City Gem + Gold + Food +Exp
Java Color.rgb(random,random,random)
05/19/2014 - Java - 4 Replies
Guten Abend liebe Community, ich habe ein Anliegen. Wie ist es möglich bei der Methode : setTextColor(Color.rgb(0,0,0)); anstatt (0,0,0) 3 random Integer zu verwenden wenn ja wie? Ich habe es mal so probiert: final Random r = new Random();



All times are GMT +1. The time now is 17:27.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.