Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 04-12-2002, 05:39 AM
Googi Googi is offline
A Serious Epidemic
Googi's Avatar
Join Date: Oct 2001
Location: Canada
Posts: 18,866
Googi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud of
Send a message via AIM to Googi
Dumb script that won't work

NPC Code:

if (created) {
setimg door.png;
setshape 1,32,32;
mine.onea=0;
}
if (playerchats&&strequals(#c,rent mine 1)&&playergralat<5&&mine.onea=0){
playergralat-=5;
tokenize #a;
mine.onea=1;
say2 You have mine 1 for 30 minutes;
timeout=1800;
}
if (playerchats&&strequals(#c,rent mine 1)&&mine.onea=1){
say2 That mine is rented already;
}
if (playerchats&&strequals(#c,rent mine 1)&&playergralat<5&&mine.onea=0){
say2 You need 5g to rent a mine!;
}
if (playertouchsme&&(#a,#t)&&mine.onea=1){
setlevel2 rentmine2.nw,6,7;
}



I keep getting the "this mine is already rented" message.
__________________
Reply With Quote
  #2  
Old 04-12-2002, 06:07 AM
Slaktmaster Slaktmaster is offline
man with the mastahplan
Slaktmaster's Avatar
Join Date: Apr 2001
Location: Half-way over the river styx
Posts: 4,422
Slaktmaster is an unknown quantity at this point
Send a message via ICQ to Slaktmaster Send a message via AIM to Slaktmaster
Re: Dumb script that won't work

NPC Code:

if (created) {
setimg door.png;
setshape 1,32,32;
mine.onea=0;
}
if (playerchats&&strequals(#c,rent mine 1)&&playergralats=>5&&mine.onea=0){
playergralats-=5;
setstring this.oneaowner,#a;
mine.onea=1;
say2 You have mine 1 for 30 minutes;
timeout=1800;
} else if (playerchats&&strequals(#c,rent mine 1)&&playergralats<5&&mine.onea=0){
say2 You need 5g to rent a mine!;
} else if (playerchats&&strequals(#c,rent mine 1)&&mine.onea=1){
say2 That mine is rented already;
}
if (playertouchsme&&(#s(this.oneaowner),#a)&&mine.one a=1){
setlevel2 rentmine2.nw,6,7;
}

Reply With Quote
  #3  
Old 04-12-2002, 06:50 AM
Googi Googi is offline
A Serious Epidemic
Googi's Avatar
Join Date: Oct 2001
Location: Canada
Posts: 18,866
Googi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud of
Send a message via AIM to Googi
Well, there were some bugs, I got them all fixed except that when I rent the mine it still won't take the 5g.
__________________
Reply With Quote
  #4  
Old 04-12-2002, 08:50 AM
Dustey Dustey is offline
Registered User
Join Date: Nov 2001
Location: Do You Think I Know?
Posts: 193
Dustey is on a distinguished road
Send a message via AIM to Dustey
Quote:
Originally posted by Googi
Well, there were some bugs, I got them all fixed except that when I rent the mine it still won't take the 5g.
for the gralats its not "playergralat"

it is

"playerrupees" i think that is spelt right if that dont work put another p on rupees

[edit] sometime if your stuck look at npc and player vars in the list to the side [/edit]
__________________
And Yes I work For.... Renegade
Reply With Quote
  #5  
Old 04-12-2002, 09:25 AM
Googi Googi is offline
A Serious Epidemic
Googi's Avatar
Join Date: Oct 2001
Location: Canada
Posts: 18,866
Googi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud of
Send a message via AIM to Googi
Okay, got it working.
__________________
Reply With Quote
  #6  
Old 04-12-2002, 02:41 PM
Slaktmaster Slaktmaster is offline
man with the mastahplan
Slaktmaster's Avatar
Join Date: Apr 2001
Location: Half-way over the river styx
Posts: 4,422
Slaktmaster is an unknown quantity at this point
Send a message via ICQ to Slaktmaster Send a message via AIM to Slaktmaster
Quote:
Originally posted by Kaimetsu
Surely the G2K1 NAT would:

a) Be able to script a mine-renting system in 5 seconds.
b) Not accept a script from someone as inexpert as you.

So why bother?
You are just too right.
Reply With Quote
  #7  
Old 04-12-2002, 06:52 PM
Spanko Spanko is offline
Squeaker of Soles
Spanko's Avatar
Join Date: Nov 2001
Location: The Netherworl...lands
Posts: 1,366
Spanko is on a distinguished road
Send a message via ICQ to Spanko Send a message via AIM to Spanko Send a message via Yahoo to Spanko
Quote:
Originally posted by Kaimetsu
Surely the G2K1 NAT would:

a) Be able to script a mine-renting system in 5 seconds.
b) Not accept a script from someone as inexpert as you.

So why bother?
Hey, at least, unlike most people here, he makes the effort of attempting to script it.
__________________

ICQ: 125283920
MSN: [email protected]
AIM: Squeax0r
Squeaker seems unable to access the forum using this account.. tis a sad day.
Now with occasional Asuka flavour! Ooops a bit too much...
Asuka should be king of Dustari!

"Y'know, some days even my lucky rocketship underpants don't even help."
Reply With Quote
  #8  
Old 04-12-2002, 07:50 PM
Spanko Spanko is offline
Squeaker of Soles
Spanko's Avatar
Join Date: Nov 2001
Location: The Netherworl...lands
Posts: 1,366
Spanko is on a distinguished road
Send a message via ICQ to Spanko Send a message via AIM to Spanko Send a message via Yahoo to Spanko
Quote:
Originally posted by Kaimetsu


For which I give him credit. However, I feel it only charitable to point out the futility of his actions.
Yes, but it did sound rather discouraging. If someone had said to you when you first started programming "It's futile, someone else could do it better then you" wouldn't you feel slightly discouraged?
__________________

ICQ: 125283920
MSN: [email protected]
AIM: Squeax0r
Squeaker seems unable to access the forum using this account.. tis a sad day.
Now with occasional Asuka flavour! Ooops a bit too much...
Asuka should be king of Dustari!

"Y'know, some days even my lucky rocketship underpants don't even help."
Reply With Quote
  #9  
Old 04-12-2002, 11:48 PM
Googi Googi is offline
A Serious Epidemic
Googi's Avatar
Join Date: Oct 2001
Location: Canada
Posts: 18,866
Googi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud of
Send a message via AIM to Googi
Quote:
Originally posted by Kaimetsu


For which I give him credit. However, I feel it only charitable to point out the futility of his actions.
I don't care about dumb Graal2K1 staff positions, I just want to get the damn mines up.

Beisdes, if I wanted to submit this for a staff position, I would have gotten a private scripter to de-bug this for me, and I would have tried to get the rock wall script that way.
__________________

Last edited by Googi; 04-13-2002 at 12:09 AM..
Reply With Quote
  #10  
Old 04-13-2002, 07:02 AM
Saga2001 Saga2001 is offline
Wishing he had 3 feet
Join Date: Aug 2001
Location: Basement
Posts: 1,565
Saga2001 is on a distinguished road
Send a message via ICQ to Saga2001 Send a message via AIM to Saga2001 Send a message via Yahoo to Saga2001
Graal2001_NAT account is taken by a bugs admin. ?!?!?
__________________

!Wan ( 11:27:55 AM):
can i c ur scripts please?
Zorg (RC): If I hear NPC Server call Ne0, Past Austin or Brent sexy one more time im disconnecting it
Reply With Quote
  #11  
Old 04-13-2002, 08:26 AM
Googi Googi is offline
A Serious Epidemic
Googi's Avatar
Join Date: Oct 2001
Location: Canada
Posts: 18,866
Googi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud of
Send a message via AIM to Googi
Quote:
Originally posted by Kaimetsu

b) Not accept a script from someone as inexpert as you.
True, but it has a slightly higher chance then endlessly bugging the admins.
__________________
Reply With Quote
  #12  
Old 04-13-2002, 08:24 PM
Googi Googi is offline
A Serious Epidemic
Googi's Avatar
Join Date: Oct 2001
Location: Canada
Posts: 18,866
Googi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud ofGoogi has much to be proud of
Send a message via AIM to Googi
Quote:
Originally posted by Kaimetsu

I doubt it :-/
Key word was slightly
__________________
Reply With Quote
  #13  
Old 04-16-2002, 07:20 AM
Neonight Neonight is offline
where da wmdz at
Neonight's Avatar
Join Date: Jun 2001
Location: Windsor, Illinois
Posts: 3,665
Neonight is on a distinguished road
Send a message via AIM to Neonight
Re: Dumb script that won't work

NPC Code:

if (created) {
setimg door.png;
setshape 1,32,32;
mine.onea=0;
}
if (playerchats&&strequals(#c,rent mine 1)&&playergralat<5&&mine.onea=0){
playergralat-=5;
tokenize #a;
mine.onea=1;
say2 You have mine 1 for 30 minutes;
timeout=1800;
}
if (playerchats&&strequals(#c,rent mine 1)&&mine.onea=1){
say2 That mine is rented already;
}
if (playerchats&&strequals(#c,rent mine 1)&&playergralat<5&&mine.onea=0){
say2 You need 5g to rent a mine!;
}
if (playertouchsme&&(#a,#t)&&mine.onea=1){
setlevel2 rentmine2.nw,6,7;
}



&&playergralat=>5;
< is less than
> is more than
Reply With Quote
  #14  
Old 04-16-2002, 07:55 AM
Cybnext_Design Cybnext_Design is offline
Registered User
Join Date: Jun 2001
Posts: 244
Cybnext_Design is on a distinguished road
Send a message via AIM to Cybnext_Design
Quote:
Originally posted by Saga2001
Graal2001_NAT account is taken by a bugs admin. ?!?!?
He got the account like a minute before I was going to get it.
Atleast I happen to be an NPC Maker.
__________________
Graal2001 NPC Maker
Frolic Owner
Aim: C Y B N E X T
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 05:46 PM.


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