Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/ClusterM/space-dragon.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey 'Cluster' Avdyukhin <clusterrr@clusterrr.com>2014-10-12 14:42:32 +0400
committerAlexey 'Cluster' Avdyukhin <clusterrr@clusterrr.com>2014-10-12 14:42:32 +0400
commita614cbc2f6034fd613557821d4a3f759e4fea056 (patch)
tree89b464cde42eec753de3d708c1cb27c1491c02e2
parent54efdef2dcb140ed78c398a8b39f5fc195713913 (diff)
Cleanup, copyright.
-rw-r--r--src/game.c18
-rw-r--r--src/game.h2
2 files changed, 13 insertions, 7 deletions
diff --git a/src/game.c b/src/game.c
index ba99ae8..8801888 100644
--- a/src/game.c
+++ b/src/game.c
@@ -1,6 +1,12 @@
#include <pebble.h>
#include "game.h"
+/*
+*** Author: Cluster aka Alexey Avdyukhin
+*** Mailto: clusterrr@clusterrr.com
+*** http://clusterrr.com
+*/
+
static Window *s_window;
static Layer *gfx_layer;
static AppTimer *timer;
@@ -234,7 +240,7 @@ void update_timer(void* data)
// Using accelerometer data to control ship
AccelData acc;
- accel_service_peek(&acc);
+ accel_service_peek(&acc);
acc_x = acc.x;
acc_y = acc.y;
@@ -475,23 +481,23 @@ void show_game() {
// Creating window
s_window = window_create();
- window_set_background_color(s_window, GColorWhite);
- window_set_fullscreen(s_window, true);
+ window_set_background_color(s_window, GColorWhite);
+ window_set_fullscreen(s_window, true);
window_set_window_handlers(s_window, (WindowHandlers) {
.unload = handle_window_unload,
});
// The layer
- Layer *window_layer = window_get_root_layer(s_window);
- GRect bounds = layer_get_frame(window_layer);
+ Layer *window_layer = window_get_root_layer(s_window);
+ GRect bounds = layer_get_frame(window_layer);
gfx_layer = layer_create(bounds);
layer_set_update_proc(gfx_layer, game_draw);
layer_add_child(window_layer, gfx_layer);
window_set_click_config_provider(s_window, config_provider);
- window_stack_push(s_window, true);
+ window_stack_push(s_window, true);
// Game timer
timer = app_timer_register(UPDATE_INTERVAL, (AppTimerCallback) update_timer, NULL);
diff --git a/src/game.h b/src/game.h
index 1cca719..1e2d342 100644
--- a/src/game.h
+++ b/src/game.h
@@ -1,7 +1,7 @@
#ifndef _GAME_H_
#define _GAME_H_
-#define VERSION "v1.3"
+#define VERSION "v1.4"
#define SHIP_WIDTH 10
#define SHIP_HEIGHT 15
#define SCREEN_WIDTH 144