
05-14-2009, 03:38 PM
|
|
Psionic Youth
|
 |
Join Date: Mar 2001
Location: Babord, West Graal Deaths:1009 Kills:1
Posts: 5,635
|
|
|
Yeah, there would be a whole lot of "if(playerenters){ play stef1.mid; }". The biggest problem last time I took a wrench to it was, of all things, SIGNS. Still don't know why Stefan decided they all had to be serverside-only...
Somewhere I've probably still got that java app that'll do all the mass-replacing for you...just a question of putting the right tweaks on it...
And from recent experience, a big stumbling block is that Baddies are a pain in the butt...if I could get some official backing on making a public generic template Baddies script we could probably hammer out a damn good one and make Graal a better place server regardless, but meh.
Problems with baddies:
they're either mostly serverside or mostly clientside.
Clientside Baddies, you can get a real smooth movement with 0.05 timeouts and everything - but to everyone else, you're swinging at nothing, while on Their screen They're getting nommed by the baddie...there's no way to get everyone chipping away at the same baddie, teamwork is impossible.
Serverside Baddies, you can all chip away at the same health bar and you all see it in the same place, but you're counting on the server to calculate movement and all that...it's kind of a pain in the butt.
The zombies I was working on for Insomnia had a fun little hybrid; the Server handled the health, targetting and movement, but the clients handled animating the movement. I never ironed it all out, but the theory goes: Serverside the baddy patrols from here to here in this much time, so let's just jump this invisible NPC to the end and wait until that time. Clientside, the baddy reads in where it's supposed to be, and where it was last displayed, and when it's supposed to get there, and calculates its next position, then shows itself at that location (with some clevar showani code-fu). Then based on its virtual clientside location, it determines if that means it just got hit by the player, or if the player just got hit by it, and does the usual song and dance. Upshot: the server runs one pretty simple script every few seconds to maybe every half a second (when actively chasing a player), but every client sees perfectly smooth baddy movement and can interact with it pretty much laglessly.
Downside is, you can't use default arrows I don't think. Unless there's a way for a clientside script to read the arrows[i].x etc.... |
__________________
"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
|
Last edited by Tyhm; 05-14-2009 at 03:50 PM..
|
|
|