Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Police Script (https://forums.graalonline.com/forums/showthread.php?t=12082)

ArmadeusWarlock 09-17-2001 12:02 AM

Police Script
 
Something is wrong, its all screwed up and wont set the server string, it wont even respond to me. And yes, this does work offline, [edit]with[/edit] the account stuff and everything, because it would work earlier but now it wont. HELP!

Quote:

// Graal2001 NPC by Stefan Knorr
if (created) {
// Initialize the attributes
showcharacter;
setcharprop #3,head1.gif;
setcharprop #C0,orange;
setcharprop #C1,red;
setcharprop #C2,darkred;
setcharprop #C3,red;
setcharprop #C4,pink;
setcharprop #n,Police (Test);
setcharprop #2,noshield.gif;
shieldpower = 1;
dir = 2;
this.jailing=0;
}

if(#a=Reese_2001||#a=ArmadeusWarlock||#g=GP&&this. jailing=0){
if(strequals(#c,reset)){
this.jailing=0;
}
if(strequals(#c,Jail Player)){
message Account Name?;
setplayerprop #c,;
this.jailing=1;
}
if(this.jailing=1&&playerchats&&!strequals(#c,jail player)){
setstring server.mostwanted,#c;
sleep 0.01;
message The player has been jailed/will be jailed when he returns online!;
this.jailing=0;
}
}

this doesnt jail the people, but i know how to do that with this script, so pleas,e tell me why it wont set the strings?

ArmadeusWarlock 09-17-2001 12:13 AM

...
 
Can you please at least tell me where I screwed up?

ArmadeusWarlock 09-17-2001 12:22 AM

hmmm...
 
I think I know what you mean. Ill go try it real quick.

ArmadeusWarlock 09-17-2001 12:25 AM

lol. Whoops, I know what you mean. I forgot about strequals at that time -_-.
Thanks

ArmadeusWarlock 09-17-2001 12:26 AM

Still doesnt fix problem. Right when i say Jail Player, it says "the player has been jailed" and all that.

ArmadeusWarlock 09-17-2001 12:29 AM

And the server.string still isnt being set :mad:


sorry for :spam: ing and not just editting one post instead of making 500 new ones each time i discover a problem

ArmadeusWarlock 09-17-2001 12:42 AM

ok
 
:D :D :D

I finally figured it out, I rewrote the whole script so it works plenty good now. Thx for your help.

LordMatt 09-17-2001 12:45 AM

Re: ok
 
Quote:

Originally posted by ArmadeusWarlock
:D :D :D

I finally figured it out, I rewrote the whole script so it works plenty good now. Thx for your help.

could you send it to me in fourm pm?

ArmadeusWarlock 09-17-2001 12:47 AM

...
 
lol.

no
i wont
if you want it, script one oyurself, its really not all that hard, i was just half awake (didnt get home early last night)

nyghtGT 09-20-2001 09:54 AM

try this ...
 
you could do ... this is very simple and easy ...

for you player system or NPC server put:

if (strcontains(#a,#s,server.jailaccount) && !strequals(#L,jailceel.graal)) {set jailed;setlevel2 32,32,jailcell.graal;}

On the NPC itself put

if (weaponfired) {
setstring server.jailaccount,#c;
}

So the Gp says the account name ... fires the weapon and the person will be sent to jail ... (i think)
i am half asleep so its probably wrong

ArmadeusWarlock 09-20-2001 10:07 AM

ummmm
 
That would work, especially if they are far from a police dude. I was wondering how I could do that, and thats not a bad idea.

My System NPC is gonna b huge by the time i get done =(

nyghtGT 09-21-2001 07:12 AM

contact
 
contact me on aim and i will explain it further if you want ...


All times are GMT +2. The time now is 10:12 PM.

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