Permalink
Browse files

Interfaces base done

  • Loading branch information...
1 parent 547f97a commit 4f0d9dd2dba1b8d047f4049a49d4f82bd0ebff40 @smithtrenton smithtrenton committed Sep 15, 2011
Showing with 991 additions and 256 deletions.
  1. +61 −0 Modules/Core/Core.simba
  2. +144 −0 Modules/Core/Globals.simba
  3. +263 −253 Modules/Core/Hooks.simba
  4. +339 −3 Modules/Core/Interfaces.simba
  5. +24 −0 Modules/Core/Mouse.simba
  6. +160 −0 Wrappers/Interface.simba
@@ -11,6 +11,67 @@ begin
Writeln('['+Category+'] '+Message);
end;
+(*
+R_TrimHTML
+~~~~~~~~~~
+
+.. code-block:: pascal
+
+ function R_TrimHTML(S : string): string;
+
+Removes the HTML junk from a string.
+
+.. note::
+
+ by lordsaturn, pyroryan
+
+*)
+function R_TrimHTML(S : string): string;
+var
+ P, P2, PLength: integer;
+ Temp: string;
+begin
+ P := Pos('<', S);
+ P2 := Pos('>', S);
+ Result := S;
+ PLength := P2 - P + 1;
+ while (P <> 0) and (P2 <> 0) do
+ begin
+ Delete(Result, P, PLength);
+ P := Pos('<', Result);
+ Temp := Result;
+ Delete(Temp, 1, P - 1);
+ PLength := Pos('>', Temp);
+ end;
+end;
+
+(*
+R_StrInArr
+~~~~~~~~~~
+
+.. code-block:: pascal
+
+ function R_StrInArr(str: string; arrS: TStringArray): Boolean;
+
+Returns True if str is found in the Array. Case sensitive. Uses Pos.
+
+.. note::
+
+ by Narcle, Nava2
+
+*)
+function R_StrInArr(str: string; arrS: TStringArray): Boolean;
+var
+ I, L, H: Integer;
+begin
+ Result := True;
+ L := Low(arrS); H := High(arrS);
+ for I := L to H do
+ if Pos(Str, arrS[I]) > 0 then
+ Exit;
+ Result := False;
+end;
+
{$include_once Hooks.simba}
{$include_once SMART.simba}
{$include_once Globals.simba}
@@ -23,3 +23,147 @@ var
{$IFDEF UseLaptopMouse}
R_LMouse_MissChance: Integer;
{$ENDIF}
+
+const
+ NULL_INT = -1;
+ NULL_STRING = '';
+
+ {Gametab constants}
+ INTERFACE_GAMETAB = 548;
+ INTERFACE_GAMETAB_FACENORTH = 177;
+
+ RTAB_FRIENDSLIST = 99;
+ RTAB_CHAT = 100;
+ RTAB_CLANCHAT = 101;
+ RTAB_OPTIONS = 102;
+ RTAB_EMOTES = 103;
+ RTAB_MUSIC = 104;
+ RTAB_NOTES = 105;
+ RTAB_COMBAT = 128;
+ RTAB_TASKS = 129;
+ RTAB_STATS = 130;
+ RTAB_QUESTS = 131;
+ RTAB_INVENTORY = 132;
+ RTAB_EQUIPMENT = 133;
+ RTAB_PRAYER = 134;
+ RTAB_SPELLBOOK = 135;
+
+ INTERFACE_HITPOINTS = 748;
+ INTERFACE_PRAYER = 749;
+ INTERFACE_RUN = 750;
+ INTERFACE_SUMMONING = 747;
+ INTERFACE_WORLDMAP = 755;
+ INTERFACE_WORLDMAP_CLOSE = 44;
+
+ SETTING_RUN = 173;
+
+ {Inventory Constants}
+ INTERFACE_INVENTORY = 679;
+ INTERFACE_BANKINVENTORY = 763;
+
+ {Equipment Constants}
+ INTERFACE_EQUIPMENT = 387;
+
+ EQUIPMENT_HELMET = 8;
+ EQUIPMENT_CAPE = 11;
+ EQUIPMENT_NECKLACE = 14;
+ EQUIPMENT_WEAPON = 17;
+ EQUIPMENT_TORSO = 20;
+ EQUIPMENT_SHIELD = 23;
+ EQUIPMENT_LEGS = 26;
+ EQUIPMENT_GLOVES = 29;
+ EQUIPMENT_BOOTS = 32;
+ EQUIPMENT_RING = 35;
+ EQUIPMENT_AMMO = 38;
+
+ {Quest Constants}
+ INTERFACE_QUESTS = 190;
+ INTERFACE_QUESTINFO = 275;
+ INTERFACE_QUESTSTART = 178;
+ QUEST_INFO_NAME = 2;
+ QUEST_INFO_CLOSE = 8;
+ QUEST_START_YES = 78;
+ QUEST_POINTS = 2;
+ QUEST_LIST = 18;
+ QUEST_SCROLL = 17;
+ QUEST_FILTER = 10;
+ QUEST_DONE = 12;
+ QUEST_CHECKED = 699;
+ QUEST_STARTED = 65535;
+ QUEST_UNSTARTED = 16711680;
+ QUEST_COMPLETE = 65280;
+ QUEST_FILTERED = 2236962;
+ QUEST_UNKNOWN = -1;
+
+ {Player Model Constants}
+ MODEL_EQUIPMENT_CONSTANT = 1073741824;
+
+ MODEL_EQUIPMENT_HEAD = 0;
+ MODEL_EQUIPMENT_CAPE = 1;
+ MODEL_EQUIPMENT_NECK = 2;
+ MODEL_EQUIPMENT_WEAPON = 3;
+ MODEL_EQUIPMENT_BODY = 4;
+ MODEL_EQUIPMENT_SHIELD = 5;
+ MODEL_EQUIPMENT_LEGS = 7;
+ MODEL_EQUIPMENT_HANDS = 9;
+ MODEL_EQUIPMENT_BOOTS = 10;
+
+ {Object Constants}
+ OBJ_INTERACTABLE = 1;
+ OBJ_WALLOBJECT = 2;
+ OBJ_WALLDECORATION = 3;
+ OBJ_FLOORDECORATION = 4;
+
+ {Bank Constants}
+ INTERFACE_BANK = 762;
+ INTERFACE_BANK_BTN_CLOSE = 43;
+ INTERFACE_BANK_BTN_DEPOSITBAG = 33;
+ INTERFACE_BANK_BTN_DEPOSITEQUIP = 35;
+ INTERFACE_BANK_BTN_DEPOSITBEAST = 37;
+ INTERFACE_BANK_BTN_NOTE = 19;
+
+ INTERFACE_BANK_SLOTS = 93;
+ INTERFACE_BANK_SLOTS_MAX = 515;
+
+ INTERFACE_BANK_SCROLLBAR = 114;
+ INTERFACE_BANK_SCROLLBAR_BAR = 1;
+ INTERFACE_BANK_SCROLLBAR_BARTOP = 2;
+ INTERFACE_BANK_SCROLLBAR_BARBOT = 3;
+ INTERFACE_BANK_SCROLLBAR_UP = 4;
+ INTERFACE_BANK_SCROLLBAR_DOWN = 5;
+
+ INTERFACE_PINSCREEN = 13;
+
+ INTERFACE_DEPOSITBOX = 11;
+
+ TEXTURE_BANKTABSELECTED = 1419;
+ TEXTURE_WITHDRAWMODE_NOTED = 1433;
+
+ {Chat Constants}
+ INTERFACE_CHAT = 137;
+ INTERFACE_CHAT_OPTIONS = 751;
+ INTERFACE_CHAT_SCROLL = 59;
+
+ RCHAT_GAME = 31;
+ RCHAT_PUBLIC = 28;
+ RCHAT_PRIVATE = 25;
+ RCHAT_FRIENDS = 8;
+ RCHAT_CLAN = 22;
+ RCHAT_TRADE = 19;
+ RCHAT_ASSIST = 16;
+
+ {Misc Constants}
+ CROSSHAIR_NONE = 0;
+ CROSSHAIR_YELLOW = 1;
+ CROSSHAIR_RED = 2;
+ INTERFACE_LOGIN_SCREEN = 596;
+ INTERFACE_LOBBY_SCREEN = 907;
+
+ {Interface Constants}
+ SEARCH_NAME = 0;
+ SEARCH_TEXT = 1;
+ SEARCH_ACTION = 2;
+
+
+ SCROLLBAR_UP = 4;
+ SCROLLBAR_DOWN = 5;
Oops, something went wrong.

0 comments on commit 4f0d9dd

Please sign in to comment.