Graal Forums  

Go Back   Graal Forums > Development Forums > Future Improvements
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #41  
Old 05-17-2002, 01:25 AM
Kaimetsu Kaimetsu is offline
Script Monkey
Kaimetsu's Avatar
Join Date: May 2001
Posts: 18,222
Kaimetsu will become famous soon enough
Quote:
Originally posted by Neonight

Jeff sayeth:

Kai, only the complicated NPCs take a few minutes. Many of the Classic NPCs, from my understanding and experience, are actually rather simple. Most of them could be rewritten if they couldn't be converted...in fact, the longest step would be changing lots of graphics to either setshape or a gani.

Okay, but you did that script wrong. I'll give ya the fixed version, which looks a little more complicated.

NPC Code:

if(actionserverside){
if(playerdarts>0){
playerdarts--;
tempx=playerx; tempy=playery; temp=playerid;
for(this.i=0;this.i<playerscount;this.i++){
with(players[this.i]){
if(playerid!=temp){
if(((playerx-tempx)^2)+((playery-tempy)^2)<100){
hitplayer this.i,playerswordpower,playerx,playery;
//I'm not even sure about this part. I don't think hitplayer works serverside, but hurt wouldn't allow specific hurtdx/dys
}
}
}
}
}
}
//#CLIENTSIDE
if(weaponfired&&playerdarts>0){
triggeraction 0,0,serverside,#w,;
}

__________________
Reply With Quote
  #42  
Old 05-17-2002, 06:17 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

Jeff:

For scripts like that on Providence we use actionhit or actionattack or somesuch; HP or Control-NPC triggering or whatever is done by the victim's system NPC. Using some quick checks with <, <, and =, you could even theoretically determine which way the victim should fly (with onwall of course).
Reply With Quote
  #43  
Old 05-17-2002, 03:01 PM
Kaimetsu Kaimetsu is offline
Script Monkey
Kaimetsu's Avatar
Join Date: May 2001
Posts: 18,222
Kaimetsu will become famous soon enough
Quote:
Originally posted by Neonight

Jeff:

For scripts like that on Providence we use actionhit or actionattack or somesuch; HP or Control-NPC triggering or whatever is done by the victim's system NPC. Using some quick checks with <, <, and =, you could even theoretically determine which way the victim should fly (with onwall of course).
Indeed, however I did not want to define a whole new system just for the sake of this example.
__________________
Reply With Quote
  #44  
Old 05-18-2002, 12:00 AM
Tyhm Tyhm is offline
Psionic Youth
Tyhm's Avatar
Join Date: Mar 2001
Location: Babord, West Graal Deaths:1009 Kills:1
Posts: 5,635
Tyhm has a spectacular aura about
Bleah. If NPCServ doesn't even have hitplayer, may as well keep Classic as vulnerable as it is and keep pushing for setshootnpc and setshootdamage.
__________________
"Whatever," said Bean, "I was just glad to get out of the toilet."

"Power does not corrupt. Fear corrupts, perhaps the fear of a loss of power."- John Steinbeck
"I'm only acting retarded, what's your excuse?" queried the Gord.
- My pet, the Levelup Gnome

http://forums.graalonline.com/forums...&postcount=233
Reply With Quote
  #45  
Old 05-18-2002, 12:08 AM
Kaimetsu Kaimetsu is offline
Script Monkey
Kaimetsu's Avatar
Join Date: May 2001
Posts: 18,222
Kaimetsu will become famous soon enough
Quote:
Originally posted by Tyhm
Bleah. If NPCServ doesn't even have hitplayer, may as well keep Classic as vulnerable as it is and keep pushing for setshootnpc and setshootdamage.
It doesn't need hitplayer. There are equivalents, but I don't know them at this time. Perhaps:

hurt 10;
hurtdx=4;
hurtdy=1;

would be sufficient. I just don't know.
__________________
Reply With Quote
  #46  
Old 05-18-2002, 12:22 AM
Tyhm Tyhm is offline
Psionic Youth
Tyhm's Avatar
Join Date: Mar 2001
Location: Babord, West Graal Deaths:1009 Kills:1
Posts: 5,635
Tyhm has a spectacular aura about
Yeah, or hurtdx=playerx-paramx; hurtdy=playery-paramy; hurt paramdmg;
__________________
"Whatever," said Bean, "I was just glad to get out of the toilet."

"Power does not corrupt. Fear corrupts, perhaps the fear of a loss of power."- John Steinbeck
"I'm only acting retarded, what's your excuse?" queried the Gord.
- My pet, the Levelup Gnome

http://forums.graalonline.com/forums...&postcount=233
Reply With Quote
  #47  
Old 05-18-2002, 12:35 AM
Kaimetsu Kaimetsu is offline
Script Monkey
Kaimetsu's Avatar
Join Date: May 2001
Posts: 18,222
Kaimetsu will become famous soon enough
Quote:
Originally posted by Tyhm
Yeah, or hurtdx=playerx-paramx; hurtdy=playery-paramy; hurt paramdmg;
Well, yeah.
__________________
Reply With Quote
  #48  
Old 05-18-2002, 04:27 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

Jeff:

Yes Tyhm, that should work.

I'd say an NPC server would actually save trouble in the future

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 07:36 PM.


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