Particle's Custom RPG
Assistance => Assistance & Feedback => Topic started by: FrieD on July 6, 2003 08:21 pm CDT
-
I was wondering what i am doing wrong here. I am wanting to make beer for a server and it wont work can u help me
};
$HardcodedItemCost[Beer] = 5;
$HardcodedItemCost[GodlyBeer] = 10;
$HardcodedItemCost[Shot] = 5;
$HardcodedItemCost[Magirita] = 10;
}
//=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
// Beer
//=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
$AccessoryVar[Beer, $Weight] = 0;
$AccessoryVar[Beer, $MiscInfo] = "Beer";
ItemData Beer
{
description = "Beer";
shapeFile = "armorKit";
heading = "eMiscellany";
className = "Accessory";
shadowDetailMask = 4;
price = 0;
};
function Beer::onUse(%player,%item)
{
%clientId = Player::getClient(%player);
Player::decItemCount(%player,%item);
%hp = fetchData(%clientId, "HP");
refreshHP(%clientId, -0.15);
refreshAll(%clientId);
if(fetchData(%clientId, "HP") != %hp)
UseSkill(%clientId, $SkillHealing, True, True);
}
$AccessoryVar[GodlyBeer, $Weight] = 0;
$AccessoryVar[GodlyBeer, $MiscInfo] = "Beer For the Gods";
ItemData GodlyBeer
{
description = "GodlyBeer";
shapeFile = "armorKit";
heading = "eMiscellany";
className = "Accessory";
shadowDetailMask = 4;
price = 0;
};
function GodlyBeer::onUse(%player,%item)
{
%clientId = Player::getClient(%player);
Player::decItemCount(%player,%item);
%hp = fetchData(%clientId, "HP");
refreshHP(%clientId, -0.6);
refreshAll(%clientId);
if(fetchData(%clientId, "HP") != %hp)
UseSkill(%clientId, $SkillHealing, True, True);
}
$AccessoryVar[Shot, $Weight] = 0;
$AccessoryVar[Shot, $MiscInfo] = "A shot of the finest rum";
ItemData Shot
{
description = "Shot";
shapeFile = "armorKit";
heading = "eMiscellany";
className = "Accessory";
shadowDetailMask = 4;
price = 0;
};
function Shot::onUse(%player,%item)
{
%clientId = Player::getClient(%player);
Player::decItemCount(%player,%item);
refreshMANA(%clientId, -16);
refreshAll(%clientId);
}
$AccessoryVar[Magirita, $Weight] = 0;
$AccessoryVar[Magirita, $MiscInfo] = "An icey Womens Drink";
ItemData Magirita
{
description = "Magirita";
shapeFile = "armorKit";
heading = "eMiscellany";
className = "Accessory";
shadowDetailMask = 4;
price = 0;
};
function Magirita::onUse(%player,%item)
{
%clientId = Player::getClient(%player);
Player::decItemCount(%player,%item);
refreshMANA(%clientId, -50);
refreshAll(%clientId);
}
-
What's wrong with it?
-
i get it to work on my server but then i send it to my friend who has a server and the no one can talk
-
if(fetchData(%clientId, "HP") != %hp)
no semi colon???
-
duh, there is no semi colons on if statements.
-
hehe
I suppose vort would code like this:
if(1 == 2);
{;
dbecho(1, "1 equals 2");
};
-
with 3 errors and an if statement thats never possible.
-
umm that still doesnt fix my problem thanx
-
*sigh* be a little more pushy. from what you said, its not your problem, its your friends problem.
-
ok i see now thanks guys
-
awww.. There is no fun in that.. code it so you can get drunk...
function drunk(%player)
{
%ds::saynum = "4";
%ds::say[0] = "*burp*";
%ds::say[1] = "uhh hahahahahahah";
%ds::say[2] = "im not as think as you drunk i am";
%ds::say[3] = "hhhheeeellllloooo";
%id = Player::GetClient(%player);
%drunksay = floor(getRandom() * %ds::saynum);
remotesay(%id, %drunksay);
}
//=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
// Beer
//=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
$AccessoryVar[Beer, $Weight] = 0;
$AccessoryVar[Beer, $MiscInfo] = "Beer";
ItemData Beer
{
description = "Beer";
shapeFile = "armorKit";
heading = "eMiscellany";
className = "Accessory";
shadowDetailMask = 4;
price = 0;
};
function Beer::onUse(%player,%item)
{
%clientId = Player::getClient(%player);
Player::decItemCount(%player,%item);
%hp = fetchData(%clientId, "HP");
refreshHP(%clientId, -0.15);
refreshAll(%clientId);
if(fetchData(%clientId, "HP") != %hp)
UseSkill(%clientId, $SkillHealing, True, True);
}
$AccessoryVar[GodlyBeer, $Weight] = 0;
$AccessoryVar[GodlyBeer, $MiscInfo] = "Beer For the Gods";
ItemData GodlyBeer
{
description = "GodlyBeer";
shapeFile = "armorKit";
heading = "eMiscellany";
className = "Accessory";
shadowDetailMask = 4;
price = 0;
};
function GodlyBeer::onUse(%player,%item)
{
%clientId = Player::getClient(%player);
Player::decItemCount(%player,%item);
%hp = fetchData(%clientId, "HP");
refreshHP(%clientId, -0.6);
refreshAll(%clientId);
if(fetchData(%clientId, "HP") != %hp)
UseSkill(%clientId, $SkillHealing, True, True);
drunk(%player);
}
-
lol thanks alot
-
Wow, particle... code?
-
If you don't think I code, you don't know me whatsoever. Over the past month, I've probably written a couple million bytes of code.
-
He was asking if you would code that in.
That is a sorry drunk script, but it gets the idea across.
If I would do something like that, I would have them jump around, say things ect.
-
fall down