Thread: New slayer task going into Negitive (Fixed)

Results 1 to 3 of 3
  1. #1 New slayer task going into Negitive (Fixed) 
    Registered Member BakonBitz's Avatar
    Join Date
    Dec 2015
    Posts
    122
    Thanks given
    21
    Thanks received
    7
    Rep Power
    16
    i added new slayer monster for task after it reachs 0 it goes -1 -2 -3 -4 ETC

    Can anyone give me a hand? im just getting back into programming and its confusing as fuck atm

    My Skype: BakonBitz502 if needed

    Also im not entirely sure with source im using and idk if its 317. DEF not PI


    Edit: Fixxed. I messed up on the slayer countdown. and when i fixed it the tasks were allready in negative
    Reply With Quote  
     

  2. #2  
    Registered Member LuckyLad's Avatar
    Join Date
    Jul 2016
    Age
    25
    Posts
    44
    Thanks given
    0
    Thanks received
    14
    Rep Power
    11
    Code:
    			if (amount == 0) {
    
    				task = null;
    				addSlayerExperience(def.getLevel() * 35);
    				p.getClient().queueOutgoingPacket(new SendMessage("<col=075D78>You have completed your Slayer task; return to Vannaka for another."));
    				p.addSlayerPoints(amount);
    				AchievementHandler.activateAchievement(p, AchievementList.COMPLETE_10_SLAYER_TASKS, 1);
    				AchievementHandler.activateAchievement(p, AchievementList.COMPLETE_100_SLAYER_TASKS, 1);
    				if (current != null) {
    					p.addSlayerPoints(current == SlayerDifficulty.BOSS ? 20 + 0 : current == SlayerDifficulty.LOW ? 5 + 0 : current == SlayerDifficulty.MEDIUM ? 8 + 0 : current == SlayerDifficulty.HIGH ? 10 + 0 : 0);
    				}
    
    			} else {
    			}
    Add something like that to your checkSlayer method in Slayer.java.
    Reply With Quote  
     

  3. #3  
    Registered Member BakonBitz's Avatar
    Join Date
    Dec 2015
    Posts
    122
    Thanks given
    21
    Thanks received
    7
    Rep Power
    16
    Quote Originally Posted by LuckyLad View Post
    Code:
    			if (amount == 0) {
    
    				task = null;
    				addSlayerExperience(def.getLevel() * 35);
    				p.getClient().queueOutgoingPacket(new SendMessage("<col=075D78>You have completed your Slayer task; return to Vannaka for another."));
    				p.addSlayerPoints(amount);
    				AchievementHandler.activateAchievement(p, AchievementList.COMPLETE_10_SLAYER_TASKS, 1);
    				AchievementHandler.activateAchievement(p, AchievementList.COMPLETE_100_SLAYER_TASKS, 1);
    				if (current != null) {
    					p.addSlayerPoints(current == SlayerDifficulty.BOSS ? 20 + 0 : current == SlayerDifficulty.LOW ? 5 + 0 : current == SlayerDifficulty.MEDIUM ? 8 + 0 : current == SlayerDifficulty.HIGH ? 10 + 0 : 0);
    				}
    
    			} else {
    			}
    Add something like that to your checkSlayer method in Slayer.java.

    Thats excatly the same code as mine but with the new task i added i never touched it, only thng i touched was adding the NPCS to Slayertasks and Slayer monsters...
    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

Similar Threads

  1. Slayer task going into negative?
    By BakonBitz in forum Help
    Replies: 0
    Last Post: 07-07-2016, 04:07 AM
  2. adding elite slayer tasks into a 667
    By pyroteddie1 in forum Help
    Replies: 0
    Last Post: 10-18-2014, 10:33 AM
  3. [PI] Adding New Slayer Tasks
    By savior I in forum Help
    Replies: 2
    Last Post: 05-15-2013, 11:45 PM
  4. Replies: 9
    Last Post: 01-23-2010, 07:56 AM
  5. Replies: 10
    Last Post: 08-31-2007, 10:41 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •