Galactic Bloodshed
Functions | Variables
fuel.cc File Reference
#include "gb/fuel.h"
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include "gb/GB_server.h"
#include "gb/doship.h"
#include "gb/files_shl.h"
#include "gb/fire.h"
#include "gb/getplace.h"
#include "gb/max.h"
#include "gb/moveship.h"
#include "gb/order.h"
#include "gb/ships.h"
#include "gb/shlmisc.h"
#include "gb/tweakables.h"
#include "gb/vars.h"
Include dependency graph for fuel.cc:

Go to the source code of this file.

Functions

static int do_trip (const placetype &, double fuel, double gravity_factor)
 
static void fuel_output (int Playernum, int Governor, double dist, double fuel, double grav, double mass, segments_t segs)
 
void proj_fuel (const command_t &argv, GameObj &g)
 

Variables

static char plan_buf [1024]
 
static segments_t number_segments
 
static double x_0
 
static double y_0
 
static double x_1
 
static double y_1
 
static Shiptmpship
 

Function Documentation

◆ do_trip()

static int do_trip ( const placetype tmpdest,
double  fuel,
double  gravity_factor 
)
static

Definition at line 245 of file fuel.cc.

References domass(), moveship(), number_segments, Numships(), tmpship, x_0, x_1, y_0, and y_1.

Referenced by proj_fuel().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fuel_output()

static void fuel_output ( int  Playernum,
int  Governor,
double  dist,
double  fuel,
double  grav,
double  mass,
segments_t  segs 
)
static

Definition at line 215 of file fuel.cc.

References plan_buf.

Referenced by proj_fuel().

Here is the caller graph for this function:

◆ proj_fuel()

void proj_fuel ( const command_t argv,
GameObj g 
)

Definition at line 38 of file fuel.cc.

References do_trip(), domass(), fuel_output(), getplanet(), number_segments, tmpship, x_0, x_1, y_0, and y_1.

Here is the call graph for this function:

Variable Documentation

◆ number_segments

segments_t number_segments
static

Definition at line 30 of file fuel.cc.

Referenced by do_trip(), and proj_fuel().

◆ plan_buf

char plan_buf[1024]
static

Definition at line 28 of file fuel.cc.

Referenced by fuel_output().

◆ tmpship

Ship* tmpship
static

Definition at line 32 of file fuel.cc.

Referenced by do_trip(), and proj_fuel().

◆ x_0

double x_0
static

Definition at line 31 of file fuel.cc.

Referenced by do_trip(), and proj_fuel().

◆ x_1

double x_1
static

Definition at line 31 of file fuel.cc.

Referenced by do_trip(), and proj_fuel().

◆ y_0

double y_0
static

Definition at line 31 of file fuel.cc.

Referenced by do_trip(), and proj_fuel().

◆ y_1

double y_1
static

Definition at line 31 of file fuel.cc.

Referenced by do_trip(), and proj_fuel().