Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Stand help.... (https://forums.graalonline.com/forums/showthread.php?t=13144)

joseyisleet 09-28-2001 05:35 AM

Stand help....
 
Okay I've been trying to make a selling stand like there is on 2001. I'm having problems taking the persons item and putting it in front of them. I deleted my old script on trying to do it because there was way to many errors. Here's what I've done so far.

// NPC made by Josey Hunt
if (playerenters&&this.bought=0){message Buy this stand for 100 gralat and sell your items!;}
if (playerenters&&this.bought=1){message #s(server.standowner) owns this stand.;}
if (playerchats&&strequals(#c,Buy stand)&&this.bought=0&&100>itemprice&&playerrupees >=99&&!playerrupees<=99){
playerrupees-=100;this.bought=1;setstring server.standowner,#n;message #s(server.standowner) owns this stand.;}
if (playerchats&&strequals(#c,Buy stand)&&this.bought=1){
message #s(server.standowner) already owns this stand!;}




Not much I know, but could someone give me a push in the righ direction?

Shard_IceFire 09-28-2001 06:24 AM

=/ sorry bud.

nyghtGT 09-28-2001 06:30 AM

Re: Stand help....
 
Quote:

Originally posted by joseyisleet
Okay I've been trying to make a selling stand like there is on 2001. I'm having problems taking the persons item and putting it in front of them. I deleted my old script on trying to do it because there was way to many errors. Here's what I've done so far.

// NPC made by Josey Hunt
if (playerenters&&this.bought=0){message Buy this stand for 100 gralat and sell your items!;}
if (playerenters&&this.bought=1){message #s(server.standowner) owns this stand.;}
if (playerchats&&strequals(#c,Buy stand)&&this.bought=0&&100>itemprice&&playerrupees >=99&&!playerrupees<=99){
playerrupees-=100;this.bought=1;setstring server.standowner,#n;message #s(server.standowner) owns this stand.;}
if (playerchats&&strequals(#c,Buy stand)&&this.bought=1){
message #s(server.standowner) already owns this stand!;}




Not much I know, but could someone give me a push in the righ direction?

first of all:
NPC Code:

if (playerchats&&strequals(#c,Buy stand) && this.bought=0 && playerrupees>=100&&) {
playerrupees-=100;
this.bought=1;
setstring server.standowner,#n;
message #s(server.standowner) owns this stand.;
}
There was no need for that '!playerrupees<=99'
if (playerchats && strequals(#c,Buy stand) && this.bought=1){
message #s(server.standowner) already owns this stand!;
}
That may work just add the two together ..


joseyisleet 09-28-2001 06:54 AM

i wasn't talking about help on that part of the script. i was wondering if someone could give me a good shove to the right direction on taking the players item that he says and placing it in front of him with a certain price and if another player says buy itemname they buy it for the price and the player that is selling the stuff gets the money.

Xaviar 09-28-2001 08:09 AM

Quote:

Originally posted by joseyisleet
i wasn't talking about help on that part of the script. i was wondering if someone could give me a good shove to the right direction on taking the players item that he says and placing it in front of him with a certain price and if another player says buy itemname they buy it for the price and the player that is selling the stuff gets the money.
putnpc2 :D

Speedoflight14 09-28-2001 08:12 AM

do u think that would really work??:eek:

Xaviar 09-28-2001 08:17 AM

I would be positive that it would work, except for the fact that most of my time is spent scripting for non-p2p stuff, so I've never actually tried it x_x

Speedoflight14 09-28-2001 08:21 AM

o:o

fireball_dolphonia 09-28-2001 08:30 AM

try it with
putnpc putthescriptintxt,x,y;
and look for something to takeaway the item from u

Xaviar 09-28-2001 08:34 AM

Quote:

Originally posted by fireball_dolphonia
try it with
putnpc putthescriptintxt,x,y;
and look for something to takeaway the item from u

*tries to think of a command nastier than putnpc*
*fondly remembers the days before the nttf when almost anything with putnpc in it got rejected immediately*

joseyisleet 09-28-2001 09:56 AM

hmm.
 
hmm
i guess it would work. oh well ill figure it out.


All times are GMT +2. The time now is 07:57 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.