Scripting Resources & Utilities > Orion UO Client
Orion.GetLastGump or GetGump() not suit for 1.26.4 client?
(1/1)
roro4ever:
Hello, I am a newbie for OrionUO Script. The freeshard I played recently using 1.26.4 client. I wrote some scirpt for train skill, and there are no problem.
Few days ago, I downloaded a script for trian blacksmithy skill, but it stucked at some code about gump.
So I wrote some scripts for learn and test gump statements.
But I found some problem, first is : How can I get gumpobject?
For example.
--- Code: ---function test(){
var IngotType='0x1BEF';
var gump0,gump1,gump2;
//TextWindow.Open();
Orion.UseType(IngotType);
Orion.Wait('useitemdelay');
gump0=Orion.GetLastGump();
gump1=Orion.GetGump('last');
Orion.Print('Orion.GumpCount='+Orion.GumpCount);
if (!(gump0 == null)) {
Orion.Print(gump0.ID);
Orion.InfoGump();
Orion.Wait(500);
}
else Orion.Print('No get gump0');
if (gump1==null) Orion.Print('gump1 is null');
}
--- End code ---
The result is :
gump0 and gump1 all are null....
why? 1.26.4 or other low version Clients can't GetGump?
altiric:
Instead of Wait('useitemdelay') try Orion.WaitForGump()
It's possible useitemdelay is too short to catch the gump poping up.
You'll also need to use Orion.Print(gump0.ID()) not (gump0.ID)
Navigation
[0] Message Index
Go to full version