View topic - sonar changes in q to dragon eye (7.66 - test417)



All times are UTC + 1 hour


Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: 23 Mar 2012, 10:11 

Joined: 29 May 2010, 22:40
In BA 7.66 until (incl.) BA-test417

way to reproduce:
* queue a sonar with a con or the com with the shift-key pressed
* when the mouse (with the semi-transparent sonar) is moved once to several times over a built unit (tidal/mex/sea lab) it changes into a dragons eye


Top
 Offline Profile  
 
PostPosted: 23 Mar 2012, 10:17 

Joined: 13 Aug 2007, 12:19
dansan wrote:
In BA 7.66 until (incl.) BA-test417

way to reproduce:
* queue a sonar with a con or the com with the shift-key pressed
* when the mouse (with the semi-transparent sonar) is moved once to several times over a built unit (tidal/mex/sea lab) it changes into a dragons eye


Lol that could explain why I made a dragon eye instead of sonar the other day. I thought i just misclicked it in the menu.


Top
 Offline Profile  
 
PostPosted: 23 Mar 2012, 10:46 
Lua Coder
User avatar

Joined: 20 Feb 2007, 01:10
That actually is a feature of the widget cmd_context_build.lua.

It automatically changes the selected building to the appropriate one when moving mouse from water <-> land.

So when you select a land mex and move your mouse to a water mex spot it automatically changes to water mex.

klapmongool wrote:
Lol that could explain why I made a dragon eye instead of sonar the other day. I thought i just misclicked it in the menu.

Hm that might happen in shallow water where it is possible to build sonar as well as dragon eye. I will exclude eye/sonar from that mechanism.


Top
 Offline Profile  
 
PostPosted: 23 Mar 2012, 11:33 

Joined: 29 May 2010, 22:40
very_bad_soldier wrote:
That actually is a feature of the widget cmd_context_build.lua.

It automatically changes the selected building to the appropriate one when moving mouse from water <-> land.
It's triggered when mouse moves over a unit (floating unit?) inside the water.


Top
 Offline Profile  
 
PostPosted: 23 Mar 2012, 16:04 
User avatar

Joined: 07 Dec 2008, 02:35
The context build widget is poorly written, the main problem being that it permanently switches your build option each time, forgetting what you originally selected.

Here's a scenario:
- You want to build a sonar
- You select the sonar from the list
- By chance the the buildmenu is 'over' land, and so the context build widget immediately switches your building selection to the dragons eye
- Because dragons eyes can be build on land and water, any location is valid and thus it never switches back to the sonar that you originally clicked.

While you could rewrite the widget to not be fail, a better solution would be to merge each of the equivalent land/sea units into a single amphibious/floating unit, resulting in a tidier mod and removing the need for the widget in the first place.


Top
 Offline Profile  
 
PostPosted: 23 Mar 2012, 16:39 
User avatar

Joined: 15 Mar 2012, 22:57
why would I want sonar to change to DT ?

just seems totally random and I already have a DT keybind :|


Top
 Offline Profile  
 
PostPosted: 23 Mar 2012, 21:51 
Lua Coder
User avatar

Joined: 20 Feb 2007, 01:10
Niobium wrote:
While you could rewrite the widget to not be fail

The problem is that the dragon eye can be build everywhere and therefore it does not qualify to be used in that widget.
How can that be solved by a different widget implementation?


Top
 Offline Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Site layout created by Roflcopter et al.