Thread: Quest config's to chnge the quests stages the proper way

Results 1 to 9 of 9
  1. #1 Quest config's to chnge the quests stages the proper way 
    Donator


    Join Date
    Jan 2010
    Age
    29
    Posts
    4,122
    Thanks given
    274
    Thanks received
    551
    Rep Power
    738
    Can someone give me em or tell me a way to find em with 'Interfaces script'

    Found this but doesn't work.

    https://www.rune-server.ee/runescape...figs-dump.html
    Reply With Quote  
     

  2. #2  
    Renown Programmer & Respected Member

    Ryley's Avatar
    Join Date
    Aug 2011
    Posts
    596
    Thanks given
    254
    Thanks received
    521
    Rep Power
    1332
    I'm under the assumption that you're trying to do this on 317 while following that 500+ guide after the interface system changed. Of course it won't work.

    Pretty sure you can dump all the configs assigned to each interface on the quest tab.

    Edit: For when you do dump the configs, the last ID is the "quest complete" config, every other config represents a new stage in the quest if I'm not mistaken.
    Reply With Quote  
     

  3. #3  
    Donator


    Join Date
    Jan 2010
    Age
    29
    Posts
    4,122
    Thanks given
    274
    Thanks received
    551
    Rep Power
    738
    Quote Originally Posted by Ryley View Post
    I'm under the assumption that you're trying to do this on 317 while following that 500+ guide after the interface system changed. Of course it won't work.

    Pretty sure you can dump all the configs assigned to each interface on the quest tab.

    Edit: For when you do dump the configs, the last ID is the "quest complete" config, every other config represents a new stage in the quest if I'm not mistaken.
    I cant seem to find anything related to dump interface configs where would i start looking if i have like a uhm hint i could prob find it out.
    Reply With Quote  
     

  4. #4  
    Donator


    Join Date
    Jan 2010
    Age
    29
    Posts
    4,122
    Thanks given
    274
    Thanks received
    551
    Rep Power
    738
    Bump anyone that has this?
    Reply With Quote  
     

  5. #5  
    Registered Member

    Join Date
    Dec 2015
    Posts
    166
    Thanks given
    77
    Thanks received
    87
    Rep Power
    404
    these are called varbits and there should only be about 2000 in 317. just loop thru all of them until you find the one you need
    "It's all a matter of perspective. There is no single path in life that is right and fair and does no harm."
    Reply With Quote  
     

  6. #6  
    Donator


    Join Date
    Jan 2010
    Age
    29
    Posts
    4,122
    Thanks given
    274
    Thanks received
    551
    Rep Power
    738
    Quote Originally Posted by Whis View Post
    these are called varbits and there should only be about 2000 in 317. just loop thru all of them until you find the one you need
    Tried this no luck.
    Reply With Quote  
     

  7. #7  
    Renown Programmer & Respected Member

    Ryley's Avatar
    Join Date
    Aug 2011
    Posts
    596
    Thanks given
    254
    Thanks received
    521
    Rep Power
    1332
    Quote Originally Posted by Nighel View Post
    I cant seem to find anything related to dump interface configs where would i start looking if i have like a uhm hint i could prob find it out.
    One of the first few blocks when interfaces are decoded has a 2d array of scripts->instructions, can't recall anything else right now
    Reply With Quote  
     

  8. #8  
    Extreme Donator


    Join Date
    Oct 2010
    Posts
    2,853
    Thanks given
    1,213
    Thanks received
    1,622
    Rep Power
    5000
    Code:
    private int executeScript(Widget widget, int id) {
    		if (widget.valueIndexArray == null || id >= widget.valueIndexArray.length)
    			return -2;
    		try {
    			int script[] = widget.valueIndexArray[id];
    			int accumulator = 0;
    			int counter = 0;
    			int operator = 0;
    			do {
    				int instruction = script[counter++];
    				int value = 0;
    				byte next = 0;
    
    				if (instruction == 0) {
    					return accumulator;
    				}
    
    				if (instruction == 1) {
    					value = currentLevels[script[counter++]];
    				}
    
    				if (instruction == 2) {
    					value = maximumLevels[script[counter++]];
    				}
    
    				if (instruction == 3) {
    					value = currentExp[script[counter++]];
    				}
    
    				if (instruction == 4) {
    					Widget other = Widget.interfaceCache[script[counter++]];
    					int item = script[counter++];
    					if (item >= 0 && item < ItemDefinition.item_count
    							&& (!ItemDefinition.lookup(item).is_members_only
    									|| isMembers)) {
    						for (int slot = 0; slot < other.inventoryItemId.length; slot++)
    							if (other.inventoryItemId[slot] == item + 1)
    								value += other.inventoryAmounts[slot];
    
    					}
    				}
    				if (instruction == 5) {
    					value = settings[script[counter++]];
    				}
    
    				if (instruction == 6) {
    					value = SKILL_EXPERIENCE[maximumLevels[script[counter++]] - 1];
    				}
    
    				if (instruction == 7) {
    					value = (settings[script[counter++]] * 100) / 46875;
    				}
    
    				if (instruction == 8) {
    					value = localPlayer.combatLevel;
    				}
    
    				if (instruction == 9) {
    					for (int skill = 0; skill < SkillConstants.SKILL_COUNT; skill++)
    						if (SkillConstants.ENABLED_SKILLS[skill])
    							value += maximumLevels[skill];
    				}
    
    				if (instruction == 10) {
    					Widget other = Widget.interfaceCache[script[counter++]];
    					int item = script[counter++] + 1;
    					if (item >= 0 && item < ItemDefinition.item_count && isMembers) {
    						for (int stored =
    								0; stored < other.inventoryItemId.length; stored++) {
    							if (other.inventoryItemId[stored] != item)
    								continue;
    							value = 0x3b9ac9ff;
    							break;
    						}
    
    					}
    				}
    
    				if (instruction == 11) {
    					value = runEnergy;
    				}
    
    				if (instruction == 12) {
    					value = weight;
    				}
    
    				if (instruction == 13) {
    					int bool = settings[script[counter++]];
    					int shift = script[counter++];
    					value = (bool & 1 << shift) == 0 ? 0 : 1;
    				}
    
    				if (instruction == 14) {
    					int index = script[counter++];
    					VariableBits bits = VariableBits.varbits[index];
    					int setting = bits.getSetting();
    					int low = bits.getLow();
    					int high = bits.getHigh();
    					int mask = BIT_MASKS[high - low];
    					value = settings[setting] >> low & mask;
    				}
    
    				if (instruction == 15) {
    					next = 1;
    				}
    
    				if (instruction == 16) {
    					next = 2;
    				}
    
    				if (instruction == 17) {
    					next = 3;
    				}
    
    				if (instruction == 18) {
    					value = (localPlayer.x >> 7) + regionBaseX;
    				}
    
    				if (instruction == 19) {
    					value = (localPlayer.y >> 7) + regionBaseY;
    				}
    
    				if (instruction == 20) {
    					value = script[counter++];
    				}
    
    				if (next == 0) {
    
    					if (operator == 0) {
    						accumulator += value;
    					}
    
    					if (operator == 1) {
    						accumulator -= value;
    					}
    
    					if (operator == 2 && value != 0) {
    						accumulator /= value;
    					}
    
    					if (operator == 3) {
    						accumulator *= value;
    					}
    					operator = 0;
    				} else {
    					operator = next;
    				}
    			} while (true);
    		} catch (Exception _ex) {
    			return -1;
    		}
    	}
    Not sure if this is right but you might wanna look at that, probably what Ryley is on about
    Reply With Quote  
     

  9. #9  
    Donator


    Join Date
    Jan 2010
    Age
    29
    Posts
    4,122
    Thanks given
    274
    Thanks received
    551
    Rep Power
    738
    Quote Originally Posted by Ryley View Post
    One of the first few blocks when interfaces are decoded has a 2d array of scripts->instructions, can't recall anything else right now
    Quote Originally Posted by Professor Oak View Post
    Code:
    private int executeScript(Widget widget, int id) {
    		if (widget.valueIndexArray == null || id >= widget.valueIndexArray.length)
    			return -2;
    		try {
    			int script[] = widget.valueIndexArray[id];
    			int accumulator = 0;
    			int counter = 0;
    			int operator = 0;
    			do {
    				int instruction = script[counter++];
    				int value = 0;
    				byte next = 0;
    
    				if (instruction == 0) {
    					return accumulator;
    				}
    
    				if (instruction == 1) {
    					value = currentLevels[script[counter++]];
    				}
    
    				if (instruction == 2) {
    					value = maximumLevels[script[counter++]];
    				}
    
    				if (instruction == 3) {
    					value = currentExp[script[counter++]];
    				}
    
    				if (instruction == 4) {
    					Widget other = Widget.interfaceCache[script[counter++]];
    					int item = script[counter++];
    					if (item >= 0 && item < ItemDefinition.item_count
    							&& (!ItemDefinition.lookup(item).is_members_only
    									|| isMembers)) {
    						for (int slot = 0; slot < other.inventoryItemId.length; slot++)
    							if (other.inventoryItemId[slot] == item + 1)
    								value += other.inventoryAmounts[slot];
    
    					}
    				}
    				if (instruction == 5) {
    					value = settings[script[counter++]];
    				}
    
    				if (instruction == 6) {
    					value = SKILL_EXPERIENCE[maximumLevels[script[counter++]] - 1];
    				}
    
    				if (instruction == 7) {
    					value = (settings[script[counter++]] * 100) / 46875;
    				}
    
    				if (instruction == 8) {
    					value = localPlayer.combatLevel;
    				}
    
    				if (instruction == 9) {
    					for (int skill = 0; skill < SkillConstants.SKILL_COUNT; skill++)
    						if (SkillConstants.ENABLED_SKILLS[skill])
    							value += maximumLevels[skill];
    				}
    
    				if (instruction == 10) {
    					Widget other = Widget.interfaceCache[script[counter++]];
    					int item = script[counter++] + 1;
    					if (item >= 0 && item < ItemDefinition.item_count && isMembers) {
    						for (int stored =
    								0; stored < other.inventoryItemId.length; stored++) {
    							if (other.inventoryItemId[stored] != item)
    								continue;
    							value = 0x3b9ac9ff;
    							break;
    						}
    
    					}
    				}
    
    				if (instruction == 11) {
    					value = runEnergy;
    				}
    
    				if (instruction == 12) {
    					value = weight;
    				}
    
    				if (instruction == 13) {
    					int bool = settings[script[counter++]];
    					int shift = script[counter++];
    					value = (bool & 1 << shift) == 0 ? 0 : 1;
    				}
    
    				if (instruction == 14) {
    					int index = script[counter++];
    					VariableBits bits = VariableBits.varbits[index];
    					int setting = bits.getSetting();
    					int low = bits.getLow();
    					int high = bits.getHigh();
    					int mask = BIT_MASKS[high - low];
    					value = settings[setting] >> low & mask;
    				}
    
    				if (instruction == 15) {
    					next = 1;
    				}
    
    				if (instruction == 16) {
    					next = 2;
    				}
    
    				if (instruction == 17) {
    					next = 3;
    				}
    
    				if (instruction == 18) {
    					value = (localPlayer.x >> 7) + regionBaseX;
    				}
    
    				if (instruction == 19) {
    					value = (localPlayer.y >> 7) + regionBaseY;
    				}
    
    				if (instruction == 20) {
    					value = script[counter++];
    				}
    
    				if (next == 0) {
    
    					if (operator == 0) {
    						accumulator += value;
    					}
    
    					if (operator == 1) {
    						accumulator -= value;
    					}
    
    					if (operator == 2 && value != 0) {
    						accumulator /= value;
    					}
    
    					if (operator == 3) {
    						accumulator *= value;
    					}
    					operator = 0;
    				} else {
    					operator = next;
    				}
    			} while (true);
    		} catch (Exception _ex) {
    			return -1;
    		}
    	}
    Not sure if this is right but you might wanna look at that, probably what Ryley is on about
    So i checked for 638 (quest interface) and on the some of the ids from the quests itsels all didnt have a script?
    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. Replies: 6
    Last Post: 06-20-2014, 07:55 PM
  2. Replies: 0
    Last Post: 02-13-2013, 08:34 AM
  3. Replies: 0
    Last Post: 01-05-2013, 07:23 PM
  4. Replies: 1
    Last Post: 04-20-2010, 12:42 AM
  5. Replies: 12
    Last Post: 02-16-2009, 12:51 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
  •