Thread: Ruse combat bug fixes

Page 1 of 2 12 LastLast
Results 1 to 10 of 13
  1. #1 Ruse combat bug fixes 
    Banned

    Join Date
    Jul 2015
    Posts
    607
    Thanks given
    520
    Thanks received
    660
    Rep Power
    0
    More people using ruse = more bugs being found, will update this thread with more fixes in the future so keep checking back on it

    Spoiler for Barrage-Gmaul-Abuse:
    Link:http://www.rune-server.org/runescape...age-abuse.html
    Fix:

    CombatSpecial, find:
    Code:
    if (spec == CombatSpecial.STAFF_OF_LIGHT && player.hasStaffOfLightEffect()) {
    				player.getPacketSender().sendMessage("You are already being protected by the Staff of Light!");
    				return;
    			}
    Replace with:
    Code:
    if(spec != CombatSpecial.STAFF_OF_LIGHT && player.isAutocast()) {
    				Autocasting.resetAutocast(player, true);
    			} else if (spec == CombatSpecial.STAFF_OF_LIGHT && player.hasStaffOfLightEffect()) {
    				player.getPacketSender().sendMessage("You are already being protected by the Staff of Light!");
    				return;
    			}
    Autocasting, replace the following method with mine:
    Code:
    public static void resetAutocast(Player p, boolean clientReset) {
    		if(clientReset)
    			p.getPacketSender().sendAutocastId(-1);
    		p.setAutocast(false);
    		p.setAutocastSpell(null);
    		p.setCastSpell(null);
    		p.getPacketSender().sendConfig(108, 3);
    	}


    Spoiler for NexBug:

    Link: http://www.rune-server.org/runescape...nex-abuse.html

    Fix:
    Find and replace the following in Nex.java (basically the phase == 1 if-statement)
    Code:
    if(phase == 1)
    		{
    			int rnd = Misc.getRandom(20);
    			if(rnd < 2 && !attacks[3])
    			{
    				NEX.forceChat("Fear the shadow!");
    				attacks[3] = true;
    				NEX.setChargingAttack(true);
    				for(final Player p_ : Misc.getCombinedPlayerList(p))
    				{
    					if(p_ == null || p_.getLocation() != Location.GODWARS_DUNGEON)
    						continue;
    					TaskManager.submit(new Task(1, NEX, false) {
    						int origX, origY;
    						int ticks;
    						@Override
    						public void execute()
    						{
    
    							if(ticks == 0)
    							{
    								origX = p_.getPosition().getX();
    								origY = p_.getPosition().getY();
    							}
    							if(ticks == 5)
    							{
    								if(origX == p_.getPosition().getX() && origY == p_.getPosition().getY())
    								{
    									p_.dealDamage(new Hit(100 + Misc.getRandom(100), Hitmask.RED, CombatIcon.NONE));
    									p_.getPacketSender().sendMessage("The shadows begin to damage you!");
    									this.stop();
    								}
    							}
    
    							if(ticks == 10) {
    								this.stop();
    							}
    
    							ticks++;
    						}
    
    						@Override
    						public void stop() {
    							setEventRunning(false);
    							attacks[3] = false;
    							NEX.setChargingAttack(false);
    						}
    					});
    				}
    			}else if(rnd >= 5 && rnd <= 7 && !attacks[4])
    			{
    				NEX.forceChat("Embrace darkness!");
    				attacks[4] = true;
    				NEX.setChargingAttack(true);
    				for(Player p_ : Misc.getCombinedPlayerList(p))
    				{
    					if(p_ == null || p_.getLocation() != Location.GODWARS_DUNGEON)
    						continue;
    					TaskManager.submit(new Task(1, NEX, false) {
    						int ticks = 0;
    						@Override
    						public void execute()
    						{
    							if(ticks == 10)
    								setShadow(p_, 250);
    							else {
    								double dist = p_.getPosition().distanceToPoint(NEX.getPosition().getX(), NEX.getPosition().getY());
    								if(dist < 3)
    								{
    									p_.getPacketSender().sendMessage("The shadows begin to consume you!");
    									p_.dealDamage(new Hit(10, Hitmask.RED, CombatIcon.NONE));
    									setShadow(p_, 20);
    								}
    								if(dist >= 3 && dist < 5)
    									setShadow(p_, 40);
    								if(dist > 5)
    									setShadow(p_, 90);
    							}
    							if(ticks >= 10)
    							{
    								this.stop();
    							}
    							ticks++;
    						}
    
    						@Override
    						public void stop() {
    							setEventRunning(false);
    							attacks[4] = false;
    							NEX.setChargingAttack(false);
    						}
    					});
    				}
    				NEX.performAnimation(new Animation(6984));
    				new CombatHitTask(NEX.getCombatBuilder(), new CombatContainer(NEX, p, 1, CombatType.MAGIC, true)).handleAttack();
    				return true;
    			} else {
    				if(p.getPosition().distanceToPoint(NEX.getPosition().getX(), NEX.getPosition().getY()) <= 2 && Misc.getRandom(1) == 0)
    				{
    					NEX.performAnimation(new Animation(6354));
    					TaskManager.submit(new Task(1, NEX, false) {
    						@Override
    						public void execute() {
    							new CombatHitTask(NEX.getCombatBuilder(), new CombatContainer(NEX, p, 1, CombatType.MELEE, true)).handleAttack();
    							stop();
    						}
    					});
    					return true;
    				} else {
    					NEX.performAnimation(new Animation(6326));
    					NEX.performGraphic(new Graphic(378));
    					new CombatHitTask(NEX.getCombatBuilder(), new CombatContainer(NEX, p, 1, CombatType.MAGIC, true)).handleAttack();
    					return true;
    				}
    			}
    		}
    Reply With Quote  
     

  2. #2  
    Registered Member
    Join Date
    Mar 2011
    Posts
    218
    Thanks given
    130
    Thanks received
    45
    Rep Power
    0
    Thanks for the bug fixes
    Reply With Quote  
     

  3. #3  
    Banned
    Join Date
    Dec 2015
    Posts
    176
    Thanks given
    31
    Thanks received
    22
    Rep Power
    0
    Dammit
    Reply With Quote  
     

  4. #4  
    Registered Member

    Join Date
    Jan 2011
    Age
    28
    Posts
    184
    Thanks given
    239
    Thanks received
    65
    Rep Power
    1712
    Not using ruse but maybe in the future , thanks for the fixes



    Reply With Quote  
     

  5. #5  
    love

    scoob's Avatar
    Join Date
    Oct 2015
    Age
    25
    Posts
    1,642
    Thanks given
    367
    Thanks received
    640
    Rep Power
    1559
    Ty for fixes, anyway anyhow, not gonna use ruse
    Attached image
    Reply With Quote  
     

  6. #6  
    Registered Member
    Join Date
    Apr 2014
    Posts
    232
    Thanks given
    34
    Thanks received
    49
    Rep Power
    14
    Thanks for this
    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Dec 2015
    Posts
    3
    Thanks given
    0
    Thanks received
    0
    Rep Power
    0
    looks decent ty for this
    Reply With Quote  
     

  8. #8  
    Registered Member NextGen's Avatar
    Join Date
    Oct 2015
    Posts
    112
    Thanks given
    8
    Thanks received
    5
    Rep Power
    10
    Quote Originally Posted by Swiffy View Post
    More people using ruse = more bugs being found, will update this thread with more fixes in the future so keep checking back on it

    Spoiler for Barrage-Gmaul-Abuse:
    Link:http://www.rune-server.org/runescape...age-abuse.html
    Fix:

    CombatSpecial, find:
    Code:
    if (spec == CombatSpecial.STAFF_OF_LIGHT && player.hasStaffOfLightEffect()) {
    				player.getPacketSender().sendMessage("You are already being protected by the Staff of Light!");
    				return;
    			}
    Replace with:
    Code:
    if(spec != CombatSpecial.STAFF_OF_LIGHT && player.isAutocast()) {
    				Autocasting.resetAutocast(player, true);
    			} else if (spec == CombatSpecial.STAFF_OF_LIGHT && player.hasStaffOfLightEffect()) {
    				player.getPacketSender().sendMessage("You are already being protected by the Staff of Light!");
    				return;
    			}
    Autocasting, replace the following method with mine:
    Code:
    public static void resetAutocast(Player p, boolean clientReset) {
    		if(clientReset)
    			p.getPacketSender().sendAutocastId(-1);
    		p.setAutocast(false);
    		p.setAutocastSpell(null);
    		p.setCastSpell(null);
    		p.getPacketSender().sendConfig(108, 3);
    	}


    Spoiler for NexBug:

    Link: http://www.rune-server.org/runescape...nex-abuse.html

    Fix:
    Find and replace the following in Nex.java (basically the phase == 1 if-statement)
    Code:
    if(phase == 1)
    		{
    			int rnd = Misc.getRandom(20);
    			if(rnd < 2 && !attacks[3])
    			{
    				NEX.forceChat("Fear the shadow!");
    				attacks[3] = true;
    				NEX.setChargingAttack(true);
    				for(final Player p_ : Misc.getCombinedPlayerList(p))
    				{
    					if(p_ == null || p_.getLocation() != Location.GODWARS_DUNGEON)
    						continue;
    					TaskManager.submit(new Task(1, NEX, false) {
    						int origX, origY;
    						int ticks;
    						@Override
    						public void execute()
    						{
    
    							if(ticks == 0)
    							{
    								origX = p_.getPosition().getX();
    								origY = p_.getPosition().getY();
    							}
    							if(ticks == 5)
    							{
    								if(origX == p_.getPosition().getX() && origY == p_.getPosition().getY())
    								{
    									p_.dealDamage(new Hit(100 + Misc.getRandom(100), Hitmask.RED, CombatIcon.NONE));
    									p_.getPacketSender().sendMessage("The shadows begin to damage you!");
    									this.stop();
    								}
    							}
    
    							if(ticks == 10) {
    								this.stop();
    							}
    
    							ticks++;
    						}
    
    						@Override
    						public void stop() {
    							setEventRunning(false);
    							attacks[3] = false;
    							NEX.setChargingAttack(false);
    						}
    					});
    				}
    			}else if(rnd >= 5 && rnd <= 7 && !attacks[4])
    			{
    				NEX.forceChat("Embrace darkness!");
    				attacks[4] = true;
    				NEX.setChargingAttack(true);
    				for(Player p_ : Misc.getCombinedPlayerList(p))
    				{
    					if(p_ == null || p_.getLocation() != Location.GODWARS_DUNGEON)
    						continue;
    					TaskManager.submit(new Task(1, NEX, false) {
    						int ticks = 0;
    						@Override
    						public void execute()
    						{
    							if(ticks == 10)
    								setShadow(p_, 250);
    							else {
    								double dist = p_.getPosition().distanceToPoint(NEX.getPosition().getX(), NEX.getPosition().getY());
    								if(dist < 3)
    								{
    									p_.getPacketSender().sendMessage("The shadows begin to consume you!");
    									p_.dealDamage(new Hit(10, Hitmask.RED, CombatIcon.NONE));
    									setShadow(p_, 20);
    								}
    								if(dist >= 3 && dist < 5)
    									setShadow(p_, 40);
    								if(dist > 5)
    									setShadow(p_, 90);
    							}
    							if(ticks >= 10)
    							{
    								this.stop();
    							}
    							ticks++;
    						}
    
    						@Override
    						public void stop() {
    							setEventRunning(false);
    							attacks[4] = false;
    							NEX.setChargingAttack(false);
    						}
    					});
    				}
    				NEX.performAnimation(new Animation(6984));
    				new CombatHitTask(NEX.getCombatBuilder(), new CombatContainer(NEX, p, 1, CombatType.MAGIC, true)).handleAttack();
    				return true;
    			} else {
    				if(p.getPosition().distanceToPoint(NEX.getPosition().getX(), NEX.getPosition().getY()) <= 2 && Misc.getRandom(1) == 0)
    				{
    					NEX.performAnimation(new Animation(6354));
    					TaskManager.submit(new Task(1, NEX, false) {
    						@Override
    						public void execute() {
    							new CombatHitTask(NEX.getCombatBuilder(), new CombatContainer(NEX, p, 1, CombatType.MELEE, true)).handleAttack();
    							stop();
    						}
    					});
    					return true;
    				} else {
    					NEX.performAnimation(new Animation(6326));
    					NEX.performGraphic(new Graphic(378));
    					new CombatHitTask(NEX.getCombatBuilder(), new CombatContainer(NEX, p, 1, CombatType.MAGIC, true)).handleAttack();
    					return true;
    				}
    			}
    		}
    Nex Bug Does not fix the problem
    Reply With Quote  
     

  9. #9  
    GravityScape & SimpliCity Developer.

    RSWSkiller's Avatar
    Join Date
    Dec 2013
    Age
    27
    Posts
    754
    Thanks given
    184
    Thanks received
    68
    Rep Power
    172
    Quote Originally Posted by Swiffy View Post
    More people using ruse = more bugs being found, will update this thread with more fixes in the future so keep checking back on it
    Nex bug "fix" doesn't work .-.
    Reply With Quote  
     

  10. #10  
    Donator

    Join Date
    Oct 2015
    Posts
    36
    Thanks given
    17
    Thanks received
    9
    Rep Power
    12
    nex :l
    Reply With Quote  
     

Page 1 of 2 12 LastLast

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. [Ruse] Pets bug fix
    By Swiffy in forum Snippets
    Replies: 7
    Last Post: 12-01-2015, 10:48 AM
  2. buying entity combat bug fix
    By Hiken jr in forum Buying
    Replies: 0
    Last Post: 05-31-2014, 06:58 PM
  3. [PI] Combat Level Calculation Bug Fix!
    By Treq in forum Snippets
    Replies: 10
    Last Post: 12-27-2011, 05:46 AM
  4. [Azure] Combat bug fix
    By Joker in forum Snippets
    Replies: 3
    Last Post: 05-29-2011, 08:26 PM
  5. Combat bug fix [final dev 2.6]
    By killamess in forum Tutorials
    Replies: 20
    Last Post: 07-31-2009, 02:34 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
  •