GameApi 28
Library used by GameApi Builder tool
Loading...
Searching...
No Matches
test.cpp File Reference
#include "GameApi.hh"
#include "Tasks.hh"
#include <sstream>
#include <fstream>
#include <cmath>
#include <pthread.h>
Include dependency graph for test.cpp:

Classes

struct  Envi

Functions

Low_SDL_Surface * InitSDL2 (int scr_x, int scr_y, bool vblank, bool antialias, bool resize, bool vr_init)
void splitter_iter2 (void *arg)
void onload (unsigned int, void *, const char *var)
void onerror (unsigned int, void *, int)
void onprogress (unsigned int, void *, int)
bool find_string (std::string s, std::string s2)
std::string hexify5 (std::string s)
std::string strip_spaces (std::string data)
std::pair< int, std::string > mainloop (Env &e2, EveryApi &ev)
std::string decode (std::string s)
std::string insert_enter (std::string s)
bool check_count (std::vector< std::string > cmd_args, int current_arg, int count)
void set_status (int val, int val_max)
IMPORT void initialize_low (int flags)
IMPORT std::string replace_str (std::string s, std::string repl, std::string subst)
IMPORT void ClearProgress ()
IMPORT const char * get_html_directory2 ()
int main (int argc, char *argv[])

Variables

std::vector< std::string > screenshot_filenames
std::vector< float > screenshot_times
std::vector< bool > screenshot_done
std::string code
std::string homepageurl = ""
int call_count =0
IMPORT bool g_transparent
IMPORT int g_event_screen_x
IMPORT int g_event_screen_y
IMPORT std::string g_platform
IMPORT bool g_deploy_phase
IMPORT std::string g_window_href
IMPORT GameApi::EveryApi * g_everyapi = 0
IMPORT pthread_t g_main_thread_id
IMPORT Low_SDL_Window * sdl_window
IMPORT int sprite_screen_width
IMPORT int sprite_screen_height
IMPORT std::string g_store_directory
IMPORT const char * g_html_dir

Function Documentation

◆ check_count()

bool check_count ( std::vector< std::string > cmd_args,
int current_arg,
int count )
Here is the caller graph for this function:

◆ ClearProgress()

IMPORT void ClearProgress ( )
Here is the caller graph for this function:

◆ decode()

std::string decode ( std::string s)
Here is the caller graph for this function:

◆ find_string()

bool find_string ( std::string s,
std::string s2 )
Here is the caller graph for this function:

◆ get_html_directory2()

IMPORT const char * get_html_directory2 ( )
Here is the caller graph for this function:

◆ hexify5()

std::string hexify5 ( std::string s)

◆ initialize_low()

IMPORT void initialize_low ( int flags)
Here is the caller graph for this function:

◆ InitSDL2()

Low_SDL_Surface * InitSDL2 ( int scr_x,
int scr_y,
bool vblank,
bool antialias,
bool resize,
bool vr_init )
Here is the caller graph for this function:

◆ insert_enter()

std::string insert_enter ( std::string s)
Here is the caller graph for this function:

◆ main()

int main ( int argc,
char * argv[] )

◆ mainloop()

std::pair< int, std::string > mainloop ( Env & e2,
EveryApi & ev )
Here is the caller graph for this function:

◆ onerror()

void onerror ( unsigned int ,
void * ,
int  )

◆ onload()

void onload ( unsigned int ,
void * ,
const char * var )

◆ onprogress()

void onprogress ( unsigned int ,
void * ,
int  )

◆ replace_str()

IMPORT std::string replace_str ( std::string s,
std::string repl,
std::string subst )
Here is the caller graph for this function:

◆ set_status()

void set_status ( int val,
int val_max )
Here is the caller graph for this function:

◆ splitter_iter2()

void splitter_iter2 ( void * arg)
Here is the caller graph for this function:

◆ strip_spaces()

std::string strip_spaces ( std::string data)
Here is the caller graph for this function:

Variable Documentation

◆ call_count

int call_count =0

◆ code

std::string code
Initial value:
=
"BM I1=ev.bitmap_api.chessboard(20,20,8,8,ffffffff,ff880088);\n"
"FB I2=ev.float_bitmap_api.from_green(I1);\n"
"S I3=ev.polygon_api.s_spherical(0,0,0,I2,300,310,0,1);\n"
"BM I4=ev.bitmap_api.loadbitmapfromurl(http://tpgames.org/map.jpg);\n"
"BM I5=ev.bitmap_api.rot90(I4);\n"
"S I6=ev.surface_api.texture(I3,I5);\n"
"P I7=ev.polygon_api.s_sample(I6,200,200);\n"
"MT I8=ev.materials_api.def(ev);\n"
"MT I9=ev.materials_api.web(ev,I8,1.03,2.0,ff000000);\n"
"ML I10=ev.materials_api.bind(I7,I9);\n"
"MN I11=ev.move_api.empty();\n"
"MN I12=ev.move_api.rotatex(I11,3.141);\n"
"MN I13=ev.move_api.rotate(I12,0,10000,0,0,0,0,0,1,628);\n"
"MN I14=ev.move_api.rotatex(I13,2.5);\n"
"ML I15=ev.move_api.move_ml(ev,I10,I14,1,10.0);\n"
"ML I16=ev.mainloop_api.touch_rotate(ev,I15,true,true,0.01,0.01);\n"
"RUN I17=ev.blocker_api.game_window2(ev,I16,false,false,0.0,100000.0);\n"

◆ g_deploy_phase

IMPORT bool g_deploy_phase
extern

◆ g_event_screen_x

IMPORT int g_event_screen_x
extern

◆ g_event_screen_y

IMPORT int g_event_screen_y
extern

◆ g_everyapi

GameApi::EveryApi * g_everyapi = 0
extern

◆ g_html_dir

IMPORT const char* g_html_dir
extern

◆ g_main_thread_id

IMPORT pthread_t g_main_thread_id
extern

◆ g_platform

IMPORT std::string g_platform
extern

◆ g_store_directory

IMPORT std::string g_store_directory
extern

◆ g_transparent

IMPORT bool g_transparent
extern

◆ g_window_href

std::string g_window_href
extern

◆ homepageurl

std::string homepageurl = ""

◆ screenshot_done

std::vector<bool> screenshot_done

◆ screenshot_filenames

std::vector<std::string> screenshot_filenames

◆ screenshot_times

std::vector<float> screenshot_times

◆ sdl_window

Low_SDL_Window * sdl_window
extern

◆ sprite_screen_height

IMPORT int sprite_screen_height
extern

◆ sprite_screen_width

IMPORT int sprite_screen_width
extern