Author Topic: Picking a specific onscreen gump  (Read 3910 times)

0 Members and 1 Guest are viewing this topic.

Offline GrandewdTopic starter

  • Full Member
  • ***
  • Posts: 239
  • Activity:
    0%
  • Reputation Power: 3
  • Grandewd has no influence.
  • Respect: +24
  • Referrals: 0
    • View Profile
Picking a specific onscreen gump
« on: July 25, 2014, 05:14:55 PM »
0
Hi all,

First, I apologize if this is a really dumb question - but here goes.  Let's say I have 2 or more gumps currently on screen.  I know their ID's/names/types/etc.
How can I select one of these gumps to use contpos on?   :-[

Offline Crisis

  • Global Moderator
  • *
  • *
  • Posts: 3016
  • Activity:
    3.6%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Re: Picking a specific onscreen gump
« Reply #1 on: July 25, 2014, 07:15:33 PM »
0
I think you can set and name them at the beginning of the script.

Code: [Select]
set %tinkgump 530_497
set %othergump 180_250 ;or whatever size it is

and then call the one you want by name and use the contpos on it.

I may be way wrong too but it is worth a try  ;D

Offline GrandewdTopic starter

  • Full Member
  • ***
  • Posts: 239
  • Activity:
    0%
  • Reputation Power: 3
  • Grandewd has no influence.
  • Respect: +24
  • Referrals: 0
    • View Profile
Re: Picking a specific onscreen gump
« Reply #2 on: July 25, 2014, 09:20:43 PM »
0
I think you can set and name them at the beginning of the script.

Code: [Select]
set %tinkgump 530_497
set %othergump 180_250 ;or whatever size it is

and then call the one you want by name and use the contpos on it.

I may be way wrong too but it is worth a try  ;D

Good thinking, Crisis.... I'll give that a shot.   ;)

Offline Crome969

  • Elite
  • *
  • *
  • Posts: 2098
  • Activity:
    0%
  • Reputation Power: 25
  • Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.
  • Gender: Male
  • UO Enthusiast
  • Respect: +211
  • Referrals: 10
    • View Profile
    • ScriptSDK
Re: Picking a specific onscreen gump
« Reply #3 on: July 25, 2014, 11:55:55 PM »
0
I think you can set and name them at the beginning of the script.

Code: [Select]
set %tinkgump 530_497
set %othergump 180_250 ;or whatever size it is

and then call the one you want by name and use the contpos on it.

I may be way wrong too but it is worth a try  ;D

As i remember you only can move the onTop Gump. This means you must keep sure that your gump is ontop.

Your snippet doesnt should work in any case because you fill data to a variable and nothing more.

Offline manwinc

  • Elite
  • *
  • *
  • Posts: 2556
  • Activity:
    0%
  • Reputation Power: 32
  • manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!
  • Gender: Male
  • "The Devs Hard at Work"
  • Respect: +123
  • Referrals: 1
    • View Profile
Re: Picking a specific onscreen gump
« Reply #4 on: July 26, 2014, 11:43:10 AM »
0
What Crome Said. If a gump isn't on top with EUO, euo Can't see it. you have to force it to be the last gump opened. 
Monkeys and Typewriters!

" Oh I know, We'll make a Boss Encounter that requires 3 keys per player to enter, Then we'll make it not a closed instance so you never know if you are going to pop into a fresh room or a boss that has 1% Health left with 20 dudes smashing its face in, wasting your time and effort"

Offline Alpha

  • Hero Member
  • *
  • Posts: 583
  • Activity:
    0%
  • Reputation Power: 10
  • Alpha barely matters.Alpha barely matters.
  • Respect: +44
  • Referrals: 0
    • View Profile
Re: Picking a specific onscreen gump
« Reply #5 on: July 26, 2014, 04:56:00 PM »
0
If you have multiple gumps open you can only manipulate the focused 1 aka top one.   My quick and dirty fix for this was a subroutine where you input the specifics of the Gump you wanted to focus on focus on and then it would do  a certain number of mouse clicks around your screen looking for that gump.   Say the gump takes up 1/4 of your play area then with 4 clicks you can d focus on that gump or close out other gump covering it etc...
« Last Edit: July 26, 2014, 05:02:47 PM by Alpha »

Offline Endless Night

  • Global Moderator
  • *
  • *
  • Posts: 5467
  • Activity:
    0%
  • Reputation Power: 62
  • Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!
  • Respect: +393
  • Referrals: 1
    • View Profile
Re: Picking a specific onscreen gump
« Reply #6 on: July 26, 2014, 08:39:10 PM »
0
easiest way is to open it again.   That makes it the top gump.

Alternatively if you know its location you can click it to maybe make it top gump again.
Outlaw Josey Wales - "Manwink, A Long Gone Scripty, and Endless are always teasing us with their private sections lol. What there realy saying is scripters rule and users drool."
Briza - "Your a living breathing vortex of usefulness."

Offline GrandewdTopic starter

  • Full Member
  • ***
  • Posts: 239
  • Activity:
    0%
  • Reputation Power: 3
  • Grandewd has no influence.
  • Respect: +24
  • Referrals: 0
    • View Profile
Re: Picking a specific onscreen gump
« Reply #7 on: July 27, 2014, 10:38:57 AM »
0
Yes, it's that "top gump" thing that drives me crazy sometimes.
I should have mentioned that the gump I'm trying to focus on is one of the Heartwood Quest givers.  You have to double/click the npc, whereupon you get both the npc's PD and the quest gump (the one I want to position) at the same time.  I know the details of the quest gump, but trying to figure out how to move it.

Offline Crisis

  • Global Moderator
  • *
  • *
  • Posts: 3016
  • Activity:
    3.6%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Re: Picking a specific onscreen gump
« Reply #8 on: July 27, 2014, 10:52:26 AM »
0
Look at TM's heartwood quester and see how he handled the gumps. It may be the best way to figure out how to do it.  ;D

http://www.scriptuo.com/index.php?topic=374.0
« Last Edit: July 27, 2014, 10:55:01 AM by Crisis »

Offline TrailMyx

  • Officially retired from UO
  • Administrator
  • *
  • *
  • Posts: 13302
  • Activity:
    0.2%
  • Reputation Power: 154
  • TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!
  • Gender: Male
  • Viper!
  • Respect: +1349
  • Referrals: 33
    • View Profile
    • ScriptUO
Re: Picking a specific onscreen gump
« Reply #9 on: July 27, 2014, 11:05:08 AM »
0
Crisis is right, the HW quester gives you a method.  I had to come up with something that would re-focus the correct gump when UO changed the way the HW gump comes up and basically broke the current HW quest script implementation.  It's a TAD slower, but it works well.
Please read the ScriptUO site RULES
Come play RIFT with me!

Offline GrandewdTopic starter

  • Full Member
  • ***
  • Posts: 239
  • Activity:
    0%
  • Reputation Power: 3
  • Grandewd has no influence.
  • Respect: +24
  • Referrals: 0
    • View Profile
Re: Picking a specific onscreen gump
« Reply #10 on: July 27, 2014, 11:30:26 AM »
0
Yes, I have your Heartwood Quester TM, and will spend more time looking thru it for your method.
Mostly, I am constantly wondering about making sure the proper gump has the focus and ways to do that.
I mean, if the gump is onscreen (with other gumps) and you know all it's properties - then I would think that it would be easy to grab and move it... But sometimes, like this example, it's less than straightforward..
Thank you all for the input.  I do enjoy learning different aspects of UO scripting.....   ;)

Tags: