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 08-12-2003, 07:23 PM
jrm_iii jrm_iii is offline
Registered User
Join Date: Apr 2003
Posts: 162
jrm_iii is on a distinguished road
script help

how would i script something, so if the account name isnt something, the npc would do something
Reply With Quote
  #2  
Old 08-12-2003, 07:44 PM
Neoreno Neoreno is offline
Cerebrate
Neoreno's Avatar
Join Date: Aug 2001
Location: England
Posts: 1,663
Neoreno is on a distinguished road
Send a message via AIM to Neoreno
A ! and a strequals may come in handy.
__________________

Quote:
Exitus Acta Probat: The Outcome Justifies the Deed.
Reply With Quote
  #3  
Old 08-12-2003, 07:54 PM
Dach Dach is offline
call me Chad, it's cooler
Dach's Avatar
Join Date: Aug 2002
Posts: 1,899
Dach is on a distinguished road
commands.rtf -> newfeatures docs -> forums

try to use the prescribed order for learning scripts and commands
__________________
Scripting Documents:Old Script Documentation-Movement Tutorial
Reply With Quote
  #4  
Old 08-12-2003, 08:03 PM
jrm_iii jrm_iii is offline
Registered User
Join Date: Apr 2003
Posts: 162
jrm_iii is on a distinguished road
i know what they do... i just dont know how to write out the commands to make it do that...
Reply With Quote
  #5  
Old 08-12-2003, 08:10 PM
jrm_iii jrm_iii is offline
Registered User
Join Date: Apr 2003
Posts: 162
jrm_iii is on a distinguished road
heres what im tryin to do...
im makin auto-defense turrets for my house.
right now, i have if (playerenters) shootball; sleep 0.2
then the shootball; sleep 0.2 is copied a lot.
i need some way to make it fire if it is not my account.
and i need a more efficient way to make it fire. (i tried the while command, but it isnt workin)
Reply With Quote
  #6  
Old 08-12-2003, 08:18 PM
Mykel Mykel is offline
:o
Mykel's Avatar
Join Date: May 2002
Location: Canton, Ohio.
Posts: 5,526
Mykel has a spectacular aura about
Send a message via AIM to Mykel Send a message via MSN to Mykel
put this before everything.

NPC Code:
if (!playerenters&&strequals(#a,youraccount)){
your script

__________________
(Married to Skyld)
Reply With Quote
  #7  
Old 08-12-2003, 08:51 PM
jrm_iii jrm_iii is offline
Registered User
Join Date: Apr 2003
Posts: 162
jrm_iii is on a distinguished road
i put shootball; sleep 0.2
after it (using a different account)
and it doesnt fire
Reply With Quote
  #8  
Old 08-12-2003, 10:28 PM
Neoreno Neoreno is offline
Cerebrate
Neoreno's Avatar
Join Date: Aug 2001
Location: England
Posts: 1,663
Neoreno is on a distinguished road
Send a message via AIM to Neoreno
Accounts are not recognized offline.
__________________

Quote:
Exitus Acta Probat: The Outcome Justifies the Deed.
Reply With Quote
  #9  
Old 08-12-2003, 10:40 PM
VeX_RaT_Boy VeX_RaT_Boy is offline
WannaBe Scripter
VeX_RaT_Boy's Avatar
Join Date: Aug 2002
Location: Norway
Posts: 960
VeX_RaT_Boy is on a distinguished road
Send a message via ICQ to VeX_RaT_Boy Send a message via AIM to VeX_RaT_Boy Send a message via Yahoo to VeX_RaT_Boy
Quote:
Originally posted by Neoreno
Accounts are not recognized offline.
They are, if you used that account last time online.


Quote:
Originally posted by jrm_iii
i put shootball; sleep 0.2
after it (using a different account)
and it doesnt fire
Did you have a } at the end?


Also, insted of lots of sleep, you should do a loop...
__________________
-Kjetil Valen
Reply With Quote
  #10  
Old 08-13-2003, 12:14 AM
SaijinGohan SaijinGohan is offline
Registered User
SaijinGohan's Avatar
Join Date: Jul 2001
Location: U.S.A - Ohio
Posts: 536
SaijinGohan is on a distinguished road
Send a message via AIM to SaijinGohan Send a message via MSN to SaijinGohan
Quote:
Originally posted by Mykel
put this before everything.

NPC Code:
if (!playerenters&&strequals(#a,youraccount)){
your script

Try:

NPC Code:
if (playerenters&&!strequals(#a,youraccount)) {
yourscript;
}



As for the balls without copy and pasting.. I would use a timeout. I would script it for ya but that's illegal.
__________________

Job: A Legend

And you think that you have played Graal forever? Ha!
Reply With Quote
  #11  
Old 08-13-2003, 12:52 AM
Mykel Mykel is offline
:o
Mykel's Avatar
Join Date: May 2002
Location: Canton, Ohio.
Posts: 5,526
Mykel has a spectacular aura about
Send a message via AIM to Mykel Send a message via MSN to Mykel
Quote:
Originally posted by SaijinGohan


Try:

NPC Code:
if (playerenters&&!strequals(#a,youraccount)) {
yourscript;
}



As for the balls without copy and pasting.. I would use a timeout. I would script it for ya but that's illegal.
Oopsie, thx.
__________________
(Married to Skyld)
Reply With Quote
  #12  
Old 08-14-2003, 02:25 AM
osrs osrs is offline
Graalian since 1998
osrs's Avatar
Join Date: Mar 2002
Location: Brazil
Posts: 2,724
osrs is on a distinguished road
Send a message via ICQ to osrs Send a message via AIM to osrs Send a message via MSN to osrs Send a message via Yahoo to osrs
Don't try to help if you aren't scripter,Mykel
__________________
"Ability is what you are capable of doing. Motivation determines what you do. Attitude determines how well you do it."
Facebook: facebook.com/raysilvadotnet /
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 08:55 PM.


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