Thread: Fishing?
View Single Post
  #23  
Old 03-30-2002, 05:06 AM
happyme happyme is offline
Registered User
Join Date: Mar 2002
Location: Toronto, Ontario, Canada
Posts: 142
happyme is on a distinguished road
Send a message via AIM to happyme
Quote:
Originally posted by neomaximus2k
ok well first of all, looked like you leeched the script from somewhere

and this script works but you got to figure out the rest yourself
NPC Code:

// Fishing Rod made by dfex
if(created) { Rodstock=30; }
if (playerenters) {message (#v(Rodstock) In Stock); }
if (playerchats && strequals(#c,buy fishing rod) && playerrupees<100) {say2 Not Enough Money.; }
if (playerchats && strequals(#c,buy fishing rod)) {
if (Rodstock==0) { say2 No Rods In Stock.; } }
if (playerchats && strequals(#c,buy fishing rod) && !hasweapon(Fishing Rod)) {
if (playerrupees>=100 && Rodstock>0) {setplayerprop #c,*Bought Fishing Rod*;
toweapons Fishing Rod; Rodstock=Rodstock-1; playerrupees=playerrupees-100;
message (#v(Rodstock) In Stock); } }
if (weaponfired && hasweapon(Fishing Rod) && onwater(playerx+10,playery)){
playersprite=33; this.x=playerx; this.y=playery; if (playerdir=0) { this.x+=1; this.y-=1.4; }
if (playerdir=1) { this.x+=0; }
if (playerdir=2) { this.x+=.7; this.y+=1.2 }
if (playerdir=3) { this.x+=2; }
showimg 100,od-fishingrod.gif,this.x,this.y;
changeimgpart 100,playerdir*20,0,20,35;
freezeplayer 1; fishweight = int(random(1,5)); fishcatch = int(random(1,10));
if(fishcatch<=7) { } else {
fishedweight = strtofloat(#s(fishedweight))+fishweight;
if (fishedweight>100) fishedweight = 150; setstring fishedweight,#v(fishedweight);
setstring fishedsize,#v(strtofloat(#s(fishedsize))+this.size );
setstring client.fishedweight,#s(fishedweight); say2 You got a #v(fishweight) pounder!;
setstring this.fisher,#a; }}
if (weaponfired && !onwater(players[0].x,players[0].y)){setplayerprop #c,I cant fish here; }

now it doesnt show img x.x
sorry for making the margins go over
__________________
Reply With Quote