It is currently Mon Dec 01, 2008 10:54 am

All times are UTC - 8 hours




Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Script request random number...
PostPosted: Fri Aug 18, 2006 12:22 pm 
Offline

Joined: Fri Apr 14, 2006 9:36 am
Posts: 240
095

Could someone make a me a script that just makes a random number between 1 and 50, and sets it to a variable and if it turns out to be 7 create an item(Ill edit the item so for now just make it 0x0000) in the backpack of the person who won.. Thanks :d(Its for a voting script)


Top
 Profile  
 
 Post subject: Re: Script request random number...
PostPosted: Fri Aug 18, 2006 1:29 pm 
Offline

Joined: Fri Feb 03, 2006 6:32 am
Posts: 104
Location: Austria
<e.g. some .textcommand...>

Code:
use uo;
use os;
use util;

program randomstuff(who)

  var itemtocreate:=0x0000;
  var itemamount:=1;

  var randomnumber:=randomint(50)+1; //randomint(50) = 0....49
  if(randomnumber == 7)
    CreateItemInBackpack( who, itemtocreate, itemamount);
    sendsysmessage(who,"congrats...you won....uhm.. a nonexisting item");
  endif

endprogram


hope that helps

_________________
[url=www.etheria.org]
Etheria - Roleplaying Realism
Image [/url]


Top
 Profile  
 
 Post subject:
PostPosted: Fri Aug 18, 2006 1:42 pm 
Offline
Certified POL Expert
User avatar

Joined: Thu Feb 02, 2006 1:41 pm
Posts: 1219
Location: Southern Central USA
Hmmm...
Firedancer your script brings up an interesting question.

Can one create a non-existing item? If the item doesn't exist after creation then was anything actually created?

The created item may exist in an alternate dimension and thus we might perceive it as being a non-existant item but I do not believe it is possible to create, in our dimension, an item that does not exist.

Care to offer any thoughts Firedancer?

_________________
Sincerely,
Yukiko

I know you think you understand what you thought I said but what you heard is not exactly what I meant.

Titus 2:13


Top
 Profile  
 
 Post subject:
PostPosted: Fri Aug 18, 2006 1:51 pm 
Offline

Joined: Fri Apr 14, 2006 9:36 am
Posts: 240
Thanks fire dancer, and uhh yukiko.. what the heck?


Top
 Profile  
 
 Post subject:
PostPosted: Fri Aug 18, 2006 1:54 pm 
Offline
Certified POL Expert
User avatar

Joined: Thu Feb 02, 2006 1:41 pm
Posts: 1219
Location: Southern Central USA
*laughs*

I was teasing Firedancer. In his script the sys message says "congrats...you won....uhm.. a nonexisting item".

_________________
Sincerely,
Yukiko

I know you think you understand what you thought I said but what you heard is not exactly what I meant.

Titus 2:13


Top
 Profile  
 
 Post subject:
PostPosted: Fri Aug 18, 2006 3:11 pm 
Offline

Joined: Fri Apr 14, 2006 9:36 am
Posts: 240
Hehe.. taking a while to test if it makes the item or not lol... Hope it does work though


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 19, 2006 1:39 am 
Offline

Joined: Fri Feb 03, 2006 6:32 am
Posts: 104
Location: Austria
hehe...
actually I guess the script will not work as long as the item-id is 0.... though I didn't want to confuse anyone by using a line of code like:

sendsysmessage(who,"congrats...you won....uhm.. an error message");

even though that would have been more accurate *laughs*

though back to answering your question, Yukiko: as the item does neither exist by definition nor has it been specified, I doubt it would be possible to have accidantly been created in other dimensions.... but then even if creating nothingness.... you might still have created something... even if that something is nothing.... wouldn't you agree? if god created the world, he had to create a lot of nothing after all as well.... *rofl*

_________________
[url=www.etheria.org]
Etheria - Roleplaying Realism
Image [/url]


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 19, 2006 6:45 am 
Offline

Joined: Fri Apr 14, 2006 9:36 am
Posts: 240
It works ;)


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 21, 2006 9:27 pm 
Offline
Certified POL Expert
User avatar

Joined: Thu Feb 02, 2006 1:41 pm
Posts: 1219
Location: Southern Central USA
Yes Firedancer. I guess the question truly boils down to "Is nothing really something?"

*giggles*

I guess we'll leave that to the quantum physicists out there.

_________________
Sincerely,
Yukiko

I know you think you understand what you thought I said but what you heard is not exactly what I meant.

Titus 2:13


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 21, 2006 9:45 pm 
This thread hurts me head! :twisted:


Top
  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Style based on FI Subice by phpBBservice.nl