bitburner-src/doc/build/html/netscriptadvancedfunctions.html

173 lines
9.5 KiB
HTML
Raw Normal View History

<!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" lang="English">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Netscript Advanced Functions &#8212; Bitburner 1.0 documentation</title>
<link rel="stylesheet" href="_static/agogo.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '1.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="Netscript Hacknet Node API" href="netscripthacknetnodeapi.html" />
<link rel="prev" title="Netscript Basic Functions" href="netscriptfunctions.html" />
</head>
<body>
<div class="header-wrapper" role="banner">
<div class="header">
<div class="headertitle"><a
href="index.html">Bitburner 1.0 documentation</a></div>
<div class="rel" role="navigation" aria-label="related navigation">
<a href="netscriptfunctions.html" title="Netscript Basic Functions"
accesskey="P">previous</a> |
<a href="netscripthacknetnodeapi.html" title="Netscript Hacknet Node API"
accesskey="N">next</a> |
<a href="genindex.html" title="General Index"
accesskey="I">index</a>
</div>
</div>
</div>
<div class="content-wrapper">
<div class="content">
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<div class="section" id="netscript-advanced-functions">
<h1>Netscript Advanced Functions<a class="headerlink" href="#netscript-advanced-functions" title="Permalink to this headline"></a></h1>
<p>These Netscript functions become relevant later on in the game. They are put on a separate page because
they contain spoilers for the game.</p>
<div class="section" id="getbitnodemultipliers">
<h2>getBitNodeMultipliers<a class="headerlink" href="#getbitnodemultipliers" title="Permalink to this headline"></a></h2>
<dl class="function">
<dt id="getBitNodeMultipliers">
<code class="descname">getBitNodeMultipliers</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#getBitNodeMultipliers" title="Permalink to this definition"></a></dt>
<dd><p>Returns an object containing the current BitNode multipliers. This function requires Source-File 5 in order
to run. The multipliers are returned in integer forms (e.g. 1.5 instead of 150%). The multipliers represent
the difference between the current BitNode and the original BitNode (BitNode-1). For example, if the
<em>CrimeMoney</em> multiplier has a value of 0.1, then that means that committing crimes in the current BitNode
will only give 10% of the money you would have received in BitNode-1. The object has the following structure,
(subject to change in the future):</p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="p">{</span>
<span class="n">ServerMaxMoney</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">ServerStartingMoney</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">ServerGrowthRate</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">ServerWeakenRate</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">ServerStartingSecurity</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">ManualHackMoney</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">ScriptHackMoney</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">CompanyWorkMoney</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">CrimeMoney</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">HacknetNodeMoney</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">CompanyWorkExpGain</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">ClassGymExpGain</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">FactionWorkExpGain</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">HackExpGain</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">CrimeExpGain</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">FactionWorkRepGain</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">FactionPassiveRepGain</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">AugmentationRepCost</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="n">AugmentationMoneyCost</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span>
<span class="p">}</span>
</pre></div>
</div>
<p>Example:</p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">mults</span> <span class="o">=</span> <span class="n">getBitNodeMultipliers</span><span class="p">();</span>
<span class="nb">print</span><span class="p">(</span><span class="n">mults</span><span class="o">.</span><span class="n">ServerMaxMoney</span><span class="p">);</span>
<span class="nb">print</span><span class="p">(</span><span class="n">mults</span><span class="o">.</span><span class="n">HackExpGain</span><span class="p">);</span>
</pre></div>
</div>
</dd></dl>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="sidebar">
<h3>Table Of Contents</h3>
<p class="caption"><span class="caption-text">Contents:</span></p>
<ul class="current">
<li class="toctree-l1 current"><a class="reference internal" href="netscript.html"> Netscript</a><ul class="current">
<li class="toctree-l2"><a class="reference internal" href="netscriptdatatypes.html"> Data Types and Variables</a></li>
<li class="toctree-l2"><a class="reference internal" href="netscriptoperators.html"> Operators</a></li>
<li class="toctree-l2"><a class="reference internal" href="netscriptloopsandconditionals.html"> Loops and Conditionals</a></li>
<li class="toctree-l2"><a class="reference internal" href="netscriptscriptarguments.html"> Script Arguments</a></li>
<li class="toctree-l2"><a class="reference internal" href="netscriptfunctions.html"> Basic Functions</a></li>
<li class="toctree-l2 current"><a class="current reference internal" href="#"> Advanced Functions</a><ul>
<li class="toctree-l3"><a class="reference internal" href="#getbitnodemultipliers">getBitNodeMultipliers</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="netscripthacknetnodeapi.html"> Hacknet Node API</a></li>
<li class="toctree-l2"><a class="reference internal" href="netscriptixapi.html"> Trade Information eXchange (TIX) API</a></li>
<li class="toctree-l2"><a class="reference internal" href="netscriptsingularityfunctions.html"> Singularity Functions</a></li>
</ul>
</li>
</ul>
<div role="search">
<h3 style="margin-top: 1.5em;">Search</h3>
<form class="search" action="search.html" method="get">
<input type="text" name="q" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="clearer"></div>
</div>
</div>
<div class="footer-wrapper">
<div class="footer">
<div class="left">
<div role="navigation" aria-label="related navigaton">
<a href="netscriptfunctions.html" title="Netscript Basic Functions"
>previous</a> |
<a href="netscripthacknetnodeapi.html" title="Netscript Hacknet Node API"
>next</a> |
<a href="genindex.html" title="General Index"
>index</a>
</div>
<div role="note" aria-label="source link">
<br/>
<a href="_sources/netscriptadvancedfunctions.rst.txt"
rel="nofollow">Show Source</a>
</div>
</div>
<div class="right">
<div class="footer" role="contentinfo">
&#169; Copyright 2017, Bitburner.
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.6.4.
</div>
</div>
<div class="clearer"></div>
</div>
</div>
</body>
</html>