diff options
Diffstat (limited to 'Doc/doxygen/html/_ship_ctrl_8cpp_source.html')
-rw-r--r-- | Doc/doxygen/html/_ship_ctrl_8cpp_source.html | 458 |
1 files changed, 458 insertions, 0 deletions
diff --git a/Doc/doxygen/html/_ship_ctrl_8cpp_source.html b/Doc/doxygen/html/_ship_ctrl_8cpp_source.html new file mode 100644 index 0000000..4df8dec --- /dev/null +++ b/Doc/doxygen/html/_ship_ctrl_8cpp_source.html @@ -0,0 +1,458 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> +<meta http-equiv="X-UA-Compatible" content="IE=9"/> +<title>Starshatter_Open: D:/SRC/StarshatterSVN/Stars45/ShipCtrl.cpp Source File</title> +<link href="tabs.css" rel="stylesheet" type="text/css"/> +<script type="text/javascript" src="jquery.js"></script> +<script type="text/javascript" src="dynsections.js"></script> +<link href="navtree.css" rel="stylesheet" type="text/css"/> +<script type="text/javascript" src="resize.js"></script> +<script type="text/javascript" src="navtree.js"></script> +<script type="text/javascript"> + $(document).ready(initResizable); +</script> +<link href="search/search.css" rel="stylesheet" type="text/css"/> +<script type="text/javascript" src="search/search.js"></script> +<script type="text/javascript"> + $(document).ready(function() { searchBox.OnSelectItem(0); }); +</script> +<link href="doxygen.css" rel="stylesheet" type="text/css" /> +</head> +<body> +<div id="top"><!-- do not remove this div, it is closed by doxygen! --> +<div id="titlearea"> +<table cellspacing="0" cellpadding="0"> + <tbody> + <tr style="height: 56px;"> + <td style="padding-left: 0.5em;"> + <div id="projectname">Starshatter_Open + </div> + <div id="projectbrief">Open source Starshatter engine</div> + </td> + </tr> + </tbody> +</table> +</div> +<!-- end header part --> +<!-- Generated by Doxygen 1.8.1 --> +<script type="text/javascript"> +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="annotated.html"><span>Classes</span></a></li> + <li class="current"><a href="files.html"><span>Files</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 type="text" 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" border="0" src="search/close.png" alt=""/></a> + </span> + </div> + </li> + </ul> + </div> + <div id="navrow2" class="tabs2"> + <ul class="tablist"> + <li><a href="files.html"><span>File List</span></a></li> + <li><a href="globals.html"><span>File Members</span></a></li> + </ul> + </div> +</div><!-- top --> +<div id="side-nav" class="ui-resizable side-nav-resizable"> + <div id="nav-tree"> + <div id="nav-tree-contents"> + </div> + </div> + <div id="splitbar" style="-moz-user-select:none;" + class="ui-resizable-handle"> + </div> +</div> +<script type="text/javascript"> +$(document).ready(function(){initNavTree('_ship_ctrl_8cpp.html','');}); +</script> +<div id="doc-content"> +<!-- window showing the filter options --> +<div id="MSearchSelectWindow" + onmouseover="return searchBox.OnSearchSelectShow()" + onmouseout="return searchBox.OnSearchSelectHide()" + onkeydown="return searchBox.OnSearchSelectKey(event)"> +<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark"> </span>Macros</a></div> + +<!-- iframe showing the search results (closed by default) --> +<div id="MSearchResultsWindow"> +<iframe src="javascript:void(0)" frameborder="0" + name="MSearchResults" id="MSearchResults"> +</iframe> +</div> + +<div class="header"> + <div class="headertitle"> +<div class="title">ShipCtrl.cpp</div> </div> +</div><!--header--> +<div class="contents"> +<a href="_ship_ctrl_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">/* Project Starshatter 4.5</span></div> +<div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment"> Destroyer Studios LLC</span></div> +<div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> Copyright © 1997-2004. All Rights Reserved.</span></div> +<div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"></span></div> +<div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"> SUBSYSTEM: Stars.exe</span></div> +<div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> FILE: ShipCtrl.cpp</span></div> +<div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="comment"> AUTHOR: John DiCamillo</span></div> +<div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment"></span></div> +<div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment"></span></div> +<div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"> OVERVIEW</span></div> +<div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="comment"> ========</span></div> +<div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="comment"> Ship Controller class</span></div> +<div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="comment">*/</span></div> +<div class="line"><a name="l00014"></a><span class="lineno"> 14</span> </div> +<div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="preprocessor">#include "<a class="code" href="_mem_debug_8h.html">MemDebug.h</a>"</span></div> +<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="preprocessor">#include "<a class="code" href="_ship_ctrl_8h.html">ShipCtrl.h</a>"</span></div> +<div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="preprocessor">#include "<a class="code" href="_ship_8h.html">Ship.h</a>"</span></div> +<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="preprocessor">#include "<a class="code" href="_ship_design_8h.html">ShipDesign.h</a>"</span></div> +<div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="preprocessor">#include "<a class="code" href="_shield_8h.html">Shield.h</a>"</span></div> +<div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="preprocessor">#include "<a class="code" href="_sensor_8h.html">Sensor.h</a>"</span></div> +<div class="line"><a name="l00021"></a><span class="lineno"> 21</span> <span class="preprocessor">#include "<a class="code" href="_nav_system_8h.html">NavSystem.h</a>"</span></div> +<div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="preprocessor">#include "<a class="code" href="_flight_comp_8h.html">FlightComp.h</a>"</span></div> +<div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="preprocessor">#include "<a class="code" href="_landing_gear_8h.html">LandingGear.h</a>"</span></div> +<div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="preprocessor">#include "<a class="code" href="_sim_8h.html">Sim.h</a>"</span></div> +<div class="line"><a name="l00025"></a><span class="lineno"> 25</span> <span class="preprocessor">#include "<a class="code" href="_star_system_8h.html">StarSystem.h</a>"</span></div> +<div class="line"><a name="l00026"></a><span class="lineno"> 26</span> <span class="preprocessor">#include "<a class="code" href="_starshatter_8h.html">Starshatter.h</a>"</span></div> +<div class="line"><a name="l00027"></a><span class="lineno"> 27</span> <span class="preprocessor">#include "<a class="code" href="_h_u_d_view_8h.html">HUDView.h</a>"</span></div> +<div class="line"><a name="l00028"></a><span class="lineno"> 28</span> <span class="preprocessor">#include "<a class="code" href="_h_u_d_sounds_8h.html">HUDSounds.h</a>"</span></div> +<div class="line"><a name="l00029"></a><span class="lineno"> 29</span> <span class="preprocessor">#include "<a class="code" href="_key_map_8h.html">KeyMap.h</a>"</span></div> +<div class="line"><a name="l00030"></a><span class="lineno"> 30</span> <span class="preprocessor">#include "<a class="code" href="_radio_message_8h.html">RadioMessage.h</a>"</span></div> +<div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="preprocessor">#include "<a class="code" href="_radio_traffic_8h.html">RadioTraffic.h</a>"</span></div> +<div class="line"><a name="l00032"></a><span class="lineno"> 32</span> </div> +<div class="line"><a name="l00033"></a><span class="lineno"> 33</span> <span class="preprocessor">#include "<a class="code" href="_mouse_controller_8h.html">MouseController.h</a>"</span></div> +<div class="line"><a name="l00034"></a><span class="lineno"> 34</span> <span class="preprocessor">#include "<a class="code" href="_keyboard_8h.html">Keyboard.h</a>"</span></div> +<div class="line"><a name="l00035"></a><span class="lineno"> 35</span> <span class="preprocessor">#include "<a class="code" href="_joystick_8h.html">Joystick.h</a>"</span></div> +<div class="line"><a name="l00036"></a><span class="lineno"> 36</span> <span class="preprocessor">#include "<a class="code" href="_game_8h.html">Game.h</a>"</span></div> +<div class="line"><a name="l00037"></a><span class="lineno"> 37</span> <span class="preprocessor">#include "<a class="code" href="_data_loader_8h.html">DataLoader.h</a>"</span></div> +<div class="line"><a name="l00038"></a><span class="lineno"> 38</span> </div> +<div class="line"><a name="l00039"></a><span class="lineno"> 39</span> <span class="comment">// +--------------------------------------------------------------------+</span></div> +<div class="line"><a name="l00040"></a><span class="lineno"> 40</span> </div> +<div class="line"><a name="l00041"></a><span class="lineno"><a class="code" href="class_ship_ctrl.html#a740ddd5983fb63a86e7af478d517ab9e"> 41</a></span> <a class="code" href="class_ship_ctrl.html#a740ddd5983fb63a86e7af478d517ab9e">ShipCtrl::ShipCtrl</a>(<a class="code" href="class_ship.html">Ship</a>* s, <a class="code" href="class_motion_controller.html">MotionController</a>* ctrl)</div> +<div class="line"><a name="l00042"></a><span class="lineno"> 42</span> : ship(s), controller(ctrl), throttle_active(false), launch_latch(false),</div> +<div class="line"><a name="l00043"></a><span class="lineno"> 43</span> pickle_latch(false), target_latch(false)</div> +<div class="line"><a name="l00044"></a><span class="lineno"> 44</span> {</div> +<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i < 10; i++)</div> +<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  GetAsyncKeyState(<span class="charliteral">'0'</span>+i);</div> +<div class="line"><a name="l00047"></a><span class="lineno"> 47</span> }</div> +<div class="line"><a name="l00048"></a><span class="lineno"> 48</span> </div> +<div class="line"><a name="l00049"></a><span class="lineno"> 49</span> <span class="comment">// +--------------------------------------------------------------------+</span></div> +<div class="line"><a name="l00050"></a><span class="lineno"> 50</span> </div> +<div class="line"><a name="l00051"></a><span class="lineno"> 51</span> <span class="keywordtype">int</span></div> +<div class="line"><a name="l00052"></a><span class="lineno"><a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e"> 52</a></span> <a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">ShipCtrl::KeyDown</a>(<span class="keywordtype">int</span> action)</div> +<div class="line"><a name="l00053"></a><span class="lineno"> 53</span> {</div> +<div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  <span class="keywordtype">int</span> k = <a class="code" href="class_joystick.html#a7e960315c6bb224d7da1cd21d1dc3d66">Joystick::KeyDownMap</a>(action) ||</div> +<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  <a class="code" href="class_keyboard.html#ac5cc9ac02ef2d7738a8eee77d570288c">Keyboard::KeyDownMap</a>(action);</div> +<div class="line"><a name="l00056"></a><span class="lineno"> 56</span> </div> +<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  <span class="keywordflow">return</span> k;</div> +<div class="line"><a name="l00058"></a><span class="lineno"> 58</span> }</div> +<div class="line"><a name="l00059"></a><span class="lineno"> 59</span> </div> +<div class="line"><a name="l00060"></a><span class="lineno"> 60</span> <span class="keywordtype">int</span></div> +<div class="line"><a name="l00061"></a><span class="lineno"><a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263"> 61</a></span> <a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">ShipCtrl::Toggled</a>(<span class="keywordtype">int</span> action)</div> +<div class="line"><a name="l00062"></a><span class="lineno"> 62</span> {</div> +<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  <span class="keyword">static</span> <span class="keywordtype">double</span> last_toggle_time = 0;</div> +<div class="line"><a name="l00064"></a><span class="lineno"> 64</span> </div> +<div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(action)) {</div> +<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  <span class="keywordflow">if</span> ((<a class="code" href="class_game.html#a321790057c657d52f3585f883cdbc507">Game::RealTime</a>() - last_toggle_time) > 250) {</div> +<div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  last_toggle_time = <a class="code" href="class_game.html#a321790057c657d52f3585f883cdbc507">Game::RealTime</a>();</div> +<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  <span class="keywordflow">return</span> 1;</div> +<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  }</div> +<div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  }</div> +<div class="line"><a name="l00071"></a><span class="lineno"> 71</span> </div> +<div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  <span class="keywordflow">return</span> 0;</div> +<div class="line"><a name="l00073"></a><span class="lineno"> 73</span> }</div> +<div class="line"><a name="l00074"></a><span class="lineno"> 74</span> </div> +<div class="line"><a name="l00075"></a><span class="lineno"> 75</span> <span class="comment">// +--------------------------------------------------------------------+</span></div> +<div class="line"><a name="l00076"></a><span class="lineno"> 76</span> </div> +<div class="line"><a name="l00077"></a><span class="lineno"> 77</span> <span class="keywordtype">void</span></div> +<div class="line"><a name="l00078"></a><span class="lineno"><a class="code" href="class_ship_ctrl.html#a744ab2cf7a29111657908693caf62119"> 78</a></span> <a class="code" href="class_ship_ctrl.html#a744ab2cf7a29111657908693caf62119">ShipCtrl::Launch</a>()</div> +<div class="line"><a name="l00079"></a><span class="lineno"> 79</span> {</div> +<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>) {</div> +<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa461a879207448a32ead8ba02bfc5728">SetThrottle</a>(100);</div> +<div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  <a class="code" href="class_ship_ctrl.html#abd6d939c175a6eddef5b302cde0b4f68">throttle_active</a> = <span class="keyword">false</span>;</div> +<div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  <a class="code" href="class_ship_ctrl.html#a11005980f7d43b20d2d2c41efb101604">launch_latch</a> = <span class="keyword">true</span>;</div> +<div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  }</div> +<div class="line"><a name="l00085"></a><span class="lineno"> 85</span> }</div> +<div class="line"><a name="l00086"></a><span class="lineno"> 86</span> </div> +<div class="line"><a name="l00087"></a><span class="lineno"> 87</span> <span class="comment">// +--------------------------------------------------------------------+</span></div> +<div class="line"><a name="l00088"></a><span class="lineno"> 88</span> </div> +<div class="line"><a name="l00089"></a><span class="lineno"> 89</span> <span class="keywordtype">void</span></div> +<div class="line"><a name="l00090"></a><span class="lineno"><a class="code" href="class_ship_ctrl.html#a428ae28a53e131c350a41cff7023e9dc"> 90</a></span> <a class="code" href="class_ship_ctrl.html#a428ae28a53e131c350a41cff7023e9dc">ShipCtrl::ExecFrame</a>(<span class="keywordtype">double</span> seconds)</div> +<div class="line"><a name="l00091"></a><span class="lineno"> 91</span> {</div> +<div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  <a class="code" href="class_starshatter.html">Starshatter</a>* stars = <a class="code" href="class_starshatter.html#ab1ac37871c2f5d17a1e346e3fc9f0ba6">Starshatter::GetInstance</a>();</div> +<div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  <span class="keywordflow">if</span> (stars && stars-><a class="code" href="class_starshatter.html#aeafed8dc0388cecf5539366c68679fb7">GetChatMode</a>()) <span class="keywordflow">return</span>;</div> +<div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  <span class="keywordflow">if</span> (!<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>) <span class="keywordflow">return</span>;</div> +<div class="line"><a name="l00095"></a><span class="lineno"> 95</span> </div> +<div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  <span class="keyword">const</span> <span class="keywordtype">int</span> DELTA_THROTTLE = 5;</div> +<div class="line"><a name="l00097"></a><span class="lineno"> 97</span> </div> +<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  <a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a3607749f63700adf5059fe1db43ce422">Acquire</a>();</div> +<div class="line"><a name="l00099"></a><span class="lineno"> 99</span> </div> +<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aad13fe948c87ff5359b29ccfb69bcbc0">IsStarship</a>() && <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a0d3024bee22febe90b155e009344986c">GetFLCSMode</a>() == <a class="code" href="class_ship.html#a282a6477e9f0f8abdd0ee7e05ff94db1a30c98402f823a6b8258ab87064514843">Ship::FLCS_HELM</a>) {</div> +<div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aad9ea33cada7af3ec023cc53b46c9d65">ApplyHelmPitch</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a3d01eaf732bb81bd9d55cf55b953ce9d">Pitch</a>() * seconds);</div> +<div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a639718e2b02486a60799d0672b3d0dfb">ApplyHelmYaw</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#aa6ce27087180f101165133a3232fd34c">Yaw</a>() * seconds);</div> +<div class="line"><a name="l00103"></a><span class="lineno"> 103</span>  }</div> +<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  <span class="keywordflow">else</span> {</div> +<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_physical.html#adc0005c9ad6bea9c1beb03912ba1a079">ApplyRoll</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a0ebab66ab52fffe639fd39a429f64048">Roll</a>());</div> +<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a4f0f1545d4f119cd67e77030fdd80495">ApplyPitch</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a3d01eaf732bb81bd9d55cf55b953ce9d">Pitch</a>());</div> +<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_physical.html#a4b5a83f5bd906e0c09ff326f5c0168a2">ApplyYaw</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#aa6ce27087180f101165133a3232fd34c">Yaw</a>());</div> +<div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  }</div> +<div class="line"><a name="l00109"></a><span class="lineno"> 109</span> </div> +<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a147d7da94611eaf2f050749b9731b67b">SetTransX</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#ab10eb9ead64b5bdff110bf95a9b1504a">X</a>() * <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a6fd3887d24901d505be195335ff3b565">Design</a>()-><a class="code" href="class_ship_design.html#a7257db57f3f26f72a9b2489bb5e330c8">trans_x</a>);</div> +<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aace8b70a9db706e9940537f825e84c09">SetTransY</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a47b6b2e52c62b3c53a209869bc6c8654">Y</a>() * <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a6fd3887d24901d505be195335ff3b565">Design</a>()-><a class="code" href="class_ship_design.html#a0d87c6b237eb24fac4ca0a460e751876">trans_y</a>);</div> +<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a5a4aa08ee2da06cec328b034dee4f8c0">SetTransZ</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#aa12af989c2302cc258ec9e09abc2d991">Z</a>() * <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a6fd3887d24901d505be195335ff3b565">Design</a>()-><a class="code" href="class_ship_design.html#aaf042f3a7a4cbeb65ed9b96a963c76b1">trans_z</a>);</div> +<div class="line"><a name="l00113"></a><span class="lineno"> 113</span> </div> +<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  <span class="keywordtype">bool</span> augmenter = <span class="keyword">false</span>;</div> +<div class="line"><a name="l00115"></a><span class="lineno"> 115</span> </div> +<div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a69abb5f0defa85f5766bc75f42fd4e80">Throttle</a>() > 0.05) {</div> +<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#abd6d939c175a6eddef5b302cde0b4f68">throttle_active</a>) {</div> +<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa461a879207448a32ead8ba02bfc5728">SetThrottle</a>(<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a69abb5f0defa85f5766bc75f42fd4e80">Throttle</a>() * 100);</div> +<div class="line"><a name="l00119"></a><span class="lineno"> 119</span> </div> +<div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a69abb5f0defa85f5766bc75f42fd4e80">Throttle</a>() >= 0.99) </div> +<div class="line"><a name="l00121"></a><span class="lineno"> 121</span>  augmenter = <span class="keyword">true</span>;</div> +<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  }</div> +<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (!<a class="code" href="class_ship_ctrl.html#a11005980f7d43b20d2d2c41efb101604">launch_latch</a> || <a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#a69abb5f0defa85f5766bc75f42fd4e80">Throttle</a>() > 0.5) {</div> +<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  <a class="code" href="class_ship_ctrl.html#abd6d939c175a6eddef5b302cde0b4f68">throttle_active</a> = <span class="keyword">true</span>;</div> +<div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  <a class="code" href="class_ship_ctrl.html#a11005980f7d43b20d2d2c41efb101604">launch_latch</a> = <span class="keyword">false</span>;</div> +<div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  }</div> +<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  }</div> +<div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#abd6d939c175a6eddef5b302cde0b4f68">throttle_active</a>) {</div> +<div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa461a879207448a32ead8ba02bfc5728">SetThrottle</a>(0);</div> +<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  <a class="code" href="class_ship_ctrl.html#abd6d939c175a6eddef5b302cde0b4f68">throttle_active</a> = <span class="keyword">false</span>;</div> +<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  }</div> +<div class="line"><a name="l00132"></a><span class="lineno"> 132</span> </div> +<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aec7034aed96a05896d94d5189581674e">ExecFLCSFrame</a>();</div> +<div class="line"><a name="l00134"></a><span class="lineno"> 134</span> </div> +<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  <span class="keyword">static</span> <span class="keywordtype">double</span> time_til_change = 0.0;</div> +<div class="line"><a name="l00136"></a><span class="lineno"> 136</span> </div> +<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  <span class="keywordflow">if</span> (time_til_change < 0.001) {</div> +<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a2641f532b9a1ea91e44b6240aed875bf">KEY_THROTTLE_UP</a>)) {</div> +<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa461a879207448a32ead8ba02bfc5728">SetThrottle</a>(<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a518d34a37b8013128648260941462765">Throttle</a>() + DELTA_THROTTLE);</div> +<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  time_til_change = 0.05;</div> +<div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  }</div> +<div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  </div> +<div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#aea202dcc2ec6f87835d47ed4ecff7ede">KEY_THROTTLE_DOWN</a>)) {</div> +<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa461a879207448a32ead8ba02bfc5728">SetThrottle</a>(<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a518d34a37b8013128648260941462765">Throttle</a>() - DELTA_THROTTLE);</div> +<div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  time_til_change = 0.05;</div> +<div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  }</div> +<div class="line"><a name="l00147"></a><span class="lineno"> 147</span> </div> +<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a9322111c64e338abe089cbcdd93448a3">KEY_THROTTLE_ZERO</a>)) {</div> +<div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa461a879207448a32ead8ba02bfc5728">SetThrottle</a>(0);</div> +<div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a1d0d629bc7a7c541bee95312dc001df0">GetFLCS</a>())</div> +<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a1d0d629bc7a7c541bee95312dc001df0">GetFLCS</a>()-><a class="code" href="class_flight_comp.html#a338dee895b857a6f18c328b3b6bb51ad">FullStop</a>();</div> +<div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  time_til_change = 0.05;</div> +<div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  }</div> +<div class="line"><a name="l00154"></a><span class="lineno"> 154</span> </div> +<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a1e13cba5b64c5a86df1d5e3516615c11">KEY_THROTTLE_FULL</a>)) {</div> +<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa461a879207448a32ead8ba02bfc5728">SetThrottle</a>(100);</div> +<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  time_til_change = 0.05;</div> +<div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  }</div> +<div class="line"><a name="l00159"></a><span class="lineno"> 159</span> </div> +<div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#af69309249f8ceacee1ea4aefeb012c68">KEY_FLCS_MODE_AUTO</a>)) {</div> +<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#ac024dedfc6f936a662cbe726c014a712">CycleFLCSMode</a>();</div> +<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  }</div> +<div class="line"><a name="l00164"></a><span class="lineno"> 164</span> </div> +<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#aafab8a50a3b30850c2862545300aefe8">KEY_CYCLE_PRIMARY</a>)) {</div> +<div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  <a class="code" href="class_h_u_d_sounds.html#a2ce2e3e88a8f60234e183608b56004c3">HUDSounds::PlaySound</a>(<a class="code" href="class_h_u_d_sounds.html#a27e5315377467cababa29be8e99a0bd6abd1643fec8fd531af425b8d5a0d63d80">HUDSounds::SND_WEP_MODE</a>);</div> +<div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a27d50238916e43c12a23eaba756529ff">CyclePrimary</a>();</div> +<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  }</div> +<div class="line"><a name="l00170"></a><span class="lineno"> 170</span> </div> +<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#aa357ae0eeb1aaed1ae55143f13e8d186">KEY_CYCLE_SECONDARY</a>)) {</div> +<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  <a class="code" href="class_h_u_d_sounds.html#a2ce2e3e88a8f60234e183608b56004c3">HUDSounds::PlaySound</a>(<a class="code" href="class_h_u_d_sounds.html#a27e5315377467cababa29be8e99a0bd6abd1643fec8fd531af425b8d5a0d63d80">HUDSounds::SND_WEP_MODE</a>);</div> +<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#add658dcb66b1000d73a25f55a1b0dcc4">CycleSecondary</a>();</div> +<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  }</div> +<div class="line"><a name="l00176"></a><span class="lineno"> 176</span> </div> +<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a46c56d063a8672a6e9f97cb2352ec4a6">GetShield</a>()) {</div> +<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  <a class="code" href="class_shield.html">Shield</a>* shield = <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a46c56d063a8672a6e9f97cb2352ec4a6">GetShield</a>();</div> +<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  <span class="keywordtype">double</span> level = shield-><a class="code" href="class_system.html#a15f8c78d743f2f1d8ff8edd311c9a0d1">GetPowerLevel</a>();</div> +<div class="line"><a name="l00180"></a><span class="lineno"> 180</span> </div> +<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a9f2617ba1b0ba29a4c8764a946e2b17d">KEY_SHIELDS_FULL</a>)) {</div> +<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  <a class="code" href="class_h_u_d_sounds.html#a2ce2e3e88a8f60234e183608b56004c3">HUDSounds::PlaySound</a>(<a class="code" href="class_h_u_d_sounds.html#a27e5315377467cababa29be8e99a0bd6aa25b87fd28555b9fa9d81c89b58de721">HUDSounds::SND_SHIELD_LEVEL</a>);</div> +<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  shield-><a class="code" href="class_shield.html#a9c22986936f524254a4d49b249a78375">SetPowerLevel</a>(100);</div> +<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00185"></a><span class="lineno"> 185</span>  }</div> +<div class="line"><a name="l00186"></a><span class="lineno"> 186</span> </div> +<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a5edea6c1aa77f2a28fcedfe749b42d5b">KEY_SHIELDS_ZERO</a>)) {</div> +<div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  <a class="code" href="class_h_u_d_sounds.html#a2ce2e3e88a8f60234e183608b56004c3">HUDSounds::PlaySound</a>(<a class="code" href="class_h_u_d_sounds.html#a27e5315377467cababa29be8e99a0bd6aa25b87fd28555b9fa9d81c89b58de721">HUDSounds::SND_SHIELD_LEVEL</a>);</div> +<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  shield-><a class="code" href="class_shield.html#a9c22986936f524254a4d49b249a78375">SetPowerLevel</a>(0);</div> +<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00191"></a><span class="lineno"> 191</span>  }</div> +<div class="line"><a name="l00192"></a><span class="lineno"> 192</span> </div> +<div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#af881c50d39685461ce986131679b2eda">KEY_SHIELDS_UP</a>)) {</div> +<div class="line"><a name="l00194"></a><span class="lineno"> 194</span>  <span class="keywordflow">if</span> (level < 25) level = 25;</div> +<div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (level < 50) level = 50;</div> +<div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (level < 75) level = 75;</div> +<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  <span class="keywordflow">else</span> level = 100;</div> +<div class="line"><a name="l00198"></a><span class="lineno"> 198</span> </div> +<div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  <a class="code" href="class_h_u_d_sounds.html#a2ce2e3e88a8f60234e183608b56004c3">HUDSounds::PlaySound</a>(<a class="code" href="class_h_u_d_sounds.html#a27e5315377467cababa29be8e99a0bd6aa25b87fd28555b9fa9d81c89b58de721">HUDSounds::SND_SHIELD_LEVEL</a>);</div> +<div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  shield-><a class="code" href="class_shield.html#a9c22986936f524254a4d49b249a78375">SetPowerLevel</a>(level);</div> +<div class="line"><a name="l00201"></a><span class="lineno"> 201</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  }</div> +<div class="line"><a name="l00203"></a><span class="lineno"> 203</span> </div> +<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a29448d81593308accc428c3a59caa9ff">KEY_SHIELDS_DOWN</a>)) {</div> +<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  <span class="keywordflow">if</span> (level > 75) level = 75;</div> +<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (level > 50) level = 50;</div> +<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (level > 25) level = 25;</div> +<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  <span class="keywordflow">else</span> level = 0;</div> +<div class="line"><a name="l00209"></a><span class="lineno"> 209</span> </div> +<div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  <a class="code" href="class_h_u_d_sounds.html#a2ce2e3e88a8f60234e183608b56004c3">HUDSounds::PlaySound</a>(<a class="code" href="class_h_u_d_sounds.html#a27e5315377467cababa29be8e99a0bd6aa25b87fd28555b9fa9d81c89b58de721">HUDSounds::SND_SHIELD_LEVEL</a>);</div> +<div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  shield-><a class="code" href="class_shield.html#a9c22986936f524254a4d49b249a78375">SetPowerLevel</a>(level);</div> +<div class="line"><a name="l00212"></a><span class="lineno"> 212</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  }</div> +<div class="line"><a name="l00214"></a><span class="lineno"> 214</span> </div> +<div class="line"><a name="l00215"></a><span class="lineno"> 215</span>  }</div> +<div class="line"><a name="l00216"></a><span class="lineno"> 216</span> </div> +<div class="line"><a name="l00217"></a><span class="lineno"> 217</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#ad9bb5ab9df2731927abd39ffbb5fcd02">GetSensor</a>()) {</div> +<div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  <a class="code" href="class_sensor.html">Sensor</a>* sensor = <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#ad9bb5ab9df2731927abd39ffbb5fcd02">GetSensor</a>();</div> +<div class="line"><a name="l00219"></a><span class="lineno"> 219</span> </div> +<div class="line"><a name="l00220"></a><span class="lineno"> 220</span>  <span class="keywordflow">if</span> (sensor-><a class="code" href="class_sensor.html#a23742fbd06ccf6c8d6b6fb26f79e7fa1">GetMode</a>() < <a class="code" href="class_sensor.html#a67373e45d6929876af10812b6c736016ae7674ee4a6da36b0888a167fb2cc3caf">Sensor::PST</a>) {</div> +<div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a87a34f63a95178dee88abd96d19d39b2">KEY_SENSOR_MODE</a>)) {</div> +<div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  <span class="keywordtype">int</span> sensor_mode = sensor-><a class="code" href="class_sensor.html#a23742fbd06ccf6c8d6b6fb26f79e7fa1">GetMode</a>() + 1;</div> +<div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  <span class="keywordflow">if</span> (sensor_mode > <a class="code" href="class_sensor.html#a67373e45d6929876af10812b6c736016a06fe9ce26ecfe658c9b200c36fefc108">Sensor::GM</a>)</div> +<div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  sensor_mode = <a class="code" href="class_sensor.html#a67373e45d6929876af10812b6c736016a92a7a1f6ddda34103ddbfbd22acd6df1">Sensor::PAS</a>;</div> +<div class="line"><a name="l00225"></a><span class="lineno"> 225</span> </div> +<div class="line"><a name="l00226"></a><span class="lineno"> 226</span>  sensor-><a class="code" href="class_sensor.html#a79ebe6fc17fc57e9351eeda1208ad1ee">SetMode</a>((<a class="code" href="class_sensor.html#a67373e45d6929876af10812b6c736016">Sensor::Mode</a>) sensor_mode);</div> +<div class="line"><a name="l00227"></a><span class="lineno"> 227</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00228"></a><span class="lineno"> 228</span>  }</div> +<div class="line"><a name="l00229"></a><span class="lineno"> 229</span> </div> +<div class="line"><a name="l00230"></a><span class="lineno"> 230</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#ae68a2e6b54e77a8d80a91ccea56c4370">KEY_SENSOR_GROUND_MODE</a>)) {</div> +<div class="line"><a name="l00231"></a><span class="lineno"> 231</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a9f283093f40dce0a125e3ea3a794928c">IsAirborne</a>()) {</div> +<div class="line"><a name="l00232"></a><span class="lineno"> 232</span>  sensor-><a class="code" href="class_sensor.html#a79ebe6fc17fc57e9351eeda1208ad1ee">SetMode</a>(<a class="code" href="class_sensor.html#a67373e45d6929876af10812b6c736016a06fe9ce26ecfe658c9b200c36fefc108">Sensor::GM</a>);</div> +<div class="line"><a name="l00233"></a><span class="lineno"> 233</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00234"></a><span class="lineno"> 234</span>  }</div> +<div class="line"><a name="l00235"></a><span class="lineno"> 235</span>  }</div> +<div class="line"><a name="l00236"></a><span class="lineno"> 236</span>  }</div> +<div class="line"><a name="l00237"></a><span class="lineno"> 237</span>  <span class="keywordflow">else</span> {</div> +<div class="line"><a name="l00238"></a><span class="lineno"> 238</span>  <span class="comment">// manual "return to search" command for starships:</span></div> +<div class="line"><a name="l00239"></a><span class="lineno"> 239</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a87a34f63a95178dee88abd96d19d39b2">KEY_SENSOR_MODE</a>)) {</div> +<div class="line"><a name="l00240"></a><span class="lineno"> 240</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a32acf68f5ac07882e170cf08718fe031">DropTarget</a>();</div> +<div class="line"><a name="l00241"></a><span class="lineno"> 241</span>  }</div> +<div class="line"><a name="l00242"></a><span class="lineno"> 242</span>  }</div> +<div class="line"><a name="l00243"></a><span class="lineno"> 243</span> </div> +<div class="line"><a name="l00244"></a><span class="lineno"> 244</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a79e3bb69884fc2f98dea806fe77aa6cb">KEY_SENSOR_RANGE_PLUS</a>)) {</div> +<div class="line"><a name="l00245"></a><span class="lineno"> 245</span>  sensor-><a class="code" href="class_sensor.html#ab7b6f82438ab8993dcb00ae48138d715">IncreaseRange</a>();</div> +<div class="line"><a name="l00246"></a><span class="lineno"> 246</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00247"></a><span class="lineno"> 247</span>  }</div> +<div class="line"><a name="l00248"></a><span class="lineno"> 248</span> </div> +<div class="line"><a name="l00249"></a><span class="lineno"> 249</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#a1d8befd409addab8989ad8f425a93fff">KEY_SENSOR_RANGE_MINUS</a>)) {</div> +<div class="line"><a name="l00250"></a><span class="lineno"> 250</span>  sensor-><a class="code" href="class_sensor.html#ac0a24820b737828ec86f08471fd0efd1">DecreaseRange</a>();</div> +<div class="line"><a name="l00251"></a><span class="lineno"> 251</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00252"></a><span class="lineno"> 252</span>  }</div> +<div class="line"><a name="l00253"></a><span class="lineno"> 253</span>  }</div> +<div class="line"><a name="l00254"></a><span class="lineno"> 254</span> </div> +<div class="line"><a name="l00255"></a><span class="lineno"> 255</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#ad1d5728c2244a1f685e7eba884eb34de">KEY_EMCON_PLUS</a>)) {</div> +<div class="line"><a name="l00256"></a><span class="lineno"> 256</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a052631d199eb5726a300734cf83a4a25">SetEMCON</a>(<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aeb573750e6baf5a92bd9f1dbd9859fa0">GetEMCON</a>()+1);</div> +<div class="line"><a name="l00257"></a><span class="lineno"> 257</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00258"></a><span class="lineno"> 258</span>  }</div> +<div class="line"><a name="l00259"></a><span class="lineno"> 259</span> </div> +<div class="line"><a name="l00260"></a><span class="lineno"> 260</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#adc04b06bff5b2b219c222221816e7726">KEY_EMCON_MINUS</a>)) {</div> +<div class="line"><a name="l00261"></a><span class="lineno"> 261</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a052631d199eb5726a300734cf83a4a25">SetEMCON</a>(<a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aeb573750e6baf5a92bd9f1dbd9859fa0">GetEMCON</a>()-1);</div> +<div class="line"><a name="l00262"></a><span class="lineno"> 262</span>  time_til_change = 0.5f;</div> +<div class="line"><a name="l00263"></a><span class="lineno"> 263</span>  }</div> +<div class="line"><a name="l00264"></a><span class="lineno"> 264</span>  }</div> +<div class="line"><a name="l00265"></a><span class="lineno"> 265</span>  <span class="keywordflow">else</span></div> +<div class="line"><a name="l00266"></a><span class="lineno"> 266</span>  time_til_change -= seconds;</div> +<div class="line"><a name="l00267"></a><span class="lineno"> 267</span> </div> +<div class="line"><a name="l00268"></a><span class="lineno"> 268</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#ac78c100b0aac6f786393d9215d9a093b">ActionMap</a>(<a class="code" href="_motion_controller_8h.html#a152e816e84cc7cdc73329b621db60325">KEY_ACTION_0</a>))</div> +<div class="line"><a name="l00269"></a><span class="lineno"> 269</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a49504dc4f5361dc12d60ade6a4e0a6ca">FirePrimary</a>();</div> +<div class="line"><a name="l00270"></a><span class="lineno"> 270</span> </div> +<div class="line"><a name="l00271"></a><span class="lineno"> 271</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#ac78c100b0aac6f786393d9215d9a093b">ActionMap</a>(<a class="code" href="_motion_controller_8h.html#a2509fbf15590b74a6dae3af227646acc">KEY_ACTION_1</a>)) {</div> +<div class="line"><a name="l00272"></a><span class="lineno"> 272</span>  <span class="keywordflow">if</span> (!<a class="code" href="class_ship_ctrl.html#a326bc4dde82965f85d2e82495c5473a3">pickle_latch</a>)</div> +<div class="line"><a name="l00273"></a><span class="lineno"> 273</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a5f0d0c9f63e2f2b9b8256f720a42ad15">FireSecondary</a>();</div> +<div class="line"><a name="l00274"></a><span class="lineno"> 274</span> </div> +<div class="line"><a name="l00275"></a><span class="lineno"> 275</span>  <a class="code" href="class_ship_ctrl.html#a326bc4dde82965f85d2e82495c5473a3">pickle_latch</a> = <span class="keyword">true</span>;</div> +<div class="line"><a name="l00276"></a><span class="lineno"> 276</span>  }</div> +<div class="line"><a name="l00277"></a><span class="lineno"> 277</span>  <span class="keywordflow">else</span> {</div> +<div class="line"><a name="l00278"></a><span class="lineno"> 278</span>  <a class="code" href="class_ship_ctrl.html#a326bc4dde82965f85d2e82495c5473a3">pickle_latch</a> = <span class="keyword">false</span>;</div> +<div class="line"><a name="l00279"></a><span class="lineno"> 279</span>  }</div> +<div class="line"><a name="l00280"></a><span class="lineno"> 280</span> </div> +<div class="line"><a name="l00281"></a><span class="lineno"> 281</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#ac6bf54853c9289c7b7244742c886dd0b">controller</a>-><a class="code" href="class_motion_controller.html#ac78c100b0aac6f786393d9215d9a093b">ActionMap</a>(<a class="code" href="_motion_controller_8h.html#a8402a0b0a82dd5f641973c236355d2a4">KEY_ACTION_3</a>)) {</div> +<div class="line"><a name="l00282"></a><span class="lineno"> 282</span>  <span class="keywordflow">if</span> (!<a class="code" href="class_ship_ctrl.html#ae91e4b4600450f8b7ae5e137ac639f72">target_latch</a>)</div> +<div class="line"><a name="l00283"></a><span class="lineno"> 283</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#afe5d622c03d1d931ac346c2b0fcbf28f">LockTarget</a>(<a class="code" href="class_sim_object.html#a43f6bd6f43c6e7798b4f7ac729c53982a883a4c0d3bae3a294a55a710f8bd7cf4">SimObject::SIM_SHIP</a>);</div> +<div class="line"><a name="l00284"></a><span class="lineno"> 284</span> </div> +<div class="line"><a name="l00285"></a><span class="lineno"> 285</span>  <a class="code" href="class_ship_ctrl.html#ae91e4b4600450f8b7ae5e137ac639f72">target_latch</a> = <span class="keyword">true</span>;</div> +<div class="line"><a name="l00286"></a><span class="lineno"> 286</span>  }</div> +<div class="line"><a name="l00287"></a><span class="lineno"> 287</span>  <span class="keywordflow">else</span> {</div> +<div class="line"><a name="l00288"></a><span class="lineno"> 288</span>  <a class="code" href="class_ship_ctrl.html#ae91e4b4600450f8b7ae5e137ac639f72">target_latch</a> = <span class="keyword">false</span>;</div> +<div class="line"><a name="l00289"></a><span class="lineno"> 289</span>  }</div> +<div class="line"><a name="l00290"></a><span class="lineno"> 290</span> </div> +<div class="line"><a name="l00291"></a><span class="lineno"> 291</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#ac75cf30a2f62be0f881d3b1caafc4ffe">SetAugmenter</a>(augmenter || (<a class="code" href="class_ship_ctrl.html#a9d5e178c8401862d82b5704d083ab28e">KeyDown</a>(<a class="code" href="_key_map_8h.html#ae5cf6053d859656ed3aca3661df89398">KEY_AUGMENTER</a>) ? <span class="keyword">true</span> : <span class="keyword">false</span>));</div> +<div class="line"><a name="l00292"></a><span class="lineno"> 292</span> </div> +<div class="line"><a name="l00293"></a><span class="lineno"> 293</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a8058250ae0035d6295d7d8e1852720bf">KEY_DECOY</a>))</div> +<div class="line"><a name="l00294"></a><span class="lineno"> 294</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#ad0df57a35655a4041edfa7ee8ec6f1a4">FireDecoy</a>();</div> +<div class="line"><a name="l00295"></a><span class="lineno"> 295</span> </div> +<div class="line"><a name="l00296"></a><span class="lineno"> 296</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#aa9109b285781daef7adb107fad6656b0">KEY_LAUNCH_PROBE</a>))</div> +<div class="line"><a name="l00297"></a><span class="lineno"> 297</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aa48218fe2c66ff8604b9f655bb89ec2e">LaunchProbe</a>();</div> +<div class="line"><a name="l00298"></a><span class="lineno"> 298</span> </div> +<div class="line"><a name="l00299"></a><span class="lineno"> 299</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a68bd15362fa6abd0d21fe492f015f964">KEY_GEAR_TOGGLE</a>))</div> +<div class="line"><a name="l00300"></a><span class="lineno"> 300</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a5244be69906eebf1b0fdd1b5a82ba024">ToggleGear</a>();</div> +<div class="line"><a name="l00301"></a><span class="lineno"> 301</span> </div> +<div class="line"><a name="l00302"></a><span class="lineno"> 302</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a4402f6cd72969cff80b140961b06eab9">KEY_NAVLIGHT_TOGGLE</a>))</div> +<div class="line"><a name="l00303"></a><span class="lineno"> 303</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a75b4de2f2d23c3632056eb80c51a0857">ToggleNavlights</a>();</div> +<div class="line"><a name="l00304"></a><span class="lineno"> 304</span> </div> +<div class="line"><a name="l00305"></a><span class="lineno"> 305</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a863e99a4e4a8998237651e284797d327">KEY_LOCK_TARGET</a>))</div> +<div class="line"><a name="l00306"></a><span class="lineno"> 306</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#afe5d622c03d1d931ac346c2b0fcbf28f">LockTarget</a>(<a class="code" href="class_sim_object.html#a43f6bd6f43c6e7798b4f7ac729c53982a883a4c0d3bae3a294a55a710f8bd7cf4">SimObject::SIM_SHIP</a>, <span class="keyword">false</span>, <span class="keyword">true</span>);</div> +<div class="line"><a name="l00307"></a><span class="lineno"> 307</span> </div> +<div class="line"><a name="l00308"></a><span class="lineno"> 308</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a195590cff128598b87dac3cab77eedc3">KEY_LOCK_THREAT</a>))</div> +<div class="line"><a name="l00309"></a><span class="lineno"> 309</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#afe5d622c03d1d931ac346c2b0fcbf28f">LockTarget</a>(<a class="code" href="class_sim_object.html#a43f6bd6f43c6e7798b4f7ac729c53982ae13513f3708d04b53ead6fb2e85facad">SimObject::SIM_DRONE</a>);</div> +<div class="line"><a name="l00310"></a><span class="lineno"> 310</span> </div> +<div class="line"><a name="l00311"></a><span class="lineno"> 311</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#aca88c31353db12614f9f9bd8d62b6d80">KEY_LOCK_CLOSEST_SHIP</a>))</div> +<div class="line"><a name="l00312"></a><span class="lineno"> 312</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#afe5d622c03d1d931ac346c2b0fcbf28f">LockTarget</a>(<a class="code" href="class_sim_object.html#a43f6bd6f43c6e7798b4f7ac729c53982a883a4c0d3bae3a294a55a710f8bd7cf4">SimObject::SIM_SHIP</a>, <span class="keyword">true</span>, <span class="keyword">false</span>);</div> +<div class="line"><a name="l00313"></a><span class="lineno"> 313</span> </div> +<div class="line"><a name="l00314"></a><span class="lineno"> 314</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a7701881f4a8250a152c20859fa845fa5">KEY_LOCK_CLOSEST_THREAT</a>))</div> +<div class="line"><a name="l00315"></a><span class="lineno"> 315</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#afe5d622c03d1d931ac346c2b0fcbf28f">LockTarget</a>(<a class="code" href="class_sim_object.html#a43f6bd6f43c6e7798b4f7ac729c53982ae13513f3708d04b53ead6fb2e85facad">SimObject::SIM_DRONE</a>, <span class="keyword">true</span>, <span class="keyword">false</span>);</div> +<div class="line"><a name="l00316"></a><span class="lineno"> 316</span> </div> +<div class="line"><a name="l00317"></a><span class="lineno"> 317</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a2faaeb09ed849349c377c8030ccdc355">KEY_LOCK_HOSTILE_SHIP</a>))</div> +<div class="line"><a name="l00318"></a><span class="lineno"> 318</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#afe5d622c03d1d931ac346c2b0fcbf28f">LockTarget</a>(<a class="code" href="class_sim_object.html#a43f6bd6f43c6e7798b4f7ac729c53982a883a4c0d3bae3a294a55a710f8bd7cf4">SimObject::SIM_SHIP</a>, <span class="keyword">true</span>, <span class="keyword">true</span>);</div> +<div class="line"><a name="l00319"></a><span class="lineno"> 319</span> </div> +<div class="line"><a name="l00320"></a><span class="lineno"> 320</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#af8f0c918726848ec09e18cba0d7be566">KEY_LOCK_HOSTILE_THREAT</a>))</div> +<div class="line"><a name="l00321"></a><span class="lineno"> 321</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#afe5d622c03d1d931ac346c2b0fcbf28f">LockTarget</a>(<a class="code" href="class_sim_object.html#a43f6bd6f43c6e7798b4f7ac729c53982ae13513f3708d04b53ead6fb2e85facad">SimObject::SIM_DRONE</a>, <span class="keyword">true</span>, <span class="keyword">true</span>);</div> +<div class="line"><a name="l00322"></a><span class="lineno"> 322</span> </div> +<div class="line"><a name="l00323"></a><span class="lineno"> 323</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a44c24b8976a056d68e48c45e7779be2d">KEY_CYCLE_SUBTARGET</a>))</div> +<div class="line"><a name="l00324"></a><span class="lineno"> 324</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a6d5480665d1ffa5485dd24188e464040">CycleSubTarget</a>(1);</div> +<div class="line"><a name="l00325"></a><span class="lineno"> 325</span> </div> +<div class="line"><a name="l00326"></a><span class="lineno"> 326</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a92d16efe7d63784fe3d69a100c6d1c5b">KEY_PREV_SUBTARGET</a>))</div> +<div class="line"><a name="l00327"></a><span class="lineno"> 327</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#a6d5480665d1ffa5485dd24188e464040">CycleSubTarget</a>(-1);</div> +<div class="line"><a name="l00328"></a><span class="lineno"> 328</span> </div> +<div class="line"><a name="l00329"></a><span class="lineno"> 329</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#a915cb21e6bf6ad3541961d237055e527">KEY_AUTO_NAV</a>)) {</div> +<div class="line"><a name="l00330"></a><span class="lineno"> 330</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#accf7d20663ac99dca04f05209291ebeb">SetAutoNav</a>(<span class="keyword">true</span>);</div> +<div class="line"><a name="l00331"></a><span class="lineno"> 331</span>  <span class="comment">// careful: this object has just been deleted!</span></div> +<div class="line"><a name="l00332"></a><span class="lineno"> 332</span>  <span class="keywordflow">return</span>;</div> +<div class="line"><a name="l00333"></a><span class="lineno"> 333</span>  }</div> +<div class="line"><a name="l00334"></a><span class="lineno"> 334</span> </div> +<div class="line"><a name="l00335"></a><span class="lineno"> 335</span>  <span class="keywordflow">if</span> (<a class="code" href="class_ship_ctrl.html#a5aa230df011ac052bff463a5da9a4263">Toggled</a>(<a class="code" href="_key_map_8h.html#acafbdc20d4b90653c001dae57b0bbac0">KEY_DROP_ORBIT</a>)) {</div> +<div class="line"><a name="l00336"></a><span class="lineno"> 336</span>  <a class="code" href="class_ship_ctrl.html#a45ad117a2cf355c5ca106f50c5e4c753">ship</a>-><a class="code" href="class_ship.html#aed25682a3fdb42468724fdb4d7634dff">DropOrbit</a>();</div> +<div class="line"><a name="l00337"></a><span class="lineno"> 337</span>  <span class="comment">// careful: this object has just been deleted!</span></div> +<div class="line"><a name="l00338"></a><span class="lineno"> 338</span>  <span class="keywordflow">return</span>;</div> +<div class="line"><a name="l00339"></a><span class="lineno"> 339</span>  }</div> +<div class="line"><a name="l00340"></a><span class="lineno"> 340</span> }</div> +<div class="line"><a name="l00341"></a><span class="lineno"> 341</span> </div> +</div><!-- fragment --></div><!-- contents --> +</div><!-- doc-content --> +<!-- start footer part --> +<div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> + <ul> + <li class="navelem"><a class="el" href="dir_ea1b58c809a5070716d7c602998a95b0.html">Stars45</a></li><li class="navelem"><a class="el" href="_ship_ctrl_8cpp.html">ShipCtrl.cpp</a></li> + <li class="footer">Generated on Thu May 31 2012 16:31:15 for Starshatter_Open by + <a href="http://www.doxygen.org/index.html"> + <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.1 </li> + </ul> +</div> +</body> +</html> |