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 02-06-2004, 03:31 PM
Jimmii Jimmii is offline
Registered User
Join Date: Jan 2004
Posts: 3
Jimmii is on a distinguished road
triggeraction clientside,0,0,name,param;

does this work? one of the people on my server said it doesn't, but ive seen references to it before

i need the truth
Reply With Quote
  #2  
Old 02-06-2004, 04:59 PM
adam adam is offline
http://wiki.graal.us/
adam's Avatar
Join Date: Nov 2001
Posts: 2,247
adam has a spectacular aura aboutadam has a spectacular aura about
Send a message via AIM to adam
It ought to. It's a new method.

It works in weapon npc's.
__________________
Rogue Shadow (TCN)(NAT)(Global Development Team)

For development help, contact the patrons of the #graaldt irc channel below, I am usually there.
Click Here to Join IRC Chat Now! -- irc.freenode.net Channel: #graaldt
Quote:
<Dustyshouri> no, RogueShadow is always talking about scripts lol
<Dustyshouri> in fact, he pretty much brought Graal back as a topic single-handedly
Reply With Quote
  #3  
Old 02-06-2004, 05:32 PM
Loriel Loriel is offline
Somewhat rusty
Loriel's Avatar
Join Date: Mar 2001
Posts: 5,059
Loriel is a name known to allLoriel is a name known to allLoriel is a name known to allLoriel is a name known to all
It is triggeraction 0,0,clientside,... though, the action name comes after the coordinates.
Reply With Quote
  #4  
Old 02-06-2004, 05:41 PM
WanDaMan WanDaMan is offline
Master Tux
WanDaMan's Avatar
Join Date: Aug 2002
Location: England, United Kingdom
Posts: 5,571
WanDaMan is a jewel in the roughWanDaMan is a jewel in the rough
Send a message via MSN to WanDaMan
In other words, no it wouldn't . Loriel's version is correct
Like:
if(actionserverside){
/*
do stuff
*/
}
//#CLIENTSIDE
if(created){
triggeraction 0,0,serverside,npcname,params;
}
Have fun !
__________________
V$:CONFL16T
Reply With Quote
  #5  
Old 02-06-2004, 06:12 PM
R0bin R0bin is offline
Banned
R0bin's Avatar
Join Date: Oct 2002
Location: Wales, UK
Posts: 828
R0bin is on a distinguished road
Send a message via AIM to R0bin
The actionclientside action only works for weapon npcs.

NPC Code:

Code of weapon: "Bank"
if (actionserverside) {
if (strequals(#p(0),deposit)) {
if (strtofloat(#s(clientr.money))>=strtofloat(#p(1)) {
setstring clientr.money,#v(strtofloat(#s(clientr.money))-strtofloat(#p(1)));
playerrupees+=strtofloat(#p(1));
triggeraction 0,0,clientside,Bank,done;
}
}
}
//#CLIENTSIDE
if (weaponfired) {
tokenize #c;
triggeraction 0,0,serverside,#t(0),#t(1);
}
if (actionclientside) {
if (strequals(#p(0),done)) {
showtext -1,playerx+1.5,playery-.5,,Arial,bc,Done!;
changeimgzoom -1,0.7;
}
}



dunno if that works, just did it in the reply box
Reply With Quote
  #6  
Old 02-06-2004, 10:39 PM
WanDaMan WanDaMan is offline
Master Tux
WanDaMan's Avatar
Join Date: Aug 2002
Location: England, United Kingdom
Posts: 5,571
WanDaMan is a jewel in the roughWanDaMan is a jewel in the rough
Send a message via MSN to WanDaMan
Quote:
Originally posted by R0bin
The actionclientside action only works for weapon npcs.
Ah, thanks. I wasn't aware of that
__________________
V$:CONFL16T
Reply With Quote
  #7  
Old 02-08-2004, 07:18 PM
TB3 TB3 is offline
Registered User
TB3's Avatar
Join Date: May 2001
Location: US of A State of VA
Posts: 658
TB3 is on a distinguished road
Send a message via Yahoo to TB3
I'm not sure i havent used it yet so..
When you call actionclientside from a DB npc, it calls that action in all weapons right? Or can you only do it inside the serverside section of a weapon?
__________________

To the sun of your age, I arise
Reply With Quote
  #8  
Old 02-08-2004, 08:01 PM
ZeLpH_MyStiK ZeLpH_MyStiK is offline
Scripter
ZeLpH_MyStiK's Avatar
Join Date: May 2003
Location: NYC
Posts: 553
ZeLpH_MyStiK is on a distinguished road
Send a message via MSN to ZeLpH_MyStiK Send a message via Yahoo to ZeLpH_MyStiK
I do believe its weapons only...and it looks like this:
NPC Code:

if (actionserverside) {
//stuff
triggeraction 0,0,clientside,WEAPONNAME,params;
//stuff
}
//#CLIENTSIDE
//stuff
if (actionclientside) {
//stuff
}

__________________
Reply With Quote
  #9  
Old 02-08-2004, 08:16 PM
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
It works basically as serverside triggeractions, but sent to client. So trigger from serverside.
__________________
"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 02:56 PM.


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