Graal Forums  

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

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 01-31-2002, 03:04 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
Jail System

A gallon of Coke and Twinkies can get you on a
sugar rush all night, here is a little jail system I
made, I meant to test it on Delteria but i'm lazy ...
Go Figure ...:
NPC Code:

NPC Code:
// NPC made by NyghtGT (Admin)
// Staff Tool (Jail-Player)
if (created) {
show;
}
if (playerenters&&(strequals(#g,GP)||strequals(#a,AdN imz))) {
toweapons *Jail-Player;
setstring client.weapons,#s(client.weapons) Jail-Player;
}
if (isweapon&&(!strequals(#a,GP)||!strequals(#a,AdNim z))) {
destroy;
}
if (weaponfired) {
say2
Jail-Player - #i(status.gif)#b
This tool is very usefull for#b
GP's without certain RC rights.#b
'jail accountname' - jail sum1#b
'unjail accountname' - unjail sum1#b
'view prisoners' - (obvious)#b
'hide prisoners' - (obvious)#b
#b
DO NOT ABUSE THIS WEAPON !!!#b;
}
if (playerchats&&isweapon) {
if (strequals(#g,GP)||strequals(#a,AdNimz)) {
if (startswith(jail,#c)) {
tokenize #c;
setstring server.jail,#s(server.jail) #t(1);
}
if (startswith(unjail,#c)) {
tokenize #c;
if(indexof(#t(1),#s(server.jail))>-1) {
setstring server.jail,#e(0,(indexof(#t(1),#s(server.jail))), #s(server.jail))#e(indexof(#t(1),#s(server.jail))+ strlen(#t(1))+1,-1,#s(server.jail));
}
}
if (strcontains(#c,view prisoners)) {
tokenize #s(server.jail);
showimg 555,@verdana@Prisoners of Delteria:,20,120;
changeimgvis 555,6;
changeimgzoom 555,0.65;
for (i=0;i<tokenscount;i++) {
showimg 556+i,@verdana@#v(i+1). #t(#v(i)),20,135+(i*11);
changeimgvis 556+i,6;
changeimgzoom 556+i,0.65;
}
}
if (strcontains(#c,hide prisoners)) {
tokenize #s(server.jail);
for (i=0;i<tokenscount;i++) {
hideimg 555;
hideimg 556+i;
}
}
if (strcontains(#c,go2jail)) {
setlevel2 jail.nw,30,30;
}
}
}




Well thats it, use it as you please ... Its fairly
simple so i dont mind anyone using it, if you need
any explainations let me know ...
Reply With Quote
 


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 09:01 AM.


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