Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 02-24-2006, 07:22 PM
Prozac Prozac is offline
one of the good guys
Prozac's Avatar
Join Date: Jan 2006
Posts: 245
Prozac is on a distinguished road
Send a message via AIM to Prozac
disabling s and d keys

on the wiki page

http://wiki.graal.net/index.php/Crea.../Script/Client

under enablefeatures() it lists a bunch of stuff that can be enabled/disabled.
but what i do not see listed is how to disable the S key from using the sword and the D key from calling the selected weapon. how do i do that without using disabledefmovement?
Reply With Quote
  #2  
Old 02-24-2006, 09:17 PM
jake13jake jake13jake is offline
Former Classic Staff
jake13jake's Avatar
Join Date: Dec 2002
Location: Northwest Vermont
Posts: 1,452
jake13jake will become famous soon enough
Quote:
Originally Posted by Prozac
on the wiki page

http://wiki.graal.net/index.php/Crea.../Script/Client

under enablefeatures() it lists a bunch of stuff that can be enabled/disabled.
but what i do not see listed is how to disable the S key from using the sword and the D key from calling the selected weapon. how do i do that without using disabledefmovement?
disableweapons(); might be a good start. From there you'd have to rescript weapons calling and the sword. I think it's actually the sword animation that the default hit detection system uses. I'm thinking, hooray, I don't have to worry about this kind of stuff because I've pretty much rescripted the entire system for Classic (well, Storm did, I just went off and completely made my own that works a lot better, I really want to be able to implement it soon).
Reply With Quote
  #3  
Old 02-24-2006, 09:40 PM
Prozac Prozac is offline
one of the good guys
Prozac's Avatar
Join Date: Jan 2006
Posts: 245
Prozac is on a distinguished road
Send a message via AIM to Prozac
disableweapons - ah yes of course ... but then is it possible to have a nopk with, say, an array of levels that you can't pk in, in a server array, and a playerenters system npc that checks if your current level is in that array before calling the weapon action?
Reply With Quote
  #4  
Old 02-25-2006, 02:15 AM
jake13jake jake13jake is offline
Former Classic Staff
jake13jake's Avatar
Join Date: Dec 2002
Location: Northwest Vermont
Posts: 1,452
jake13jake will become famous soon enough
Quote:
Originally Posted by Prozac
disableweapons - ah yes of course ... but then is it possible to have a nopk with, say, an array of levels that you can't pk in, in a server array, and a playerenters system npc that checks if your current level is in that array before calling the weapon action?
I'd just rewrite the entire weapon handling system :P. It's not very hard at all.
PHP Code:
disableweapons();
if (!(
player.level in serverr.nopklevels))
  
weapon.trigger("wasfired",null); 
Reply With Quote
  #5  
Old 02-25-2006, 06:56 PM
Ajira Ajira is offline
Poont.
Join Date: Oct 2004
Location: NY, USA
Posts: 477
Ajira is on a distinguished road
Quote:
Originally Posted by jake13jake
I'd just rewrite the entire weapon handling system :P. It's not very hard at all.
PHP Code:
disableweapons();
if (!(
player.level in serverr.nopklevels))
  
weapon.trigger("wasfired",null); 
Why not just trigger a 'weaponfired' for compatibility with onWeaponFired()..
__________________
Liek omigosh.

Reply With Quote
  #6  
Old 02-25-2006, 07:03 PM
jake13jake jake13jake is offline
Former Classic Staff
jake13jake's Avatar
Join Date: Dec 2002
Location: Northwest Vermont
Posts: 1,452
jake13jake will become famous soon enough
Quote:
Originally Posted by Ajira
Why not just trigger a 'weaponfired' for compatibility with onWeaponFired()..
Shoot me, that's what I meant to say.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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:32 PM.


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