ScriptUO

Scripting Resources & Utilities => Stealth Client => Stealth Snippets\Library => Topic started by: Chrisok on April 24, 2013, 09:18:25 AM

Title: GM detect
Post by: Chrisok on April 24, 2013, 09:18:25 AM
i use this for fs uosa change names if you know them.
Code: [Select]
Unit GM_detect;
interface
 
function is_GM_around():boolean;
function does_GM_name_match(ID:cardinal):boolean;
implementation
 
Var
   GM_name_contains :array of string; // general prefixes+official uosa staff
      
 
function does_GM_name_match(ID:cardinal):boolean;
var
   HisName:String;
   i:integer;
begin
   HisName := GetName(ID);
  GM_name_contains := ['GM','Seer', 'Counselor', 'Helper', 'Administrator', 'Admin','GM_name1', 'GM_name2', 'GM_name3', 'GM_name4', 'Derrick', 'Kaivan'];
   For i:= Low(GM_name_contains) to High(GM_name_contains) do
   begin
      if (BMSearch(1,HisName,GM_name_contains[i])>0) then
      begin
      // the name of the character mached with one of known GM names
         AddToSystemJournal('Found by a GM, CARE');
         Result := true;
         Exit;
      end;
   end;
   Result := false;
end;

function is_GM_around():boolean;
var
   GM_ID :Cardinal;
begin
   FindDistance := 30;
  
   GM_ID := FindType($0190, Ground);  // looking for a male GM
  
   if (GM_ID >0) then
      if (does_GM_name_match(GM_ID)) then
      begin
         Result := true;
         Exit;
      end;
 
   GM_ID := FindType($0191, Ground);   // looking for a female GM
      
   if (GM_ID >0) then
      if (does_GM_name_match(GM_ID)) then
      begin
         Result := true;
         Exit;
      end;
      
   // Found no Staff
  
   Result := false;
end;
 
begin
AddToSystemJournal('Found Nothing, Keep Macroing');
end.
Title: Re: GM detect
Post by: Crome969 on April 24, 2013, 09:50:12 AM
Title: Re: GM detect
Post by: manwinc on April 24, 2013, 10:03:03 AM
Phhhh.... This would be Useful IF GM's Existed anymore...
Title: Re: GM detect
Post by: Insideout on April 24, 2013, 11:03:38 AM
They still exist I have one drop by the house every time the lil razor running punks decided they think I'm scripting lol
Title: Re: GM detect
Post by: Chrisok on April 24, 2013, 01:20:45 PM
Yea, the one i personally use (has maybe an additional 10 lines) scans for people trying to talk to the bot, with about 10 different catchphrases to scan for.. posted this as something to develop from. Originally found it on a russian shard site not working so i fixed for the freeshards i play
Title: Re: GM detect
Post by: NObama on April 24, 2013, 02:59:12 PM
There are GMs.  Recently had someone page on me for refusing to sell them relic fragments at ridiculously low prices.  GM showed up to see if my multiple 3,000 relic frag commodity deeds were duped. 

They aren't, by the way.  Very amusing case of sour grapes. 
Title: Re: GM detect
Post by: manwinc on April 24, 2013, 04:12:44 PM
You guys must be Lucky then. I think I've been waiting on gm's for weeks to fix some glitched Accounts/Servers. 
Title: Re: GM detect
Post by: NObama on April 24, 2013, 04:33:49 PM
You guys must be Lucky then. I think I've been waiting on gm's for weeks to fix some glitched Accounts/Servers. 

Page on yourself, maybe?  This was on Atlantic...on which servers are you trying to get GM attention?
Title: Re: GM detect
Post by: Crome969 on April 24, 2013, 10:36:58 PM
You guys must be Lucky then. I think I've been waiting on gm's for weeks to fix some glitched Accounts/Servers. 
I needed 3 times a GM lately, Paged , after 2-8hours they were avaible. I also Paged on Pacific and then got response on europa, so i think they can react whenever they can and no matter where you are..
Title: Re: GM detect
Post by: uofreak on November 16, 2018, 09:25:41 AM
Cool but usually GMs are cloaked/hidden would this still detect them or nope? :)