Am I still waiting for the updates to happen or when he updates them? It's still outdated for me.
Printable View
Am I still waiting for the updates to happen or when he updates them? It's still outdated for me.
Same here. We play the waiting game for now.. :norris:
Get your own hooks? Ok, learn java, bytecode analysis then study the runetek engine till you start finding hooks.
Or just wait, Krazy meerkat does everything in his own time with little to no reward. So he can take as much time as he wants, since there is a good chance school/college/uni has restarted for him.
If you're so impatient, spent your "waiting" time learning a bit about the RuneTek Engine so you can change the names of my hooks to match the hook names that the include needs. I gave you all the hooks you need, you just need to learn the RS hierarchy; it's not difficult, I learnt the class and field hierarchy in about 2 hours =)
Not the best refactor but it's where I learnt, obviously you have to understand the core principles of Java first =)
RS Refactor
Thanks Cheddy
Done from 2 previous revisions of CHeddy and Merkat's to come up with an incomplete translation.
Code:http://speedy.sh/Dm6du/hooks-original.xlsx
Because you actually put the effort in to try, I will give you a file with the naming adapted for simba. That will make it easier for you to correct your translation table if you want to use it in the future =) Alternately you could just replace your hooks file with these and it should work (assuming I have corrected all the naming haha), some of the widget ones may need get added actually :/ :
Simba Code:{ 209 Hooks Found By Cheddys Beautiful Updater }
const
ReflectionRevision = '58';
{* BoundaryObject - 9 Hooks *}
BoundaryObject = 'cj';
BoundaryObject_AlternativeOrientation = 'd';
BoundaryObject_AlternativeOrientation_Multiplier = -1515667875;
BoundaryObject_BackupRenderable = 'v';
BoundaryObject_Flags = 'j';
BoundaryObject_Flags_Multiplier = 925559837;
BoundaryObject_Hash = 'z';
BoundaryObject_Hash_Multiplier = -101908655;
BoundaryObject_Orientation = 'e';
BoundaryObject_Orientation_Multiplier = 843487795;
BoundaryObject_Plane = 't';
BoundaryObject_Plane_Multiplier = -1666421637;
BoundaryObject_Renderable = 'n';
BoundaryObject_Get_X = 's';
BoundaryObject_Get_X_Multiplier = -1089886639;
BoundaryObject_Get_Y = 'f';
BoundaryObject_Get_Y_Multiplier = 1982254941;
{* Buffer - 2 Hooks *}
Buffer = 'db';
Buffer_Offset = 's';
Buffer_Offset_Multiplier = 1042478381;
Buffer_Payload = 't';
{* Cache - 5 Hooks *}
Cache = 'fy';
Cache_CacheableNode = 't';
Cache_NodeHashTable = 'e';
Cache_Queue = 'd';
Cache_Remaining = 'f';
Cache_Remaining_Multiplier = 1;
Cache_Size = 's';
Cache_Size_Multiplier = 1;
{* CacheableNode - 2 Hooks *}
CacheableNode = 'fe';
CacheableNode_Next = 'cp';
CacheableNode_Prev = 'cx';
{* Canvas - 1 Hooks *}
Canvas = 'dz';
Canvas_Component = 't';
{* Actor - 17 Hooks *}
Actor = 'ae';
Actor_Animation = 'ap';
Actor_Animation_Multiplier = 1281463967;
Actor_CombatCycle = 'ag';
Actor_CombatCycle_Multiplier = 1612466433;
Actor_Health = 'au';
Actor_Health_Multiplier = 2026047803;
Actor_HitCycles = 'aa';
Actor_HitDamages = 'at';
Actor_HitTypes = 'av';
Actor_Interacting = 'ay';
Actor_Interacting_Multiplier = 189973027;
Actor_MaxHealth = 'aj';
Actor_MaxHealth_Multiplier = 1042698779;
Actor_Orientation = 'bm';
Actor_Orientation_Multiplier = -1991653213;
Actor_PathLength = 'bj';
Actor_PathLength_Multiplier = 604519285;
Actor_PathTraversed = 'bw';
Actor_PathX = 'bs';
Actor_PathY = 'bb';
Actor_ActiveText = 'ax';
Actor_LocalX = 'k';
Actor_LocalX_Multiplier = -1912652009;
Actor_LocalY = 'b';
Actor_LocalY_Multiplier = 1159505345;
Actor_isInSequence = 'ar';
{* Client - 53 Hooks *}
Client = 'client';
Client_BaseX = 'w.cd';
Client_BaseX_Multiplier = -568870037;
Client_BaseY = 'e.cy';
Client_BaseY_Multiplier = -635953723;
Client_CameraPitch = 'bk.fa';
Client_CameraPitch_Multiplier = 1426250829;
Client_CameraX = 'w.ff';
Client_CameraX_Multiplier = -998054749;
Client_CameraY = 'g.fo';
Client_CameraY_Multiplier = 270638187;
Client_CameraYaw = 'f.fu';
Client_CameraYaw_Multiplier = 573879485;
Client_CameraZ = 'dy.fb';
Client_CameraZ_Multiplier = -2115906345;
Client_Canvas = 'p.po';
Client_CollisionMaps = 'client.w';
Client_Run_Energy = 'client.jv';
Client_Run_Energy_Multiplier = -758662925;
Client_Experiences = 'client.hu';
Client_LoopCycle = 'client.p';
Client_LoopCycle_Multiplier = 1234794817;
Client_Login_State = 'client.l';
Client_Login_State_Multiplier = -1320666373;
Client_GroundItems = 'client.hm';
Client_ItemDefinitionCache = 'aj.e';
Client_ItemContainerTable = 'w.t';
Client_Levels = 'client.ht';
Client_NPCs = 'client.bb';
Client_Player = 'cr.hf';
Client_Players = 'client.ga';
Client_LoginState = 'aw.ae';
Client_LoginState_Multiplier = 76594955;
Client_CompassAngle = 'client.fq';
Client_CompassAngle_Multiplier = -482144205;
Client_Map_Offset = 'client.df';
Client_Map_Offset_Multiplier = 816991303;
Client_Map_Scale = 'client.dg';
Client_Map_Scale_Multiplier = 1186981241;
Client_MenuActions = 'client.ik';
Client_MenuCount = 'client.ak';
Client_MenuCount_Multiplier = 1851881611;
Client_MenuHeight = 'ah.io';
Client_MenuHeight_Multiplier = -1940027677;
Client_MenuOptions = 'client.iq';
Client_MenuWidth = 'cf.im';
Client_MenuWidth_Multiplier = -497476525;
Client_MenuX = 'cz.he';
Client_MenuX_Multiplier = -1898904481;
Client_MenuY = 'f.hx';
Client_MenuY_Multiplier = -121628793;
Client_NPCDefinitionCache = 'ar.f';
Client_NPCIndices = 'client.bq';
Client_ObjectDefinitionCache = 'aq.e';
Client_Password = 'aw.az';
Client_Plane = 'h.hq';
Client_Plane_Multiplier = 892241573;
Client_RealLevels = 'client.hp';
Client_Region = 'e.dk';
Client_Settings = 'ei.s';
Client_GroundHeights = 'n.t';
Client_GroundSettings = 'n.s';
Client_Username = 'aw.am';
Client_ValidWidgets = 'ew.s';
Client_Weight = 'client.jz';
Client_Weight_Multiplier = 906057103;
Client_WidgetBoundsHeight = 'client.lb';
Client_WidgetBoundsWidth = 'client.lc';
Client_WidgetBoundsX = 'client.lv';
Client_WidgetBoundsY = 'client.lk';
Client_WidgetNodeTable = 'client.jb';
Client_Widgets = 'ew.t';
Client_WidgetSettings = 'ei.f';
Client_WidgetVarps = 'ei.f';
Client_isMenuOpen = 'client.hr';
{* CollisionMap - 1 Hooks *}
CollisionMap = 'go';
CollisionMap_Flags = 'ab';
{* FloorDecorationObject - 6 Hooks *}
FloorDecorationObject = 'co';
FloorDecorationObject_Flags = 'n';
FloorDecorationObject_Flags_Multiplier = 91978925;
FloorDecorationObject_Hash = 'd';
FloorDecorationObject_Hash_Multiplier = -2054573615;
FloorDecorationObject_Plane = 't';
FloorDecorationObject_Plane_Multiplier = 1678696827;
FloorDecorationObject_Renderable = 'e';
FloorDecorationObject_Get_X = 's';
FloorDecorationObject_Get_X_Multiplier = -421149461;
FloorDecorationObject_Get_Y = 'f';
FloorDecorationObject_Get_Y_Multiplier = -227813017;
{* NodeHashTable - 5 Hooks *}
NodeHashTable = 'ft';
NodeHashTable_Current = 'e';
NodeHashTable_CurrentIndex = 'd';
NodeHashTable_CurrentIndex_Multiplier = 1;
NodeHashTable_Head = 'f';
NodeHashTable_GetNodes = 's';
NodeHashTable_GetSize = 't';
NodeHashTable_GetSize_Multiplier = 1;
{* Item - 2 Hooks *}
Item = 'o';
Item_ID = 't';
Item_ID_Multiplier = 1375185025;
Item_StackSize = 's';
Item_StackSize_Multiplier = -1465831673;
{* ItemDefinition - 4 Hooks *}
ItemDefinition = 'aj';
ItemDefinition_GroundActions = 'i';
ItemDefinition_Name = 'u';
ItemDefinition_InventoryActions = 'o';
ItemDefinition_isMembers = 'h';
{* ItemContainer - 2 Hooks *}
ItemContainer = 'w';
ItemContainer_IDs = 's';
ItemContainer_StackSizes = 'f';
{* ItemLayer - 8 Hooks *}
ItemLayer = 'cs';
ItemLayer_BottomRenderable = 'e';
ItemLayer_Height = 'z';
ItemLayer_Height_Multiplier = -817560073;
ItemLayer_ID = 'v';
ItemLayer_ID_Multiplier = 116687793;
ItemLayer_MiddleRenderable = 'd';
ItemLayer_Plane = 't';
ItemLayer_Plane_Multiplier = 1919008493;
ItemLayer_TopRenderable = 'n';
ItemLayer_X = 's';
ItemLayer_X_Multiplier = 190476239;
ItemLayer_Y = 'f';
ItemLayer_Y_Multiplier = 1036270037;
{* LinkedList - 2 Hooks *}
LinkedList = 'fl';
LinkedList_Head = 't';
LinkedList_Tail = 's';
{* Model - 12 Hooks *}
Model = 'cc';
Model_IndicesX = 'u';
Model_IndicesY = 'g';
Model_IndicesZ = 'a';
Model_TexturedIndicesX = 'c';
Model_TexturedIndicesY = 'w';
Model_TexturedIndicesZ = 'l';
Model_TexturedVerticesX = 'u';
Model_TexturedVerticesY = 'g';
Model_TexturedVerticesZ = 'a';
Model_VerticesX = 'n';
Model_VerticesY = 'v';
Model_VerticesZ = 'z';
{* Node - 3 Hooks *}
Node = 'gm';
Node_Next = 'em';
Node_Previous = 'eh';
Node_ID = 'df';
{* NPC - 1 Hooks *}
NPC = 'ab';
NPC_Definition = 't';
{* NPCDefinition - 7 Hooks *}
NPCDefinition = 'ar';
NPCDefinition_Actions = 'k';
NPCDefinition_CombatLevel = 'h';
NPCDefinition_CombatLevel_Multiplier = 569378961;
NPCDefinition_ID = 'd';
NPCDefinition_ID_Multiplier = 903407553;
NPCDefinition_Name = 'n';
NPCDefinition_SettingID = 'ah';
NPCDefinition_SettingID_Multiplier = 722717255;
NPCDefinition_TransformIDs = 'ao';
NPCDefinition_VarBitID = 'ae';
NPCDefinition_VarBitID_Multiplier = 702885197;
{* ObjectDefinition - 2 Hooks *}
ObjectDefinition = 'aq';
ObjectDefinition_Actions = 'af';
ObjectDefinition_Name = 'a';
{* Player - 3 Hooks *}
Player = 'f';
Player_CombatLevel = 'd';
Player_CombatLevel_Multiplier = 1066957001;
Player_Model = 'c';
Player_Name = 't';
{* Queue - 1 Hooks *}
Queue = 'fx';
Queue_Head = 't';
{* Region - 2 Hooks *}
Region = 'cb';
Region_Objects = 'j';
Region_SceneTiles = 'n';
{* Renderable - 1 Hooks *}
Renderable = 'bq';
Renderable_ModelHeight = 'cj';
Renderable_ModelHeight_Multiplier = -698968837;
{* WorldObject - 12 Hooks *}
WorldObject = 'cm';
WorldObject_Flags = 'w';
WorldObject_Flags_Multiplier = 1203732819;
WorldObject_Height = 's';
WorldObject_Height_Multiplier = -1795351697;
WorldObject_Hash = 'c';
WorldObject_Hash_Multiplier = -1736250779;
WorldObject_Orientation = 'n';
WorldObject_Orientation_Multiplier = 1933292693;
WorldObject_Plane = 't';
WorldObject_Plane_Multiplier = 762681757;
WorldObject_RelativeX = 'v';
WorldObject_RelativeX_Multiplier = -767162703;
WorldObject_RelativeY = 'j';
WorldObject_RelativeY_Multiplier = 101039943;
WorldObject_Renderable = 'd';
WorldObject_SizeX = 'z';
WorldObject_SizeX_Multiplier = 1942425537;
WorldObject_SizeY = 'u';
WorldObject_SizeY_Multiplier = 1814654745;
WorldObject_Get_X = 'f';
WorldObject_Get_X_Multiplier = 1837351411;
WorldObject_Get_Y = 'e';
WorldObject_Get_Y_Multiplier = 195040881;
{* SceneTile - 8 Hooks *}
SceneTile = 'cw';
SceneTile_BoundaryObject = 'v';
SceneTile_FloorDecorationObject = 'j';
SceneTile_ItemLayer = 'u';
SceneTile_Plane = 'e';
SceneTile_Plane_Multiplier = 1693898871;
SceneTile_WorldObjects = 'a';
SceneTile_WallObject = 'z';
SceneTile_X = 's';
SceneTile_X_Multiplier = -833139785;
SceneTile_Y = 'f';
SceneTile_Y_Multiplier = -985522581;
{* WallObject - 11 Hooks *}
WallObject = 'cn';
WallObject_BackupRenderable = 'j';
WallObject_Flags = 'g';
WallObject_Flags_Multiplier = -153029915;
WallObject_Height = 'd';
WallObject_Height_Multiplier = -1238977827;
WallObject_Hash = 'u';
WallObject_Hash_Multiplier = 1278767611;
WallObject_Orientation = 'e';
WallObject_Orientation_Multiplier = 1930387639;
WallObject_Plane = 't';
WallObject_Plane_Multiplier = 637314477;
WallObject_RelativeX = 'n';
WallObject_RelativeX_Multiplier = 337723027;
WallObject_RelativeY = 'v';
WallObject_RelativeY_Multiplier = -1850897549;
WallObject_Renderable = 'z';
WallObject_X = 's';
WallObject_X_Multiplier = -366351375;
WallObject_Y = 'f';
WallObject_Y_Multiplier = 1317694817;
{* Widget - 26 Hooks *}
Widget = 'ew';
Widget_GetActions = 'bh';
Widget_BorderThickness = 'at';
Widget_BorderThickness_Multiplier = 1107949007;
Widget_BoundsIndex = 'dq';
Widget_BoundsIndex_Multiplier = -1419799283;
Widget_Children = 'dt';
Widget_GetItems = 'dr';
Widget_Height = 'b';
Widget_Height_Multiplier = -1971283087;
Widget_GetID = 'a';
Widget_GetID_Multiplier = 640678563;
Widget_GetIndex = 'c';
Widget_GetIndex_Multiplier = -1751616003;
Widget_ItemID = 'du';
Widget_ItemID_Multiplier = 802088521;
Widget_LoopCycleStatus = 'dg';
Widget_LoopCycleStatus_Multiplier = -1404242157;
Widget_Name = 'bv';
Widget_GetRelativeX = 'k';
Widget_GetRelativeX_Multiplier = -764139897;
Widget_GetRelativeY = 'b';
Widget_GetRelativeY_Multiplier = -1971283087;
Widget_Root = 'bj';
Widget_RootID = 'h';
Widget_RootID_Multiplier = 1154498019;
Widget_ScrollX = 'o';
Widget_ScrollX_Multiplier = -1096692949;
Widget_ScrollY = 'm';
Widget_ScrollY_Multiplier = 1512227783;
Widget_SpriteID = 'am';
Widget_SpriteID_Multiplier = 132754559;
Widget_StackSize = 'dv';
Widget_StackSize_Multiplier = 192913583;
Widget_GetStackSizes = 'dk';
Widget_GetText = 'br';
Widget_GetTextureID = 'aq';
Widget_GetTextureID_Multiplier = 2009338005;
Widget_Width = 'k';
Widget_Width_Multiplier = -764139897;
Widget_X = 'p';
Widget_X_Multiplier = 692928385;
Widget_Y = 'x';
Widget_Y_Multiplier = -598844925;
Widget_isHidden = 'i';
{* WidgetNode - 1 Hooks *}
WidgetNode = 'e';
WidgetNode_ID = 't';
WidgetNode_ID_Multiplier = 2097571581;
The hooks have been updated, thanks Cheddy.
I'm not here to debate naming, although the names used in this include aren't entirely logical, it's better not to have this discussion at the minute b/c it's a matter of opinion in the end (eg. Actor class could also be called Character, Entity, etc.) not to mention that Cheddy's updater is for a different include.
Error: Out Of Range at line 509
The following DTMs were not freed: [SRL - Lamp bitmap, SRL - Book of Knowledge, 2]
The following bitmaps were not freed: [SRL - Mod bitmap, SRL - Admin bitmap, SRL - Minimap Mask bitmap, 3]
^ is in the misc file.
Getting this now that the reflection include updated. Any ideas on what to do??
What happened to our Updater? o.O
Well randoms are completely optional now...
Add something where you can input the offset in extends. For example, when you want to attack a dragon.
Had to make a seperate function, it's an really easy add.
Simba Code:function dragon_TileToMS(Tile: TPoint): TPoint;
var
X, Y, Height: Integer;
begin
X := Round((Tile.X - (SmartGetFieldInt(SmartCurrentTarget, 0, client_baseX) * client_baseX_Multiplier) - 0.0) * 128);
Y := Round((Tile.Y - (SmartGetFieldInt(SmartCurrentTarget, 0, client_baseY) * client_baseY_Multiplier) - 0.0) * 128);
Height := R_GetTileHeight(Tile);
Result := R_TileToMSEx(X, Y, Height);
if (not PointInBox(Result, MSBox)) then
Result := Point(-1, -1);
end;
Edit:
0,5 -> 0,0 on the math in TileToMS :)
Fixed it to match our hook names :)
Simba Code:type TRSPlayer = record
Name, OverheadText : String;
Level, CurrentHP, MaxHP, Animation, Interacting, Orientation, Plane : Integer;
InCombat : boolean;
Tile, TileWalkQueue : TPoint;
end;
TRSPlayerArray = array of TRSPlayer;
function R_GetAllRSPlayers: TRSPlayerArray;
var
i, j, PlayerCount, Ref, PlayerName, Overhead, x, y, LoopCycle : Integer;
begin
PlayerCount := SmartGetFieldArraySize(SmartCurrentTarget, 0, Client_Players, 0);
for i:=0 to PlayerCount-1 do begin
Ref := SmartGetFieldArrayObject(SmartCurrentTarget, 0, Client_Players, i);
if (Ref <= 0) then
Continue;
Inc(j);
SetLength(Result, j);
PlayerName := SmartGetFieldObject(SmartCurrentTarget, Ref, Player_Name);
x := SmartGetFieldInt(SmartCurrentTarget, 0, Client_BaseX)*Client_BaseX_Multiplier;
y := SmartGetFieldInt(SmartCurrentTarget, 0, Client_BaseY)*Client_BaseY_Multiplier;
LoopCycle := SmartGetFieldInt(SmartCurrentTarget, 0, Client_LoopCycle)*Client_LoopCycle_Multiplier;
with Result[j-1] do begin
Level := SmartGetFieldInt(SmartCurrentTarget, Ref, Player_CombatLevel)*Player_CombatLevel_Multiplier;
CurrentHP := SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_Health)*Actor_Health_Multiplier;
MaxHP := SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_MaxHealth)*Actor_MaxHealth_Multiplier;
Animation := SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_Animation)*Actor_Animation_Multiplier;
Interacting := SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_Interacting)*Actor_Interacting_Multiplier;
Orientation := Round(FixD(180 + (SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_Orientation)*Actor_Orientation_Multiplier*45)/2048));
Plane := SmartGetFieldInt(SmartCurrentTarget, 0, Client_Plane)*Client_Plane_Multiplier; //uses client's plane it was found on...
Name := R_GetJavaString(PlayerName, 512);
OverheadText := R_GetJavaString(Overhead, 512);
InCombat := (SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_CombatCycle) * Actor_CombatCycle_Multiplier) > LoopCycle;
Tile := Point(x + (SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_LocalX) * Actor_LocalX_Multiplier) div 128, y + (SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_LocalY) * Actor_LocalY_Multiplier) div 128);
TileWalkQueue := Point(SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_PathX), SmartGetFieldInt(SmartCurrentTarget, Ref, Actor_PathY));
end;
SmartFreeObject(SmartCurrentTarget, PlayerName);
SmartFreeObject(SmartCurrentTarget, Ref);
SmartFreeObject(SmartCurrentTarget, Overhead);
end;
end;
EDIT:
Add it?
Simba Code:function get_CB: integer;
begin
Result := StrToIntDef(GetNumbers(R_GetWidgetText(R_GetWidget(593, 2))), -1);
end;
Would it break the reflection include if i removed the antirandoms folder? I don't want it to detect randoms anymore since they are optional now.
R_GetSkillLevel or maybe it is R_GetHealth doesn't seem to work, broken hook ?
R_GetSkillLevel works fine.
R_GetHealth is based on R_GetSkillLevel.
My guess without testing would be that the constant SKILL_HITPOINTS is wrong?
Use getCurrentHealth, uses color but works flawless!
EDIT:
Writeln(R_GetSkillLevel(SKILL_HITPOINTS)); works fine?
EDIT:
@Dervish, both functions work fine :)
Hmm.. I don't understand why this doesn't work and just loops infinitely then :
Simba Code:if PrayingMelee then
begin
GameTab(tab_Prayer);
Prayer_Mouse('Protect',false);
repeat
Wait(50);
until(R_GetHealth < 13);
Prayer_Mouse('Protect',true);
end;
It doesn't seem to detect that current hitpoints are < 13.
Simba Code:function R_GetHealth: extended;
begin
Result := R_GetSkillLevel(skill_hitpoints);
end;
Doesn't work so... Where is the problem ? :s