<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://www.seatribe.se/bt/bugzilla.dtd">

<bugzilla version="4.2"
          urlbase="http://www.seatribe.se/bt/"
          
          maintainer="fredrik@dolda2000.com"
>

    <bug>
          <bug_id>12</bug_id>
          
          <creation_ts>2012-07-12 00:36:00 +0200</creation_ts>
          <short_desc>Cannot click to move or interact with objects on MacOS 10.7.4 with GeForce 7300GT card</short_desc>
          <delta_ts>2014-03-14 08:20:10 +0100</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Salem</product>
          <component>Client</component>
          <version>unspecified</version>
          <rep_platform>Macintosh</rep_platform>
          <op_sys>Mac OS</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>211</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>---</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Andorn">M8R-vog5dj</reporter>
          <assigned_to name="loftar">fredrik</assigned_to>
          

      

      

      

          <long_desc isprivate="0">
            <commentid>40</commentid>
            <who name="Andorn">M8R-vog5dj</who>
            <bug_when>2012-07-12 00:36:42 +0200</bug_when>
            <thetext>When running the client on a Mac Pro with a GeForce 7300 GT card, I cannot left-click the ground to move, and I cannot click objects on the ground to interact with them. The 2d UI still works.

I *think* I&apos;ve narrowed the issue down to some unexpected results coming out of MapView.checkmapclick(), which depends on MapMesh.drawFlat(). When clicking the ground or objects, no hit is detected. The coordinates found appear to be incorrect.

When I change the camera angle using the mouse wheel to zoom all the way out, I see a slight improvement in the hit detection. At a certain zoom level (zoom all the way out, then zoom in about 4 - 5 clicks of the scroll wheel), I observe the values for &quot;tile = new Coord(hitcol.getRed() - 1, hitcol.getGreen() - 1);&quot; suddenly change.

I observe this only on my Mac Pro. I do not observe this on my mac laptop.
The Mac Pro is running 10.7.4, with a GeForce 7300GT.
The Macbook is running 10.6.x.


Affects the stock client, Ender&apos;s client, or BD client.
I have compiled and run the stock client and Ender&apos;s client from source (cloned from github July 10, 2012) to check for recent fixes.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <commentid>58</commentid>
            <who name="loftar">fredrik</who>
            <bug_when>2012-07-13 05:26:33 +0200</bug_when>
            <thetext>It&apos;s a bit weird, though. Even if it gets the coordinates wrong, it shouldn&apos;t mean that no hit whatever is detected (since all colors are valid). What values are you, in fact, getting in the various phases?</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <commentid>73</commentid>
            <who name="Andorn">M8R-vog5dj</who>
            <bug_when>2012-07-17 22:28:20 +0200</bug_when>
            <thetext>I&apos;m getting tile hit color values outside of the valid [0 - 25) range.

Stand in the new player area, after getting a body.

With the camera zoomed in to about 45 degrees, 
Click the top center of the clothes chest.
The player does not move.
Zoom the camera out all the way out to 90 degrees, looking straight down.
Clock the top center of the clothes chest, same spot.
The player moves to the chest.


I added some debugging statements to the code. In the log below, the first mousedown happens with the camera at 45 deg, the second with the camera at 90 deg:

 MapView mousedown button 1
 Running HitTest
 colorAtPixel= java.awt.Color[r=144,g=0,b=0]
 hit mesh=haven.MapMesh@1510e56
 tile hitcolor = java.awt.Color[r=74,g=8,b=0] coord = (73, 7)rl.limit.sz = (25, 25)
 colorAtPixel= java.awt.Color[r=240,g=240,b=0]
 nohit
 MapView mousedown button 1
 Running HitTest
 colorAtPixel= java.awt.Color[r=144,g=0,b=0]
 hit mesh=haven.MapMesh@1510e56
 tile hitcolor = java.awt.Color[r=3,g=18,b=0] coord = (2, 17)rl.limit.sz = (25, 25)
 pixel hitcolor = java.awt.Color[r=110,g=70,b=0]
 colorAtPixel= java.awt.Color[r=240,g=240,b=0]


Let me know if you want a dump of the code that generated this output.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <commentid>137</commentid>
            <who name="loftar">fredrik</who>
            <bug_when>2012-08-19 02:00:29 +0200</bug_when>
            <thetext>Since you know how to modify the client, you may want to use the new getimage() function of GOut to capture a screenshot of the image output when the click-test scene has been drawn, to see what it looks like.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <commentid>138</commentid>
              <attachid>5</attachid>
            <who name="loftar">fredrik</who>
            <bug_when>2012-08-19 02:01:28 +0200</bug_when>
            <thetext>Created attachment 5
MapView patch for image output

Example patch for MapView.java for using getimage() to help with debugging.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <commentid>642</commentid>
            <who name="loftar">fredrik</who>
            <bug_when>2014-03-14 08:20:10 +0100</bug_when>
            <thetext>Made a new, more descriptive report for the general case of this particular problem.

*** This bug has been marked as a duplicate of bug 211 ***</thetext>
          </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>5</attachid>
            <date>2012-08-19 02:01:00 +0200</date>
            <delta_ts>2012-08-19 02:01:28 +0200</delta_ts>
            <desc>MapView patch for image output</desc>
            <filename>clickimg.diff</filename>
            <type>text/plain</type>
            <size>854</size>
            <attacher>fredrik</attacher>
            
              <data encoding="base64">ZGlmZiAtLWdpdCBhL3NyYy9oYXZlbi9NYXBWaWV3LmphdmEgYi9zcmMvaGF2ZW4vTWFwVmlldy5q
YXZhCmluZGV4IDNjM2RkZjQuLjg4MDE5MWQgMTAwNjQ0Ci0tLSBhL3NyYy9oYXZlbi9NYXBWaWV3
LmphdmEKKysrIGIvc3JjL2hhdmVuL01hcFZpZXcuamF2YQpAQCAtNDY1LDYgKzQ3Nyw3IEBAIHB1
YmxpYyBjbGFzcyBNYXBWaWV3IGV4dGVuZHMgUFZpZXcgaW1wbGVtZW50cyBEVGFyZ2V0IHsKIAl9
CiAgICAgfQogCisgICAgcHJpdmF0ZSBpbnQgY2lzZXEgPSAwOwogICAgIHByaXZhdGUgQ29vcmQg
Y2hlY2ttYXBjbGljayhHT3V0IGcsIENvb3JkIGMpI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