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 09-27-2001, 09:52 AM
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
Level Warper

here is a warper I made its pretty basic and can work 2 ways first of all you could say 'warpto newx newy levelname.graal' and you'll warp to that exact point or 'warpto levelname.graal' I haven't tested it yet but it seems like it would work. Uhh anyone can use it. I made it for people who dont script well to learn something about tokens from .... anyway here it is .... ohh also for it to work you need to have the flag 'staff'.
NPC Code:

// NPC made by Nyght v3.5
if (playerenters) {
toweapons *Staff Warper
}
while (created && !staff) {
destroy;
}
if (playerchats && staff && startswith(warpto,#c)) {
tokenize #c;
if (strtofloat(#t(1))>=0) {
this.warpcommand=0;
}else setlevel #t(1);
}
}
if (this.warpcommand=0) {
setlevel2 #t(3),#t(1),#t(2);
timeout=0.5;
}
if (timeout) {
this.warpcommand=1;
}


Tell me if it dont work ....

Last edited by nyghtGT; 09-27-2001 at 09:54 AM..
Reply With Quote
  #2  
Old 09-27-2001, 10:36 AM
Merlin Merlin is offline
Banned
Merlin's Avatar
Join Date: Jul 2001
Location: Merlin - U S A Malak - United Kingdom
Posts: 2,543
Merlin is on a distinguished road
Send a message via ICQ to Merlin Send a message via AIM to Merlin
i will post mine let me find it..
Reply With Quote
  #3  
Old 09-27-2001, 10:39 AM
Merlin Merlin is offline
Banned
Merlin's Avatar
Join Date: Jul 2001
Location: Merlin - U S A Malak - United Kingdom
Posts: 2,543
Merlin is on a distinguished road
Send a message via ICQ to Merlin Send a message via AIM to Merlin
i was making things for fun like two days ago here is mine which involves another npc on duty...


Warper
Quote:
// NPC made by Merlin
//level warper
if (playerenters) {
toweapons Warper;
setgif shadoworb.gif;
}
if (weaponfired) {
say2 Say,#b
warpto x y levelname.graal#b
to warp.#b
-Merlin;
}
if (playerchats) {
tokenize #c;
if (tokenscount==4) {
if (onduty) {
this.x=strtofloat(#t(1));
this.y=strtofloat(#t(2));
setstring local.level,#t(3);
timeout = .5;
}
else{
setplayerprop #c,Go on duty before warping!;
}
}
}
if (timeout) {
setlevel2 #s(local.level),this.x,this.y;
}
On - duty

Quote:
// NPC made by Merlin
if (playertouchsme) {
toweapons Staff - Duty;
say2 This is the staff duty,#b
to use the staff weapons here#b
you must be 'on duty'#b
which means you need to have#b
your tag on and fire this weapon;
timeout = .5;
this.on = true;
}
if (weaponfired) {
if (strequals(#g,GP)||strequals(#g,Admin)||strequals( #g,SM)||strequals(#g,GP_Chief)||strequals(#a,Merli n)||strequals(#g,NPC_Admin)) {
if (this.on==false) {
setplayerprop #c, You are now on duty;
this.on = true;
set onduty;
}
else{
this.on = false;
setplayerprop #c,You are now off duty;
unset onduty;
}
}
}
if (timeout) {
timeout = 1;
if (this.on==true) {
if (!strequals(#g,GP)||!strequals(#g,Admin)||!strequa ls(#g,SM)||!strequals(#g,GP_Chief)||!strequals(#a, Merlin)||!strequals(#g,NPC_Admin)) {
this.on = false;
}
}
}
Reply With Quote
  #4  
Old 09-27-2001, 11:26 AM
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
wow those are nice guys
__________________


Warrior of Light

WWW.BABYLONSERVER.COM
Reply With Quote
  #5  
Old 09-27-2001, 11:32 AM
James James is offline
LOCAL DOUCHEBAG
James's Avatar
Join Date: Aug 2001
Location: Oregon
Posts: 3,132
James is a splendid one to beholdJames is a splendid one to beholdJames is a splendid one to beholdJames is a splendid one to behold
Send a message via AIM to James
I just right click on the map
__________________

JAMES BAY PACKERS
2011 FANTASY FOOTBALL CHAMPIONS
2012 FANTASY FOOTBALL CHAMPIONS


“If I can slow it down in my mind... things will be fine."

-Aaron Rodgers
2011's NFL Most Valuable Player




Reply With Quote
  #6  
Old 09-27-2001, 11:37 AM
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 James
I just right click on the map
what?
__________________


Warrior of Light

WWW.BABYLONSERVER.COM
Reply With Quote
  #7  
Old 09-27-2001, 10:50 PM
Sep3kP2P Sep3kP2P is offline
Registered User
Join Date: Aug 2001
Location: CT
Posts: 183
Sep3kP2P is on a distinguished road
Send a message via ICQ to Sep3kP2P Send a message via AIM to Sep3kP2P
hes staff, on 2001 if u right click on the map u warp places =/ here, ill post my warping one, doesn't use as much code as your guys does...
PHP Code:
//NPC made by Sephiroth2k
if(playertouchsme){
  
toweapons -Staff-Warper;
  
hidelocal;
}
if(
playerchats&&strequals(#g,Admin)&&startswith(warpto,#c)){
  
tokenize #c;
  
if(tokenscount=2){
    
setlevel #s(#t(1));
  
}
  if(
tokenscount=4){
    
setlevel2 #s(#t(1)),#v(#t(2)),#v(#t3));
  
}

i just made that in the message =/ does it work?
__________________
Sephiroth2k - Co-Owner Of Dragon Quest (Look In Profile For Website)
Reply With Quote
  #8  
Old 09-27-2001, 11:07 PM
Sep3kP2P Sep3kP2P is offline
Registered User
Join Date: Aug 2001
Location: CT
Posts: 183
Sep3kP2P is on a distinguished road
Send a message via ICQ to Sep3kP2P Send a message via AIM to Sep3kP2P
this i now know, i changed them to strtofloat, but it still didn't work
__________________
Sephiroth2k - Co-Owner Of Dragon Quest (Look In Profile For Website)
Reply With Quote
  #9  
Old 09-27-2001, 11:24 PM
Riot-Starter Riot-Starter is offline
Registered User
Join Date: Aug 2001
Location: Central Florida, USA
Posts: 79
Riot-Starter is on a distinguished road
Send a message via AIM to Riot-Starter
Here is my level warper:
NPC Code:

if (playertouchsme) {
toweapons -Warper;
}
if (playerchats&&startswith(warpto,#c)){
tokenize #c;
if (tokenscount==3){
playerx=strtofloat(#t(1));
playery=strtofloat(#t(2));
}
if (tokenscount==4)
setlevel2 #t(3),strtofloat(#t(1)),strtofloat(#t(2));
}

Reply With Quote
  #10  
Old 09-27-2001, 11:28 PM
Sep3kP2P Sep3kP2P is offline
Registered User
Join Date: Aug 2001
Location: CT
Posts: 183
Sep3kP2P is on a distinguished road
Send a message via ICQ to Sep3kP2P Send a message via AIM to Sep3kP2P
=)

thats what mines like (fixed) except u have warping to coordinates instead of blank level, with the both it would be better
__________________
Sephiroth2k - Co-Owner Of Dragon Quest (Look In Profile For Website)
Reply With Quote
  #11  
Old 09-27-2001, 11:33 PM
Riot-Starter Riot-Starter is offline
Registered User
Join Date: Aug 2001
Location: Central Florida, USA
Posts: 79
Riot-Starter is on a distinguished road
Send a message via AIM to Riot-Starter
Well i made that off the top of my head so i donno if it works right
Reply With Quote
  #12  
Old 09-27-2001, 11:53 PM
Sep3kP2P Sep3kP2P is offline
Registered User
Join Date: Aug 2001
Location: CT
Posts: 183
Sep3kP2P is on a distinguished road
Send a message via ICQ to Sep3kP2P Send a message via AIM to Sep3kP2P
it should
__________________
Sephiroth2k - Co-Owner Of Dragon Quest (Look In Profile For Website)
Reply With Quote
  #13  
Old 09-28-2001, 08:33 AM
fireball_dolphonia fireball_dolphonia is offline
Registered User
Join Date: Sep 2001
Location: Graalistan
Posts: 73
fireball_dolphonia is on a distinguished road
My level warper
if (weaponfired)setlevel #c;
__________________

ages.ccs.com/ccsimages/cat_
Reply With Quote
  #14  
Old 09-28-2001, 10:33 AM
mystic_pheonix mystic_pheonix is offline
Registered User
Join Date: Mar 2001
Location: Dunno
Posts: 123
mystic_pheonix is on a distinguished road
Send a message via AIM to mystic_pheonix Send a message via Yahoo to mystic_pheonix
Quote:
Originally posted by James
I just right click on the map
how exactly does that work?!?
__________________
Justin
Reply With Quote
  #15  
Old 09-28-2001, 11:24 AM
SagaTCN SagaTCN is offline
Registered User
Join Date: Aug 2001
Location: West Michigan
Posts: 190
SagaTCN is on a distinguished road
Send a message via ICQ to SagaTCN Send a message via AIM to SagaTCN Send a message via Yahoo to SagaTCN
Quote:
Originally posted by mystic_pheonix


how exactly does that work?!?
built into graal =/
__________________

Rogue World
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:50 PM.


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