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-10-2002, 03:16 PM
ownerofbabylon ownerofbabylon is offline
Lord Helmut
ownerofbabylon's Avatar
Join Date: Jun 2001
Location: Gainesville FL
Posts: 1,763
ownerofbabylon is on a distinguished road
Send a message via ICQ to ownerofbabylon Send a message via AIM to ownerofbabylon
Proper Keydown?

How is the best way to keep testing for a player to touch a NPC and hit A?

if(playertouchsme&&keydown(5)){
message hi;
}

makes it so u have to hold A and run at the NPC. Im just trying to figure out some way so a player can already be touching a NPC and hit a and it works.

Loriel did it on his mini game on londeroth but I really have no clue how. Any ideas?
__________________


Warrior of Light

WWW.BABYLONSERVER.COM
Reply With Quote
  #2  
Old 02-10-2002, 03:17 PM
joseyisleet joseyisleet is offline
Registered User
Join Date: Aug 2001
Posts: 378
joseyisleet is on a distinguished road
-=Josey=-
I'd use something like:
if (created){
timeout=.05;
}
if (timeout){
if (playertouchsme&&keydown(0)){
message o.0;
}
timeout=.05;
}
__________________
Account used by Josey and Howard.
Ali G: 'Is it cause i Black?'
Reply With Quote
  #3  
Old 02-10-2002, 03:20 PM
Faheria_GP2 Faheria_GP2 is offline
Banned
Faheria_GP2's Avatar
Join Date: Oct 2001
Posts: 1,177
Faheria_GP2 is on a distinguished road
events dont work well within events

yes, if (playertouchsme && keydown(5)) would be a good way to do it
Reply With Quote
  #4  
Old 02-10-2002, 03:50 PM
ownerofbabylon ownerofbabylon is offline
Lord Helmut
ownerofbabylon's Avatar
Join Date: Jun 2001
Location: Gainesville FL
Posts: 1,763
ownerofbabylon is on a distinguished road
Send a message via ICQ to ownerofbabylon Send a message via AIM to ownerofbabylon
Quote:
Originally posted by Faheria_GP2
events dont work well within events

yes, if (playertouchsme && keydown(5)) would be a good way to do it
then u have to hold a and run at it.

Kai, i didnt ever understand the way you explained =/ sorry
__________________


Warrior of Light

WWW.BABYLONSERVER.COM
Reply With Quote
  #5  
Old 02-10-2002, 04:00 PM
nyghtGT nyghtGT is offline
Banned
nyghtGT's Avatar
Join Date: Jun 2001
Posts: 3,993
nyghtGT is on a distinguished road
Send a message via AIM to nyghtGT
Quote:
Originally posted by ownerofbabylon


then u have to hold a and run at it.

Kai, i didnt ever understand the way you explained =/ sorry
like maybe you could draw a litte box around the NPC itself, then have it so:
NPC Code:

NPC Code:

if (created) {
timeout=0.5;
}
if (timeout) {
if (playerx in {#,#} && playery in {#,#,#} && keydown(6)) {
message li3k, omG! k?;
} else {
message li3k !omG, k?;
timeout=0.5;
}
}




i have no honest idea if that would work but give it a shot ...
Reply With Quote
  #6  
Old 02-10-2002, 06:23 PM
TDO2000 TDO2000 is offline
Registered User
TDO2000's Avatar
Join Date: Jul 2001
Location: Germany
Posts: 655
TDO2000 is on a distinguished road
um as Londeroth Admin I can tell u that this is not something like this... we use a script in our system NPC that triggers in front of the player when u press a so this Minigame NPC just gets a triggeraction...
__________________
No Webhost at the moment
Reply With Quote
  #7  
Old 02-10-2002, 09:18 PM
TDK_RC6 TDK_RC6 is offline
Registered User
TDK_RC6's Avatar
Join Date: Jan 2002
Location: Earth
Posts: 0
TDK_RC6 is on a distinguished road
Quote:
Originally posted by Kaimetsu
We've discussed this before :-/
lol
__________________
Staff on Renegade


email: [email protected]
aim: papivicente
Reply With Quote
  #8  
Old 02-10-2002, 09:57 PM
lordhelmut lordhelmut is offline
Registered User
lordhelmut's Avatar
Join Date: Aug 2001
Posts: 710
lordhelmut is on a distinguished road
Send a message via ICQ to lordhelmut Send a message via AIM to lordhelmut Send a message via Yahoo to lordhelmut
Quote:
Originally posted by TDO2000
um as Londeroth Admin I can tell u that this is not something like this... we use a script in our system NPC that triggers in front of the player when u press a so this Minigame NPC just gets a triggeraction...
I was told Trigger Action isnt allowed on free servers =(
__________________

Check out the development at:
http://razza.org/lordhelmut/FantasyTales/index
Reply With Quote
  #9  
Old 02-10-2002, 10:02 PM
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
Quote:
Originally posted by lordhelmut


I was told Trigger Action isnt allowed on free servers =(
That's bull****, it is allowed.

Last edited by Kaimetsu; 02-10-2002 at 10:36 PM..
Reply With Quote
  #10  
Old 02-10-2002, 11:16 PM
Androk2k1 Androk2k1 is offline
Banned
Androk2k1's Avatar
Join Date: Dec 2001
Posts: 1,336
Androk2k1 is on a distinguished road
is trigger action allowed? I thought it wasn't...
Reply With Quote
  #11  
Old 02-11-2002, 04:50 AM
lordhelmut lordhelmut is offline
Registered User
lordhelmut's Avatar
Join Date: Aug 2001
Posts: 710
lordhelmut is on a distinguished road
Send a message via ICQ to lordhelmut Send a message via AIM to lordhelmut Send a message via Yahoo to lordhelmut
Androk is the one who said it wasnt, he had me worried.
__________________

Check out the development at:
http://razza.org/lordhelmut/FantasyTales/index
Reply With Quote
  #12  
Old 02-11-2002, 06:31 AM
TDK_RC6 TDK_RC6 is offline
Registered User
TDK_RC6's Avatar
Join Date: Jan 2002
Location: Earth
Posts: 0
TDK_RC6 is on a distinguished road
Quote:
Originally posted by Androk2k1
is trigger action allowed? I thought it wasn't...
i do believe it is
__________________
Staff on Renegade


email: [email protected]
aim: papivicente
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 11:55 AM.


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