-
Notifications
You must be signed in to change notification settings - Fork 1
/
class_b_w_a_p_i_1_1_bullet_interface.html
1 lines (1 loc) · 24.2 KB
/
class_b_w_a_p_i_1_1_bullet_interface.html
1
<!DOCTYPE html><html><head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>BWAPI: BWAPI::BulletInterface Class Reference</title><link rel="shortcut icon" href="favicon.ico" type="image/x-icon"><link rel="icon" href="favicon.ico" type="image/x-icon"><script>if(window.location.protocol!="file:"){(function(d,e,j,h,f,c,b){d.GoogleAnalyticsObject=f;d[f]=d[f]||function(){(d[f].q=d[f].q||[]).push(arguments)},d[f].l=1*new Date();c=e.createElement(j),b=e.getElementsByTagName(j)[0];c.async=1;c.src=h;b.parentNode.insertBefore(c,b)})(window,document,"script","//www.google-analytics.com/analytics.js","ga");ga("create","UA-11415685-4","auto");ga("send","pageview")};</script><link href="doxygen.css" rel="stylesheet"><script src="search/search.js"></script></head><body><div id="top"><div id="titlearea"><table><tbody><tr style="height: 56px;"><td id="projectlogo"><img style="width:110px;height:55px;" alt="Logo" src="logo.png"></td><td style="padding-left: 0.5em;"><div id="projectname">BWAPI <span id="projectnumber">4.2.0</span></div><div id="projectbrief">An API for interacting with Starcraft: Broodwar (1.16.1)</div></td></tr></tbody></table><div class="ribbon"><a href="//github.com/bwapi/bwapi">Fork me on GitHub</a></div></div><script>var searchBox=new SearchBox("searchBox","search",false,"Search");</script><div id="navrow1" class="tabs"><ul class="tablist"><li><a href="index.html"><span>Main Page</span></a></li><li><a href="modules.html"><span>Modules</span></a></li><li><a href="namespaces.html"><span>Namespaces</span></a></li><li class="current"><a href="annotated.html"><span>Classes</span></a></li><li><a href="//github.com/bwapi/bwapi/issues"><span>Issues</span></a></li><li><a href="//github.com/bwapi/bwapi/wiki"><span>Wiki</span></a></li><li><div id="MSearchBox" class="MSearchBoxInactive"><span class="left"><img id="MSearchSelect" src="search/mag_sel.png" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" alt=""><input id="MSearchField" value="Search" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)" onkeyup="searchBox.OnSearchFieldChange(event)"></span><span class="right"><a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" src="search/close.png" alt=""></a></span></div></li></ul></div><div id="navrow2" class="tabs2"><ul class="tablist"><li><a href="annotated.html"><span>Class List</span></a></li><li><a href="classes.html"><span>Class Index</span></a></li><li><a href="inherits.html"><span>Class Hierarchy</span></a></li><li><a href="functions.html"><span>Class Members</span></a></li></ul></div><div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"></div><div id="MSearchResultsWindow"><iframe src="javascript:void(0)" name="MSearchResults" id="MSearchResults"></iframe></div><div id="nav-path" class="navpath"><ul><li class="navelem"><a class="el" href="namespace_b_w_a_p_i.html">BWAPI</a></li><li class="navelem"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html">BulletInterface</a></li></ul></div></div><div class="header"><div class="summary"><a href="#pub-methods">Public Member Functions</a> | <a href="class_b_w_a_p_i_1_1_bullet_interface-members.html">List of all members</a></div><div class="headertitle"><div class="title">BWAPI::BulletInterface Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span><div class="ingroups"><a class="el" href="group___interface.html">Interface Classes</a></div></div></div></div><div class="contents"><div class="dynheader"> Inheritance diagram for BWAPI::BulletInterface:</div><div class="dyncontent"><div class="center"><img src="class_b_w_a_p_i_1_1_bullet_interface__inherit__graph.png" usemap="#_b_w_a_p_i_1_1_bullet_interface_inherit__map" alt="Inheritance graph"></div><map name="_b_w_a_p_i_1_1_bullet_interface_inherit__map" id="_b_w_a_p_i_1_1_bullet_interface_inherit__map"><area shape="rect" id="node3" href="class_b_w_a_p_i_1_1_interface.html" title="This generalized class allows the application of features that are common to all interface classes..." alt="" coords="12,5,167,33"></map></div><table class="memberdecls"><tbody><tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods"></a> Public Member Functions</h2></td></tr><tr><td class="memItemLeft">virtual bool </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a5ca6252c310179bc1c4fb165418c1ffd">exists</a> () const =0</td></tr><tr><td class="memItemLeft">virtual double </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a78da8566116cddae80877b38809eafb2">getAngle</a> () const =0</td></tr><tr><td class="memItemLeft">virtual int </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a54e6fa28adc5ead2fb284b44de015e4a">getID</a> () const =0</td></tr><tr><td class="memItemLeft">virtual <a class="el" href="namespace_b_w_a_p_i.html#ab8daa67d10dc7eaa154a2636ec1784f8">Player</a> </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#abb946823ae869cc2001a771d8e9c1ebb">getPlayer</a> () const =0</td></tr><tr><td class="memItemLeft">virtual <a class="el" href="namespace_b_w_a_p_i.html#ac3d7867eeb5adc1fc7983e2db5edb7c6">Position</a> </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a53daf3c8360dcac7a9e091cede457064">getPosition</a> () const =0</td></tr><tr><td class="memItemLeft">virtual int </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#ad1402d1d7ab90316db90b3514caee964">getRemoveTimer</a> () const =0</td></tr><tr><td class="memItemLeft">virtual <a class="el" href="namespace_b_w_a_p_i.html#afa82675af468ff71f8b884f63d200a54">Unit</a> </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#af975b7b72ea1398bae8768a68a50db3a">getSource</a> () const =0</td></tr><tr><td class="memItemLeft">virtual <a class="el" href="namespace_b_w_a_p_i.html#afa82675af468ff71f8b884f63d200a54">Unit</a> </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a7f4901ffc0209d201a4eb34e59e9cb20">getTarget</a> () const =0</td></tr><tr><td class="memItemLeft">virtual <a class="el" href="namespace_b_w_a_p_i.html#ac3d7867eeb5adc1fc7983e2db5edb7c6">Position</a> </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a8a7422d58b4bc30c101a9930cc56ac3d">getTargetPosition</a> () const =0</td></tr><tr><td class="memItemLeft">virtual <a class="el" href="class_b_w_a_p_i_1_1_bullet_type.html">BulletType</a> </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a6aef4cb43d5daf939f7a2fc679dc1675">getType</a> () const =0</td></tr><tr><td class="memItemLeft">virtual double </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a2df4a017cb0aea25ce9ea5b1d1cc23c6">getVelocityX</a> () const =0</td></tr><tr><td class="memItemLeft">virtual double </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a24219ad5614455bdcecc982650e9386b">getVelocityY</a> () const =0</td></tr><tr><td class="memItemLeft">virtual bool </td><td class="memItemRight"><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#ab632c2d49ac42bec65efe4718432ba18">isVisible</a> (<a class="el" href="namespace_b_w_a_p_i.html#ab8daa67d10dc7eaa154a2636ec1784f8">Player</a> player=nullptr) const =0</td></tr></tbody></table><a id="details"></a><h2 class="groupheader">Detailed Description</h2><div class="textblock"><p>An interface object representing a bullet or missile spawned from an attack. </p><p>The Bullet interface allows you to detect bullets, missiles, and other types of non-melee attacks or special abilities that would normally be visible through human eyes (A lurker spike or a Queen's flying parasite), allowing quicker reaction to unavoidable consequences.</p><p>For example, ordering medics to restore units that are about to receive a lockdown to compensate for latency and minimize its effects. You can't know entirely which unit will be receiving a lockdown unless you can detect the lockdown missile using the Bullet class.</p><p>Bullet objects are re-used after they are destroyed, however their ID is updated when it represents a new Bullet.</p><p>If <a class="el" href="namespace_b_w_a_p_i_1_1_flag.html#a394478b7ea50a1fea08f7a73bbad04aeaf6d5058525d1ce926407b5644594d790" title="Enable to get information about all units on the map, not just the visible units.">Flag::CompleteMapInformation</a> is disabled, then a Bullet is accessible if and only if it is visible. Otherwise if <a class="el" href="namespace_b_w_a_p_i_1_1_flag.html#a394478b7ea50a1fea08f7a73bbad04aeaf6d5058525d1ce926407b5644594d790" title="Enable to get information about all units on the map, not just the visible units.">Flag::CompleteMapInformation</a> is enabled, then all Bullets in the game are accessible. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_game.html#a5956598877c37a5422a2e32e061eac12" title="Retrieves the set of all accessible bullets. ">Game::getBullets</a>, <a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a5ca6252c310179bc1c4fb165418c1ffd" title="Checks if the Bullet exists in the view of the BWAPI player. ">BulletInterface::exists</a></dd></dl></div><h2 class="groupheader">Member Function Documentation</h2><a class="anchor" id="a54e6fa28adc5ead2fb284b44de015e4a"></a><div class="memitem"><div class="memproto">virtual int BWAPI::BulletInterface::getID () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves a unique identifier for the current Bullet. </p><dl class="section return"><dt>Returns</dt><dd>An integer value containing the identifier. </dd></dl></div></div><a class="anchor" id="a5ca6252c310179bc1c4fb165418c1ffd"></a><div class="memitem"><div class="memproto">virtual bool BWAPI::BulletInterface::exists () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Checks if the Bullet exists in the view of the <a class="el" href="namespace_b_w_a_p_i.html" title="The primary namespace for the BWAPI interface. ">BWAPI</a> player. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">true</td><td>If the bullet exists or is visible. </td></tr><tr><td class="paramname">false</td><td>If the bullet was destroyed or has gone out of scope.</td></tr></tbody></table></dd></dl><p>If <a class="el" href="namespace_b_w_a_p_i_1_1_flag.html#a394478b7ea50a1fea08f7a73bbad04aeaf6d5058525d1ce926407b5644594d790" title="Enable to get information about all units on the map, not just the visible units.">Flag::CompleteMapInformation</a> is disabled, and a Bullet is not visible, then the return value will be false regardless of the Bullet's true existence. This is because absolutely no state information on invisible enemy bullets is made available to the AI.</p><p>If <a class="el" href="namespace_b_w_a_p_i_1_1_flag.html#a394478b7ea50a1fea08f7a73bbad04aeaf6d5058525d1ce926407b5644594d790" title="Enable to get information about all units on the map, not just the visible units.">Flag::CompleteMapInformation</a> is enabled, then this function is accurate for all Bullet information. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#ab632c2d49ac42bec65efe4718432ba18" title="Retrieves the visibility state of the Bullet. ">isVisible</a>, <a class="el" href="class_b_w_a_p_i_1_1_unit_interface.html#a53abaf1441bb383be78559c6c59ebfd3" title="Checks if the Unit exists in the view of the BWAPI player. ">UnitInterface::exists</a></dd></dl></div></div><a class="anchor" id="abb946823ae869cc2001a771d8e9c1ebb"></a><div class="memitem"><div class="memproto">virtual <a class="el" href="namespace_b_w_a_p_i.html#ab8daa67d10dc7eaa154a2636ec1784f8">Player</a> BWAPI::BulletInterface::getPlayer () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the Player interface that owns the Bullet. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">nullptr</td><td>If the Player object for this Bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>The owning Player interface object. </dd></dl></div></div><a class="anchor" id="a6aef4cb43d5daf939f7a2fc679dc1675"></a><div class="memitem"><div class="memproto">virtual <a class="el" href="class_b_w_a_p_i_1_1_bullet_type.html">BulletType</a> BWAPI::BulletInterface::getType () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the type of this Bullet. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname"><a class="el" href="namespace_b_w_a_p_i_1_1_bullet_types.html#a18bee6269e57a312d293ed518cd8e082">BulletTypes::Unknown</a></td><td>if the Bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>A <a class="el" href="class_b_w_a_p_i_1_1_bullet_type.html" title="This class represents a type of bullet. ">BulletType</a> representing the Bullet's type. </dd></dl></div></div><a class="anchor" id="af975b7b72ea1398bae8768a68a50db3a"></a><div class="memitem"><div class="memproto">virtual <a class="el" href="namespace_b_w_a_p_i.html#afa82675af468ff71f8b884f63d200a54">Unit</a> BWAPI::BulletInterface::getSource () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the Unit interface that the Bullet spawned from. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">nullptr</td><td>If the source can not be identified or is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>The owning Unit interface object. </dd></dl><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a7f4901ffc0209d201a4eb34e59e9cb20" title="Retrieves the Unit interface that the Bullet is heading to. ">getTarget</a></dd></dl></div></div><a class="anchor" id="a53daf3c8360dcac7a9e091cede457064"></a><div class="memitem"><div class="memproto">virtual <a class="el" href="namespace_b_w_a_p_i.html#ac3d7867eeb5adc1fc7983e2db5edb7c6">Position</a> BWAPI::BulletInterface::getPosition () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the Bullet's current position. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname"><a class="el" href="namespace_b_w_a_p_i_1_1_positions.html#ae2581b77eb8c4d58663ce871f555973b">Positions::Unknown</a></td><td>If the Bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>A Position containing the Bullet's current coordinates. </dd></dl><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a8a7422d58b4bc30c101a9930cc56ac3d" title="Retrieves the target position that the Bullet is heading to. ">getTargetPosition</a></dd></dl></div></div><a class="anchor" id="a78da8566116cddae80877b38809eafb2"></a><div class="memitem"><div class="memproto">virtual double BWAPI::BulletInterface::getAngle () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieve's the direction the Bullet is facing. </p><p>If the angle is 0, then the Bullet is facing right.</p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">0.0</td><td>If the bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>A double representing the direction the Bullet is facing. </dd></dl></div></div><a class="anchor" id="a2df4a017cb0aea25ce9ea5b1d1cc23c6"></a><div class="memitem"><div class="memproto">virtual double BWAPI::BulletInterface::getVelocityX () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the X component of the Bullet's velocity, measured in pixels per frame. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">0.0</td><td>if the Bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>A double representing the number of pixels moved on the X axis per frame.</dd></dl><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a24219ad5614455bdcecc982650e9386b" title="Retrieves the Y component of the Bullet's velocity, measured in pixels per frame. ...">getVelocityY</a>, <a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a78da8566116cddae80877b38809eafb2" title="Retrieve's the direction the Bullet is facing. ">getAngle</a></dd></dl></div></div><a class="anchor" id="a24219ad5614455bdcecc982650e9386b"></a><div class="memitem"><div class="memproto">virtual double BWAPI::BulletInterface::getVelocityY () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the Y component of the Bullet's velocity, measured in pixels per frame. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">0.0</td><td>if the Bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>A double representing the number of pixels moved on the Y axis per frame.</dd></dl><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a2df4a017cb0aea25ce9ea5b1d1cc23c6" title="Retrieves the X component of the Bullet's velocity, measured in pixels per frame. ...">getVelocityX</a>, <a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a78da8566116cddae80877b38809eafb2" title="Retrieve's the direction the Bullet is facing. ">getAngle</a></dd></dl></div></div><a class="anchor" id="a7f4901ffc0209d201a4eb34e59e9cb20"></a><div class="memitem"><div class="memproto">virtual <a class="el" href="namespace_b_w_a_p_i.html#afa82675af468ff71f8b884f63d200a54">Unit</a> BWAPI::BulletInterface::getTarget () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the Unit interface that the Bullet is heading to. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">nullptr</td><td>If the Bullet's target Unit is inaccessible, the Bullet is targetting the ground, or if the Bullet itself is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>The target Unit interface object, if one exists. </dd></dl><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a8a7422d58b4bc30c101a9930cc56ac3d" title="Retrieves the target position that the Bullet is heading to. ">getTargetPosition</a>, <a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#af975b7b72ea1398bae8768a68a50db3a" title="Retrieves the Unit interface that the Bullet spawned from. ">getSource</a></dd></dl></div></div><a class="anchor" id="a8a7422d58b4bc30c101a9930cc56ac3d"></a><div class="memitem"><div class="memproto">virtual <a class="el" href="namespace_b_w_a_p_i.html#ac3d7867eeb5adc1fc7983e2db5edb7c6">Position</a> BWAPI::BulletInterface::getTargetPosition () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the target position that the Bullet is heading to. </p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname"><a class="el" href="namespace_b_w_a_p_i_1_1_positions.html#ae2581b77eb8c4d58663ce871f555973b">Positions::Unknown</a></td><td>If the bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>A Position indicating where the Bullet is headed. </dd></dl><dl class="section see"><dt>See also</dt><dd><a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a7f4901ffc0209d201a4eb34e59e9cb20" title="Retrieves the Unit interface that the Bullet is heading to. ">getTarget</a>, <a class="el" href="class_b_w_a_p_i_1_1_bullet_interface.html#a53daf3c8360dcac7a9e091cede457064" title="Retrieves the Bullet's current position. ">getPosition</a></dd></dl></div></div><a class="anchor" id="ad1402d1d7ab90316db90b3514caee964"></a><div class="memitem"><div class="memproto">virtual int BWAPI::BulletInterface::getRemoveTimer () const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the timer that indicates the Bullet's life span. </p><p>Bullets are not permanent objects, so they will often have a limited life span. This life span is measured in frames. Normally a Bullet will reach its target before being removed.</p><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">0</td><td>If the Bullet is inaccessible.</td></tr></tbody></table></dd></dl><dl class="section return"><dt>Returns</dt><dd>An integer representing the remaining number of frames until the Bullet self-destructs. </dd></dl></div></div><a class="anchor" id="ab632c2d49ac42bec65efe4718432ba18"></a><div class="memitem"><div class="memproto">virtual bool BWAPI::BulletInterface::isVisible (<a class="el" href="namespace_b_w_a_p_i.html#ab8daa67d10dc7eaa154a2636ec1784f8">Player</a> <span class="paramname"><em>player</em> = <code>nullptr</code></span>) const <span class="mlabels"><span class="mlabel">pure virtual</span></span></div><div class="memdoc"><p>Retrieves the visibility state of the Bullet. </p><dl class="params"><dt>Parameters</dt><dd><table class="params"><tbody><tr><td class="paramname">player</td><td>(optional) If this parameter is specified, then the Bullet's visibility to the given player is checked. If this parameter is omitted, then a default value of nullptr is used, which will check if the <a class="el" href="namespace_b_w_a_p_i.html" title="The primary namespace for the BWAPI interface. ">BWAPI</a> player has vision of the Bullet. </td></tr></tbody></table></dd></dl><dl class="section note"><dt>Note</dt><dd>If <code>player</code> is nullptr and Broodwar->self() is also nullptr, then the visibility of the Bullet is determined by checking if at least one other player has vision of the Bullet.</dd></dl><dl class="retval"><dt>Return values</dt><dd><table class="retval"><tbody><tr><td class="paramname">true</td><td>If the Bullet is visible to the specified player. </td></tr><tr><td class="paramname">false</td><td>If the Bullet is not visible to the specified player. </td></tr></tbody></table></dd></dl></div></div></div><hr class="footer"><address class="footer"><div style="float:left;" id="google_translate_element"></div><script>if(window.location.protocol!="file:"){function googleTranslateElementInit(){new google.translate.TranslateElement({pageLanguage:"en",layout:google.translate.TranslateElement.InlineLayout.HORIZONTAL},"google_translate_element")}var js=document.createElement("script");js.type="text/javascript";js.src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit";document.body.appendChild(js)};</script><small> Generated on Wed Apr 19 2017 09:26:58 for BWAPI by <a href="//www.doxygen.org/index.html"><img style="width:104px;height:31px;" class="footer" src="doxygen.png" alt="doxygen"></a> 1.8.11 </small></address><script src="jquery.js"></script><script src="dynsections.js"></script><script>$(document).ready(function(){searchBox.OnSelectItem(0);$(".memberdecls, .memname, .memproto, .paramname, .fieldname, .entry, .fragment").addClass("notranslate");$("#MSearchResultsWindow").addClass("notranslate");$(".qindex, .qindex + table").addClass("notranslate");$(".contents > ul").addClass("notranslate");$(".contents > h3").addClass("notranslate");$("#navrow4 > .tablist > li > a").addClass("notranslate");$("a.el, a.elRef").addClass("notranslate")});</script></body></html>