- Fixed console bug when toggled in editor mode and restored previous functionality

- Updated nuklear to version 4.00.2
- Fixed other formating mistakes
dev
Shariq Shah 7 years ago
parent 7339ad6834
commit 6980186a4b
  1. 10
      README.md
  2. 29689
      include/common/nuklear.h
  3. 33
      src/libsymmetry/console.c
  4. 95
      src/libsymmetry/editor.c
  5. 572
      src/libsymmetry/game.c
  6. 5
      todo.txt

@ -42,6 +42,13 @@ This will generate a visual studio 2017 solution in the *build/vs2017* folder wh
make all make all
``` ```
This will build the debug configuration by default and it's output will be in *build/gmake/debug* folder. You can then run the game by,
```bash
cd debug
./Symmetry
```
## License ## License
All the code in this repository is under GPLv3, see LICENSE for more information All the code in this repository is under GPLv3, see LICENSE for more information
@ -127,6 +134,9 @@ All the code in this repository is under GPLv3, see LICENSE for more information
variant value like, health or ammo etc. But, how to save/load all of that? variant value like, health or ammo etc. But, how to save/load all of that?
- ### Materials - ### Materials
*TODO* *TODO*
- ### Mesh/Geometry - ### Mesh/Geometry
*TODO* *TODO*

File diff suppressed because it is too large Load Diff

@ -69,7 +69,6 @@ void console_update(struct Console* console, struct Gui_State* gui_state, float
*context->current->layout->offset_y = (nk_uint)context->current->layout->at_y; *context->current->layout->offset_y = (nk_uint)context->current->layout->at_y;
console->scroll_to_bottom = false; console->scroll_to_bottom = false;
} }
nk_group_end(context); nk_group_end(context);
} }
@ -108,28 +107,28 @@ int console_filter(const struct nk_text_edit *box, nk_rune unicode)
void console_on_log_message(struct Console* console, const char* message, va_list args) void console_on_log_message(struct Console* console, const char* message, va_list args)
{ {
/* if(++console->current_message_index >= MAX_CONSOLE_MESSAGES) */ if(++console->current_message_index >= MAX_CONSOLE_MESSAGES)
/* console->current_message_index = 0; */ console->current_message_index = 0;
/* vsnprintf(console->console_messages[console->current_message_index].message, MAX_CONSOLE_MESSAGE_LEN, message, args); */ vsnprintf(console->console_messages[console->current_message_index].message, MAX_CONSOLE_MESSAGE_LEN, message, args);
/* console->console_messages[console->current_message_index].type = CMT_MESSAGE; */ console->console_messages[console->current_message_index].type = CMT_MESSAGE;
/* console->scroll_to_bottom = true; */ console->scroll_to_bottom = true;
} }
void console_on_log_warning(struct Console* console, const char* warning_message, va_list args) void console_on_log_warning(struct Console* console, const char* warning_message, va_list args)
{ {
/* if(++console->current_message_index >= MAX_CONSOLE_MESSAGES) */ if(++console->current_message_index >= MAX_CONSOLE_MESSAGES)
/* console->current_message_index = 0; */ console->current_message_index = 0;
/* vsnprintf(console->console_messages[console->current_message_index].message, MAX_CONSOLE_MESSAGE_LEN, warning_message, args); */ vsnprintf(console->console_messages[console->current_message_index].message, MAX_CONSOLE_MESSAGE_LEN, warning_message, args);
/* console->console_messages[console->current_message_index].type = CMT_WARNING; */ console->console_messages[console->current_message_index].type = CMT_WARNING;
/* console->scroll_to_bottom = true; */ console->scroll_to_bottom = true;
} }
void console_on_log_error(struct Console* console, const char* context, const char* error, va_list args) void console_on_log_error(struct Console* console, const char* context, const char* error, va_list args)
{ {
/* if(++console->current_message_index >= MAX_CONSOLE_MESSAGES) */ if(++console->current_message_index >= MAX_CONSOLE_MESSAGES)
/* console->current_message_index = 0; */ console->current_message_index = 0;
/* int loc = snprintf(console->console_messages[console->current_message_index].message, MAX_CONSOLE_MESSAGE_LEN, "(%s)", context); */ int loc = snprintf(console->console_messages[console->current_message_index].message, MAX_CONSOLE_MESSAGE_LEN, "(%s)", context);
/* vsnprintf(console->console_messages[console->current_message_index].message + loc, MAX_CONSOLE_MESSAGE_LEN - loc, error, args); */ vsnprintf(console->console_messages[console->current_message_index].message + loc, MAX_CONSOLE_MESSAGE_LEN - loc, error, args);
/* console->console_messages[console->current_message_index].type = CMT_ERROR; */ console->console_messages[console->current_message_index].type = CMT_ERROR;
/* console->scroll_to_bottom = true; */ console->scroll_to_bottom = true;
} }

@ -199,11 +199,12 @@ void editor_update(float dt)
if(nk_begin(context, "Editor", nk_recti(0, 0, win_width, win_height), NK_WINDOW_NO_SCROLLBAR | NK_WINDOW_BACKGROUND)) if(nk_begin(context, "Editor", nk_recti(0, 0, win_width, win_height), NK_WINDOW_NO_SCROLLBAR | NK_WINDOW_BACKGROUND))
{ {
context->style.window.fixed_background = default_background; context->style.window.fixed_background = default_background;
/* Top Panel */ /* Top Panel */
nk_layout_row_dynamic(context, editor_state.top_panel_height + 10.f, 1); nk_layout_row_dynamic(context, editor_state.top_panel_height + 10.f, 1);
nk_group_begin(context, "Menubar", NK_WINDOW_NO_SCROLLBAR); nk_group_begin(context, "Menubar", NK_WINDOW_NO_SCROLLBAR);
{ {
static float top_panel_ratios[] = {0.1f, 0.1f, 0.7f, 0.1f}; static float top_panel_ratios[] = { 0.1f, 0.1f, 0.7f, 0.1f };
static int frames = 0; static int frames = 0;
static int fps = 0; static int fps = 0;
static float seconds = 0.f; static float seconds = 0.f;
@ -220,13 +221,13 @@ void editor_update(float dt)
if(nk_button_label(context, "Render Settings")) if(nk_button_label(context, "Render Settings"))
editor_state.renderer_settings_window = !editor_state.renderer_settings_window; editor_state.renderer_settings_window = !editor_state.renderer_settings_window;
if(nk_button_label(context, "Save config")) if(nk_button_label(context, "Save config"))
platform->config.save("config.cfg", DIRT_USER); platform->config.save("config.symtres", DIRT_USER);
nk_spacing(context, 1); nk_spacing(context, 1);
nk_labelf(context, NK_TEXT_ALIGN_RIGHT | NK_TEXT_ALIGN_MIDDLE, "FPS : %.d", fps); nk_labelf(context, NK_TEXT_ALIGN_RIGHT | NK_TEXT_ALIGN_MIDDLE, "FPS : %.d", fps);
nk_group_end(context);
} }
nk_group_end(context);
static float main_editor_ratios[] = {0.2f, 0.6f, 0.2f}; static float main_editor_ratios[] = { 0.2f, 0.6f, 0.2f };
nk_layout_row(context, NK_DYNAMIC, win_height - editor_state.top_panel_height, sizeof(main_editor_ratios) / sizeof(float), main_editor_ratios); nk_layout_row(context, NK_DYNAMIC, win_height - editor_state.top_panel_height, sizeof(main_editor_ratios) / sizeof(float), main_editor_ratios);
/* Left */ /* Left */
if(nk_group_begin(context, "Editor Left", NK_WINDOW_SCROLL_AUTO_HIDE)) if(nk_group_begin(context, "Editor Left", NK_WINDOW_SCROLL_AUTO_HIDE))
@ -252,7 +253,7 @@ void editor_update(float dt)
/* Debug Variables */ /* Debug Variables */
if(nk_tree_push(context, NK_TREE_TAB, "Debug Variables", NK_MAXIMIZED)) if(nk_tree_push(context, NK_TREE_TAB, "Debug Variables", NK_MAXIMIZED))
{ {
static char variant_str[MAX_VARIANT_STR_LEN] = {'\0'}; static char variant_str[MAX_VARIANT_STR_LEN] = { '\0' };
nk_layout_row_dynamic(context, 250, 1); nk_layout_row_dynamic(context, 250, 1);
if(nk_group_begin(context, "Name", NK_WINDOW_SCROLL_AUTO_HIDE)) if(nk_group_begin(context, "Name", NK_WINDOW_SCROLL_AUTO_HIDE))
{ {
@ -299,29 +300,29 @@ void editor_update(float dt)
/* Transform */ /* Transform */
{ {
nk_layout_row_dynamic(context, row_height, 1); nk_label(context, "Position", NK_TEXT_ALIGN_CENTERED); nk_layout_row_dynamic(context, row_height, 1); nk_label(context, "Position", NK_TEXT_ALIGN_CENTERED);
vec3 abs_pos = {0.f, 0.f, 0.f}; vec3 abs_pos = { 0.f, 0.f, 0.f };
transform_get_absolute_position(entity, &abs_pos); transform_get_absolute_position(entity, &abs_pos);
if(editor_widget_v3(context, &abs_pos, "Px", "Py", "Pz", -FLT_MAX, FLT_MAX, 5.f, 1.f, row_height)) transform_set_position(entity, &abs_pos); if(editor_widget_v3(context, &abs_pos, "#X", "#Y", "#Z", -FLT_MAX, FLT_MAX, 5.f, 1.f, row_height)) transform_set_position(entity, &abs_pos);
nk_layout_row_dynamic(context, row_height, 1); nk_label(context, "Rotation", NK_TEXT_ALIGN_CENTERED); nk_layout_row_dynamic(context, row_height, 1); nk_label(context, "Rotation", NK_TEXT_ALIGN_CENTERED);
quat abs_rot = {0.f, 0.f, 0.f, 1.f}; quat abs_rot = { 0.f, 0.f, 0.f, 1.f };
transform_get_absolute_rot(entity, &abs_rot); transform_get_absolute_rot(entity, &abs_rot);
vec3 rot_angles = {0.f, 0.f, 0.f}; vec3 rot_angles = { 0.f, 0.f, 0.f };
rot_angles.x = TO_DEGREES(quat_get_pitch(&abs_rot)); rot_angles.x = TO_DEGREES(quat_get_pitch(&abs_rot));
rot_angles.y = TO_DEGREES(quat_get_yaw(&abs_rot)); rot_angles.y = TO_DEGREES(quat_get_yaw(&abs_rot));
rot_angles.z = TO_DEGREES(quat_get_roll(&abs_rot)); rot_angles.z = TO_DEGREES(quat_get_roll(&abs_rot));
vec3 curr_rot = {rot_angles.x, rot_angles.y, rot_angles.z}; vec3 curr_rot = { rot_angles.x, rot_angles.y, rot_angles.z };
nk_layout_row_dynamic(context, row_height, 1); nk_property_float(context, "Rx", -FLT_MAX, &curr_rot.x, FLT_MAX, 5.f, 1.f); nk_layout_row_dynamic(context, row_height, 1); nk_property_float(context, "#X", -FLT_MAX, &curr_rot.x, FLT_MAX, 5.f, 1.f);
nk_layout_row_dynamic(context, row_height, 1); nk_property_float(context, "Ry", -FLT_MAX, &curr_rot.y, FLT_MAX, 5.f, 1.f); nk_layout_row_dynamic(context, row_height, 1); nk_property_float(context, "#Y", -FLT_MAX, &curr_rot.y, FLT_MAX, 5.f, 1.f);
nk_layout_row_dynamic(context, row_height, 1); nk_property_float(context, "Rz", -FLT_MAX, &curr_rot.z, FLT_MAX, 5.f, 1.f); nk_layout_row_dynamic(context, row_height, 1); nk_property_float(context, "#Z", -FLT_MAX, &curr_rot.z, FLT_MAX, 5.f, 1.f);
vec3 delta = {0.f, 0.f, 0.f}; vec3 delta = { 0.f, 0.f, 0.f };
vec3_sub(&delta, &rot_angles, &curr_rot); vec3_sub(&delta, &rot_angles, &curr_rot);
vec3 AXIS_X = {1.f, 0.f, 0.f}; vec3 AXIS_X = { 1.f, 0.f, 0.f };
vec3 AXIS_Y = {0.f, 1.f, 0.f}; vec3 AXIS_Y = { 0.f, 1.f, 0.f };
vec3 AXIS_Z = {0.f, 0.f, 1.f}; vec3 AXIS_Z = { 0.f, 0.f, 1.f };
const float epsilon = 0.0001f; const float epsilon = 0.0001f;
if(fabsf(delta.x) > epsilon) transform_rotate(entity, &AXIS_X, delta.x, TS_WORLD); if(fabsf(delta.x) > epsilon) transform_rotate(entity, &AXIS_X, delta.x, TS_WORLD);
@ -329,9 +330,9 @@ void editor_update(float dt)
if(fabsf(delta.z) > epsilon) transform_rotate(entity, &AXIS_Z, delta.z, TS_WORLD); if(fabsf(delta.z) > epsilon) transform_rotate(entity, &AXIS_Z, delta.z, TS_WORLD);
nk_layout_row_dynamic(context, row_height, 1); nk_label(context, "Scale", NK_TEXT_ALIGN_CENTERED); nk_layout_row_dynamic(context, row_height, 1); nk_label(context, "Scale", NK_TEXT_ALIGN_CENTERED);
vec3 abs_scale = {0.f, 0.f, 0.f}; vec3 abs_scale = { 0.f, 0.f, 0.f };
transform_get_absolute_scale(entity, &abs_scale); transform_get_absolute_scale(entity, &abs_scale);
if(editor_widget_v3(context, &abs_scale, "SX", "SY", "SZ", 0.1f, FLT_MAX, 1.f, 0.1f, row_height)) if(editor_widget_v3(context, &abs_scale, "#X", "#Y", "#Z", 0.1f, FLT_MAX, 1.f, 0.1f, row_height))
{ {
entity->transform.scale = abs_scale; entity->transform.scale = abs_scale;
transform_update_transmat(entity); transform_update_transmat(entity);
@ -351,7 +352,7 @@ void editor_update(float dt)
} }
else else
{ {
static const char* light_types[] = {"Spot", "Directional", "Point"}; static const char* light_types[] = { "Spot", "Directional", "Point" };
float combo_width = nk_widget_width(context), combo_height = row_height * (LT_MAX); float combo_width = nk_widget_width(context), combo_height = row_height * (LT_MAX);
nk_layout_row_dynamic(context, row_height, 2); nk_layout_row_dynamic(context, row_height, 2);
@ -475,7 +476,7 @@ void editor_update(float dt)
struct Render_Settings* render_settings = &game_state->renderer->settings; struct Render_Settings* render_settings = &game_state->renderer->settings;
if(nk_tree_push(context, NK_TREE_TAB, "Debug", NK_MAXIMIZED)) if(nk_tree_push(context, NK_TREE_TAB, "Debug", NK_MAXIMIZED))
{ {
static const char* draw_modes[] = {"Triangles", "Lines", "Points"}; static const char* draw_modes[] = { "Triangles", "Lines", "Points" };
nk_layout_row_dynamic(context, row_height, 2); nk_layout_row_dynamic(context, row_height, 2);
nk_label(context, "Debug Draw", NK_TEXT_ALIGN_LEFT | NK_TEXT_ALIGN_MIDDLE); nk_label(context, "Debug Draw", NK_TEXT_ALIGN_LEFT | NK_TEXT_ALIGN_MIDDLE);
nk_checkbox_label(context, "", &render_settings->debug_draw_enabled); nk_checkbox_label(context, "", &render_settings->debug_draw_enabled);
@ -492,7 +493,7 @@ void editor_update(float dt)
if(nk_tree_push(context, NK_TREE_TAB, "Fog", NK_MAXIMIZED)) if(nk_tree_push(context, NK_TREE_TAB, "Fog", NK_MAXIMIZED))
{ {
static const char* fog_modes[] = {"None", "Linear", "Exponential", "Exponential Squared"}; static const char* fog_modes[] = { "None", "Linear", "Exponential", "Exponential Squared" };
nk_layout_row_dynamic(context, row_height, 2); nk_layout_row_dynamic(context, row_height, 2);
nk_label(context, "Color", NK_TEXT_ALIGN_LEFT | NK_TEXT_ALIGN_MIDDLE); nk_label(context, "Color", NK_TEXT_ALIGN_LEFT | NK_TEXT_ALIGN_MIDDLE);
editor_widget_color_combov3(context, &render_settings->fog.color, 200, 400); editor_widget_color_combov3(context, &render_settings->fog.color, 200, 400);
@ -550,14 +551,14 @@ void editor_update(float dt)
void editor_camera_update(float dt) void editor_camera_update(float dt)
{ {
struct Camera* editor_camera = &game_state_get()->scene->cameras[CAM_EDITOR]; struct Camera* editor_camera = &game_state_get()->scene->cameras[CAM_EDITOR];
static float total_up_down_rot = 0.f;
float move_speed = editor_state.camera_move_speed, turn_speed = editor_state.camera_turn_speed; float move_speed = editor_state.camera_move_speed, turn_speed = editor_state.camera_turn_speed;
vec3 offset = {0, 0, 0};
float turn_up_down = 0.f; float turn_up_down = 0.f;
float turn_left_right = 0.f; float turn_left_right = 0.f;
float max_up_down = 60.f; float max_up_down = 60.f;
static float total_up_down_rot = 0.f; vec3 offset = { 0, 0, 0 };
vec3 rot_axis_up_down = {1, 0, 0}; vec3 rot_axis_up_down = { 1, 0, 0 };
vec3 rot_axis_left_right = {0, 1, 0}; vec3 rot_axis_left_right = { 0, 1, 0 };
/* Look around */ /* Look around */
if(input_map_state_get("Turn_Up", KS_PRESSED)) turn_up_down += turn_speed; if(input_map_state_get("Turn_Up", KS_PRESSED)) turn_up_down += turn_speed;
@ -662,27 +663,30 @@ void editor_widget_color_combov3(struct nk_context* context, vec3* color, int wi
struct nk_color temp_color = nk_rgba_f(color->x, color->y, color->z, 1.f); struct nk_color temp_color = nk_rgba_f(color->x, color->y, color->z, 1.f);
if(nk_combo_begin_color(context, temp_color, nk_vec2(width, height))) if(nk_combo_begin_color(context, temp_color, nk_vec2(width, height)))
{ {
enum color_mode {COL_RGB, COL_HSV}; enum color_mode { COL_RGB, COL_HSV };
static int col_mode = COL_RGB; static int col_mode = COL_RGB;
nk_layout_row_dynamic(context, 25, 2); nk_layout_row_dynamic(context, 25, 2);
col_mode = nk_option_label(context, "RGB", col_mode == COL_RGB) ? COL_RGB : col_mode; col_mode = nk_option_label(context, "RGB", col_mode == COL_RGB) ? COL_RGB : col_mode;
col_mode = nk_option_label(context, "HSV", col_mode == COL_HSV) ? COL_HSV : col_mode; col_mode = nk_option_label(context, "HSV", col_mode == COL_HSV) ? COL_HSV : col_mode;
nk_layout_row_dynamic(context, 120, 1); nk_layout_row_dynamic(context, 120, 1);
temp_color = nk_color_picker(context, temp_color, NK_RGB); struct nk_colorf temp_colorf = nk_color_cf(temp_color);
temp_colorf = nk_color_picker(context, temp_colorf, NK_RGB);
temp_color = nk_rgba_cf(temp_colorf);
nk_layout_row_dynamic(context, 25, 1); nk_layout_row_dynamic(context, 25, 1);
if(col_mode == COL_RGB) if(col_mode == COL_RGB)
{ {
temp_color.r = (nk_byte)nk_propertyi(context, "#R:", 0, temp_color.r, 255, 1,1); temp_color.r = (nk_byte)nk_propertyi(context, "#R:", 0, temp_color.r, 255, 1, 1);
temp_color.g = (nk_byte)nk_propertyi(context, "#G:", 0, temp_color.g, 255, 1,1); temp_color.g = (nk_byte)nk_propertyi(context, "#G:", 0, temp_color.g, 255, 1, 1);
temp_color.b = (nk_byte)nk_propertyi(context, "#B:", 0, temp_color.b, 255, 1,1); temp_color.b = (nk_byte)nk_propertyi(context, "#B:", 0, temp_color.b, 255, 1, 1);
} }
else else
{ {
nk_byte tmp[4]; nk_byte tmp[4];
nk_color_hsva_bv(tmp, temp_color); nk_color_hsva_bv(tmp, temp_color);
tmp[0] = (nk_byte)nk_propertyi(context, "#H:", 0, tmp[0], 255, 1,1); tmp[0] = (nk_byte)nk_propertyi(context, "#H:", 0, tmp[0], 255, 1, 1);
tmp[1] = (nk_byte)nk_propertyi(context, "#S:", 0, tmp[1], 255, 1,1); tmp[1] = (nk_byte)nk_propertyi(context, "#S:", 0, tmp[1], 255, 1, 1);
tmp[2] = (nk_byte)nk_propertyi(context, "#V:", 0, tmp[2], 255, 1,1); tmp[2] = (nk_byte)nk_propertyi(context, "#V:", 0, tmp[2], 255, 1, 1);
temp_color = nk_hsva_bv(tmp); temp_color = nk_hsva_bv(tmp);
} }
float empty = 1.f; float empty = 1.f;
@ -696,29 +700,32 @@ void editor_widget_color_combov4(struct nk_context* context, vec4* color, int wi
struct nk_color temp_color = nk_rgba_f(color->x, color->y, color->z, color->w); struct nk_color temp_color = nk_rgba_f(color->x, color->y, color->z, color->w);
if(nk_combo_begin_color(context, temp_color, nk_vec2(width, height))) if(nk_combo_begin_color(context, temp_color, nk_vec2(width, height)))
{ {
enum color_mode {COL_RGB, COL_HSV}; enum color_mode { COL_RGB, COL_HSV };
static int col_mode = COL_RGB; static int col_mode = COL_RGB;
nk_layout_row_dynamic(context, 25, 2); nk_layout_row_dynamic(context, 25, 2);
col_mode = nk_option_label(context, "RGB", col_mode == COL_RGB) ? COL_RGB : col_mode; col_mode = nk_option_label(context, "RGB", col_mode == COL_RGB) ? COL_RGB : col_mode;
col_mode = nk_option_label(context, "HSV", col_mode == COL_HSV) ? COL_HSV : col_mode; col_mode = nk_option_label(context, "HSV", col_mode == COL_HSV) ? COL_HSV : col_mode;
nk_layout_row_dynamic(context, 120, 1); nk_layout_row_dynamic(context, 120, 1);
temp_color = nk_color_picker(context, temp_color, NK_RGBA); struct nk_colorf temp_colorf = nk_color_cf(temp_color);
temp_colorf = nk_color_picker(context, temp_colorf, NK_RGBA);
temp_color = nk_rgba_cf(temp_colorf);
nk_layout_row_dynamic(context, 25, 1); nk_layout_row_dynamic(context, 25, 1);
if(col_mode == COL_RGB) if(col_mode == COL_RGB)
{ {
temp_color.r = (nk_byte)nk_propertyi(context, "#R:", 0, temp_color.r, 255, 1,1); temp_color.r = (nk_byte)nk_propertyi(context, "#R:", 0, temp_color.r, 255, 1, 1);
temp_color.g = (nk_byte)nk_propertyi(context, "#G:", 0, temp_color.g, 255, 1,1); temp_color.g = (nk_byte)nk_propertyi(context, "#G:", 0, temp_color.g, 255, 1, 1);
temp_color.b = (nk_byte)nk_propertyi(context, "#B:", 0, temp_color.b, 255, 1,1); temp_color.b = (nk_byte)nk_propertyi(context, "#B:", 0, temp_color.b, 255, 1, 1);
temp_color.a = (nk_byte)nk_propertyi(context, "#A:", 0, temp_color.a, 255, 1,1); temp_color.a = (nk_byte)nk_propertyi(context, "#A:", 0, temp_color.a, 255, 1, 1);
} }
else else
{ {
nk_byte tmp[4]; nk_byte tmp[4];
nk_color_hsva_bv(tmp, temp_color); nk_color_hsva_bv(tmp, temp_color);
tmp[0] = (nk_byte)nk_propertyi(context, "#H:", 0, tmp[0], 255, 1,1); tmp[0] = (nk_byte)nk_propertyi(context, "#H:", 0, tmp[0], 255, 1, 1);
tmp[1] = (nk_byte)nk_propertyi(context, "#S:", 0, tmp[1], 255, 1,1); tmp[1] = (nk_byte)nk_propertyi(context, "#S:", 0, tmp[1], 255, 1, 1);
tmp[2] = (nk_byte)nk_propertyi(context, "#V:", 0, tmp[2], 255, 1,1); tmp[2] = (nk_byte)nk_propertyi(context, "#V:", 0, tmp[2], 255, 1, 1);
tmp[3] = (nk_byte)nk_propertyi(context, "#A:", 0, tmp[3], 255, 1,1); tmp[3] = (nk_byte)nk_propertyi(context, "#A:", 0, tmp[3], 255, 1, 1);
temp_color = nk_hsva_bv(tmp); temp_color = nk_hsva_bv(tmp);
} }
nk_color_f(&color->x, &color->y, &color->z, &color->w, temp_color); nk_color_f(&color->x, &color->y, &color->z, &color->w, temp_color);

File diff suppressed because it is too large Load Diff

@ -1,4 +1,5 @@
Todo: Todo:
- Migrate from bitbucket to github and from mercurial back to git
- Add warning to genie build script when running on windows and WindowsSdkVersion cannot be found. This happens when the script is not run from vcvarsall command prompt - Add warning to genie build script when running on windows and WindowsSdkVersion cannot be found. This happens when the script is not run from vcvarsall command prompt
? Rethink/remove the game executable and game library split. ? Rethink/remove the game executable and game library split.
- Refactor all global application state into 'Application_Context' struct. A single global instance of which is available everywhere - Refactor all global application state into 'Application_Context' struct. A single global instance of which is available everywhere
@ -62,9 +63,8 @@ Bugs:
- Better handling of wav format checking at load time - Better handling of wav format checking at load time
- Fix light rotation/direction bugs - Fix light rotation/direction bugs
- Fix lights type not being correctly saved/loaded from file - Fix lights type not being correctly saved/loaded from file
- Console fix bug when enabled in editor mode
- Fix mouse button press/release behaviour by investigating how sdl handles mouse release or by explicitly caching mouse state by using event callbacks recieved when a mousebutton release event is reported by sdl - Fix mouse button press/release behaviour by investigating how sdl handles mouse release or by explicitly caching mouse state by using event callbacks recieved when a mousebutton release event is reported by sdl
- Fix culling
Done: Done:
* Input * Input
@ -190,3 +190,4 @@ Done:
* Implemented screen coordinate to ray conversion and ray-sphere collision * Implemented screen coordinate to ray conversion and ray-sphere collision
* Split todo and readme into two files * Split todo and readme into two files
* Replace all renderer_check_gl calls with GL_CHECK macro * Replace all renderer_check_gl calls with GL_CHECK macro
* Fixed Console bug when enabled in editor mode
Loading…
Cancel
Save