Thread: need help with food sytem.

Results 1 to 2 of 2
  1. #1 need help with food sytem. 
    Registered Member copycopy's Avatar
    Join Date
    Aug 2006
    Posts
    185
    Thanks given
    17
    Thanks received
    3
    Rep Power
    14
    ok well im good with servers and coding, but i do not get this because the food. On my server well when i eat it it sais you ate a manta blah blah. so i couldnt find it in any my files till i got to postins.java so i tryed adding heal = 25; ect but it still donsn't heal can any one help? if needed i can send you some files.


    Code:
    case 391:
    				if (System.currentTimeMillis() - c.foodDelay < 2000)
    				return;
    				c.foodDelay = System.currentTimeMillis();
    				c.setAnimation(0x33D);
    				//c.playSound(317, 000, 020);
    				c.sM("You eat the manta ray.");
    				if(c.currentHealth < c.playerLevel[c.playerHitpoints]){
    				c.sM("It heals some health.");
    				}
    				c.deleteItem(391, slot, 1);
    				
    				c.currentHealth += 22;
    				if (c.currentHealth > c.playerLevel[c.playerHitpoints])
    					c.currentHealth = c.playerLevel[c.playerHitpoints];
    				c.sendQuest("" + c.currentHealth + "", 4016);
    				break;
    Quote Originally Posted by Liam View Post
    We have like 20 staff members, and lots of them are pretty worthless. what the **** is the point of a SB mod?
    agreed there... well kinda
    Reply With Quote  
     

  2. #2  
    Registered Member
    Vox''s Avatar
    Join Date
    Nov 2008
    Age
    31
    Posts
    3,113
    Thanks given
    49
    Thanks received
    181
    Rep Power
    731
    ok. so you have
    Code:
    case 391:
    				if (System.currentTimeMillis() - c.foodDelay < 2000)
    				return;
    				c.foodDelay = System.currentTimeMillis();
    				c.setAnimation(0x33D);
    				//c.playSound(317, 000, 020);
    				c.sM("You eat the manta ray.");
    				if(c.currentHealth < c.playerLevel[c.playerHitpoints]){
    				c.sM("It heals some health.");
    				}
    				c.deleteItem(391, slot, 1);
    				
    				c.currentHealth += 22;
    				if (c.currentHealth > c.playerLevel[c.playerHitpoints])
    					c.currentHealth = c.playerLevel[c.playerHitpoints];
    				c.sendQuest("" + c.currentHealth + "", 4016);
    				break;
    NOTE: i ripped it out of delta potions.java, so whatever. so if you want to change the amount of HP healed, you would change
    Code:
    				c.currentHealth += 22;
    change the 22 to any number you want to be healed. BUT you must change the case number to the food ID? got it?

    Quote Originally Posted by Zirtrix View Post
    So I've recently changed some things in the server, but when i compile it says
    Code:
    source\server\model\players\packets\Commands.java: 58: error: cannot find symbol
    This.Antileech("Remove This Line");
    ^
    Anyone know the problem?
    Student and Developer for http://www.rune-server.org/runescape...pve-based.html
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •