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-09-2002, 02:32 AM
Spark910 Spark910 is offline
Ex-Graal Global
Spark910's Avatar
Join Date: Oct 2001
Location: England
Posts: 10,892
Spark910 has a spectacular aura about
Can you use this on None P2p:

Can you use:

triggeraction on non p2p

?
__________________
--Spark911
Reply With Quote
  #2  
Old 04-09-2002, 02:44 AM
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
I think it's allowed, though I'm not completely sure.
It certainly makes things much more normally possible then otherwise.
__________________

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
  #3  
Old 04-09-2002, 03:34 AM
royce royce is offline
Banned
royce's Avatar
Join Date: Sep 2001
Location: Yakitinzen, China
Posts: 2,271
royce is on a distinguished road
Send a message via AIM to royce
triggeraction x,y,action,params,.....;

It triggers action "action" at x y, however they failed to mention that you can add params, mostly for p2p stuff..but awww heck...
watch:


code:--------------------------------------------------------------------------------
if (playertouchsme) toweapons weapon;
if (playerchats) triggeraction playerx+1.5,playery+2,weapon,name,#c,#a;
if (actionname) setplayerprop #c,#p(1): #p(0);
--------------------------------------------------------------------------------

talk about a loop...
Reply With Quote
  #4  
Old 04-09-2002, 03:40 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
Yeah, it's allowed.
Reply With Quote
  #5  
Old 04-09-2002, 04:33 AM
happyme happyme is offline
Registered User
Join Date: Mar 2002
Location: Toronto, Ontario, Canada
Posts: 142
happyme is on a distinguished road
Send a message via AIM to happyme
Quote:
Originally posted by Slaktmaster
Yeah, it's allowed.
un and alot of other people have it, so why cat you :P?
__________________
Reply With Quote
  #6  
Old 04-09-2002, 06:15 AM
Gohan43331 Gohan43331 is offline
Registered User
Join Date: Jan 2002
Posts: 87
Gohan43331 is on a distinguished road
Send a message via AIM to Gohan43331
Quote:
Originally posted by royce
if (playerchats) triggeraction playerx+1.5,playery+2,weapon,name,#c,#a;
so it's x,y,weapon,action,params...

I thought it was action before weapon

*Goes back to fix his system npcw*

[edit]

Funny thing is, that's not working either....

*ponders if he's doing this right...*

NPC Code:

if (weaponfired) triggeraction playerx+this.xdirgo[playerdir],playery+this.ydirgo[playerdir],-system,steal,#s(client.skill),#s(client.dex);


and in player system:
NPC Code:

if (actionsteal) {
if (isweapon) {
playerrupees-=strtofloat(#p(1))/2;
}
}



Can you see anything wrong?

Last edited by Gohan43331; 04-09-2002 at 06:25 AM..
Reply With Quote
  #7  
Old 04-09-2002, 08:25 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
Quote:
Originally posted by Gohan43331


so it's x,y,weapon,action,params...

I thought it was action before weapon

*Goes back to fix his system npcw*

[edit]

Funny thing is, that's not working either....

*ponders if he's doing this right...*

NPC Code:

if (weaponfired) triggeraction playerx+this.xdirgo[playerdir],playery+this.ydirgo[playerdir],-system,steal,#s(client.skill),#s(client.dex);


and in player system:
NPC Code:

if (actionsteal) {
if (isweapon) {
playerrupees-=strtofloat(#p(1))/2;
}
}



Can you see anything wrong?
it looks like that isweapon test is failing...? maybe? also why are you using +this.dirgo? I think you want playerx+1.5,playery+2...
__________________

!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
  #8  
Old 04-09-2002, 09:47 AM
Gohan43331 Gohan43331 is offline
Registered User
Join Date: Jan 2002
Posts: 87
Gohan43331 is on a distinguished road
Send a message via AIM to Gohan43331
Well, i use that for later, when it needs to test other people...I guess i might try 1.5,2....see what happens

[edit]
Still no luck....do you think this would work online?
[/edit]
Reply With Quote
  #9  
Old 04-09-2002, 05:30 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 Gohan43331
Removed long post
Nah, the Weapon is only necesarry when you are calling to the serverside part of a weapon.
Otherwise if you want to call a weapon you'll just have to use callweapon.
__________________

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
  #10  
Old 04-10-2002, 01:31 AM
amonrabr amonrabr is offline
Scripter
Join Date: Nov 2001
Location: Brazil
Posts: 374
amonrabr is on a distinguished road
Re: Can you use this on None P2p:

Quote:
Originally posted by Spark910
Can you use:
triggeraction on non p2p?
yap
Reply With Quote
  #11  
Old 04-10-2002, 01:43 AM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
I think newfeatures2001.txt says triggeraction is for p2p only...I could be wrong though
__________________
Reply With Quote
  #12  
Old 04-10-2002, 03:00 AM
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 G_yoshi
I think newfeatures2001.txt says triggeraction is for p2p only...I could be wrong though
I checked, it doesn't say anything about where it may be used or not.
__________________

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
  #13  
Old 04-10-2002, 04:10 AM
Gohan43331 Gohan43331 is offline
Registered User
Join Date: Jan 2002
Posts: 87
Gohan43331 is on a distinguished road
Send a message via AIM to Gohan43331
Quote:
Originally posted by Spanko

Nah, the Weapon is only necesarry when you are calling to the serverside part of a weapon.
Otherwise if you want to call a weapon you'll just have to use callweapon.
Well, *TECHNICALLY* none of it's client-side (unless toweapons is cs, which i think it is) I wanted to see if i could do it without callweapon, since you can't use variables... :-/

[edit] (instead of a new post )

Could this be done with p2p?
NPC Code:

this.dex=client.dex;
this.pplevel=client.pplevel;
with(players[testplayer(playerx,playery)]) {
dostuff;
}


It would be able to access those this.-vars from inside the with, since it isn't accessing a npc (with it's own this.-vars), right?

[/edit]

Last edited by Gohan43331; 04-10-2002 at 04:49 AM..
Reply With Quote
  #14  
Old 04-10-2002, 03:48 PM
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
Quote:
Originally posted by Kaimetsu


Wha...? All clientside commands are clientside. That's why they're called "clientside commands".
I love kai, he is the cheese in my sandwitch.

I believe that if you wrote the code correctly, it would work d00d, maybe just do tests at every stop to see whats happeneing...
__________________

!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
  #15  
Old 04-11-2002, 04:15 AM
Gohan43331 Gohan43331 is offline
Registered User
Join Date: Jan 2002
Posts: 87
Gohan43331 is on a distinguished road
Send a message via AIM to Gohan43331
Quote:
Originally posted by Kaimetsu


Wha...? All clientside commands are clientside. That's why they're called "clientside commands".

Heheh Mmmkay

Quote:
Players' this.vars are stored clientside, and thus cannot be accessed by the server. So any this.vars within the with structure would refer simply to those of the NPC running the script. [/B]
By players' this.-vars you mean client.-vars? Or are there actually this.-vars for the client?
Reply With Quote
  #16  
Old 04-19-2002, 05:55 AM
Deadly_Killer Deadly_Killer is offline
Registered User
Join Date: Feb 2002
Posts: 227
Deadly_Killer is on a distinguished road
Post P2P

It doesn't matter about p2p or not. Graal is going p2p in about 2 or 3 weeks.
__________________
- Zidane / Zidaya
Reply With Quote
  #17  
Old 04-19-2002, 07:01 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
Quote:
Originally posted by royce
triggeraction x,y,action,params,.....;
code:--------------------------------------------------------------------------------
if (playertouchsme) toweapons weapon;
if (playerchats) triggeraction playerx+1.5,playery+2,weapon,name,#c,#a;
if (actionname) setplayerprop #c,#p(1): #p(0);
--------------------------------------------------------------------------------

talk about a loop...
Actually that wouldn't loop, only if the player chat is set be the player does playerchats trigger...(I am 90% pausitive)
__________________

!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
  #18  
Old 04-26-2002, 09:18 PM
emortylone emortylone is offline
Registered User
Join Date: Apr 2002
Location: Control-NPC
Posts: 834
emortylone is on a distinguished road
I don't use it often, but from what i've read and been told, then triggeraction works on non=p2p and is legal. At first someone told me it wasn't, be EVERYONE else that i talked to says it is allowed and works just fine. So i'd say Hell yes it worx.
---Shifter
__________________
Quote:
*Stefan: it seems sometimes they hire newbie scripters everywhere x-x
*Stefan: scripters are sometimes like people that draw paintings
*Stefan: all that counts is that it looks nice
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 09:44 PM.


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