Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Server (https://forums.graalonline.com/forums/forumdisplay.php?f=14)
-   -   putnpc (https://forums.graalonline.com/forums/showthread.php?t=6869)

Bravo_LAT-Admin 07-08-2001 05:41 AM

putnpc
 
i remeber seeing this post earlier but i can't find it. which putnpc command works with npcserver putnpc1 or putnpc2 and whats the format for putnpc2?

Er1c 07-08-2001 07:26 AM

putnpc2 x,y,{script}; is what works on the NPC server.

Bravo_LAT-Admin 07-08-2001 08:11 AM

ty : D

Knightoffrost 07-08-2001 11:37 AM

Hrm..

Bravo_LAT-Admin 07-09-2001 12:39 AM

?
 
whats hrm for 0.o

Bravo_LAT-Admin 07-09-2001 02:20 AM

??
 
anyone know why this script won't let me pick up the weapon?

if (playertouchsme) {toweapons noobmaker;}
if (weaponfired) {
setani backflip,;
putnpc2 playerx,playery,{
if (created) {
showcharacter;
setcharprop #3,head0.gif;
setcharprop #C0,orange;
setcharprop #C1,white;
setcharprop #C2,blue;
setcharprop #C3,red;
setcharprop #C4,black;
setcharprop #2,shield1.gif;
shieldpower = 1;
dir = 2;
canbecarried;
}
}
}

FxChiP 07-09-2001 02:43 AM

Re: ??
 
Quote:

Originally posted by Bravo_LAT-Admin
anyone know why this script won't let me pick up the weapon?

if (playertouchsme) {toweapons noobmaker;}
if (weaponfired) {
setani backflip,;
putnpc2 playerx,playery,{
if (created) {
showcharacter;
setcharprop #3,head0.gif;
setcharprop #C0,orange;
setcharprop #C1,white;
setcharprop #C2,blue;
setcharprop #C3,red;
setcharprop #C4,black;
setcharprop #2,shield1.gif;
shieldpower = 1;
dir = 2;
canbecarried;
}
}
}

If the image is 32x32, for example, you put this in before playertouchsme (because since the server doesn't load the gifs, you need to tell it the dimensions).

NPC Code:

if (created) {
setshape 1,32,32;
}



That way, the NPC Server knows the dimensions, and therefore knows where the player has to be in order to touch the NPC.

Bravo_LAT-Admin 07-09-2001 08:09 AM

hmm
 
well now i can pick it up : / but it won;t lay the noobie doll >.< can anyone eolsve this one?

Er1c 07-09-2001 08:20 AM

putnpc2 needs to be used serverside... you need to trigger a server action and in the control NPC put the putnpc2 part

NPC Code:
if (weaponfired) {
triggeraction 0,0,servernoob,;
}


NPC Code:
if (actionservernoob) <what you had>



its either actionservernoob or serveractionnoob, dont remember

Knightoffrost 07-09-2001 11:00 AM

Re: ?
 
Quote:

Originally posted by Bravo_LAT-Admin
whats hrm for 0.o
Its sorta a dumb question

Bravo_LAT-Admin 07-09-2001 09:11 PM

ok
 
ok ty..hmm and frost i havn't has too much experience scripting with p2p yet ;p so i'm gonna ask some dumb questions ;p

Bravo_LAT-Admin 07-09-2001 09:30 PM

: /
 
well its still acting the same as before..does the backflip but no noobie doll......

if (created){setshape 1,10,10;}
if (playertouchsme) {toweapons noobmaker; }
if (weaponfired) {triggeraction 0,0,servernoob,;}
if(actionservernoob) {
setani backflip,;
putnpc2 playerx,playery,{
if (created) {
showcharacter;
setcharprop #3,head0.gif;
setcharprop #C0,orange;
setcharprop #C1,white;
setcharprop #C2,blue;
setcharprop #C3,red;
setcharprop #C4,black;
setcharprop #2,shield1.gif;
shieldpower = 1;
dir = 2;
canbecarried;
}
}
}

Er1c 07-10-2001 12:51 AM

Quote:

Originally posted by Er1c
putnpc2 needs to be used serverside... you need to trigger a server action and in the control NPC put the putnpc2 part

NPC Code:
if (weaponfired) {
triggeraction 0,0,servernoob,;
}


NPC Code:
if (actionservernoob) <what you had>



its either actionservernoob or serveractionnoob, dont remember

Read it! you need to put the seccond part in the control-NPC

SaijinGohan 07-10-2001 07:11 PM

I so lost in all of this script. I feel a headache coming on.:(

SaijinGohan 07-10-2001 11:03 PM

Woe is me
 
Woe Woe is me. Heres my best script!! Its for a toilet!
if (created) {
drawunderplayer;
dontblock;
}
:D

SaijinGohan 07-10-2001 11:06 PM

1 Attachment(s)
No Actually this is my best script....

if (playerenters) show;
if (playertouchsme) {
toweapons Wood Bomb;
hide;
}
if (weaponfired && playerbombs>0) {
timeout=3;
if (playerdir=0) {
putnpc woodbomb.gif,woodbomb.txt,playerx+0.5,playery-1;
};
if (playerdir=1) {
putnpc woodbomb.gif,woodbomb.txt,playerx-1.5,playery+1;
};
if (playerdir=2) {
putnpc woodbomb.gif,woodbomb.txt,playerx+0.5,playery+2.5;
};
if (playerdir=3) {
putnpc woodbomb.gif,woodbomb.txt,playerx+2.5,playery+1;
};
playerbombs--;
}
if (timeout) {
for (i=0; i<playerscount; i++) {
if ((x-players[i].x)<=6 &&
(y-players[i].y)<=6 &&
(x-players[i].x)>=-6 &&
(y-players[i].y)>=-6) {
hitplayer i,1,x,y};
};
}


heres the text file for it....:D

Bravo_LAT-Admin 07-11-2001 12:12 AM

hmm
 
ok ty i ot it now thank you er1c. one more question si there ahyway to make the noobie dolls serverside becuase irght now it seems as if they are runnin clientside because when you pick it up others see a bush...and the noobie stays for them..


All times are GMT +2. The time now is 06:09 AM.

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