[gnome-games/gnibbles-clutter] More work on reducing CPU usage
- From: Guillaume Béland <guillaubel src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnome-games/gnibbles-clutter] More work on reducing CPU usage
- Date: Sun, 4 Oct 2009 17:12:27 +0000 (UTC)
commit db9ad2efb00963335d25a3b6df7f39c8a0f48b20
Author: Guillaume Beland <guillaume beland gmail com>
Date: Wed Sep 23 17:39:55 2009 -0400
More work on reducing CPU usage
gnibbles/worm.c | 17 +----------------
1 files changed, 1 insertions(+), 16 deletions(-)
---
diff --git a/gnibbles/worm.c b/gnibbles/worm.c
index 45453e9..d364968 100644
--- a/gnibbles/worm.c
+++ b/gnibbles/worm.c
@@ -163,20 +163,6 @@ gnibbles_worm_get_tail_actor (GnibblesWorm *worm)
}
static void
-gnibbles_worm_move_actor (GnibblesWorm *worm)
-{
- ClutterActor *tmp;
- tmp = gnibbles_worm_get_tail_actor (worm);
- clutter_actor_set_position (tmp,
- worm->xhead * properties->tilesize,
- worm->yhead * properties->tilesize);
- worm->list = g_list_prepend (worm->list, tmp);
- worm->list = g_list_delete_link (worm->list, g_list_last (worm->list));
- board->walls[worm->xtail][worm->ytail] = EMPTYCHAR;
- board->walls[worm->xhead][worm->yhead] = WORMCHAR + worm->number;
-}
-
-static void
gnibbles_worm_add_actor (GnibblesWorm *worm)
{
ClutterActor *actor;
@@ -431,9 +417,8 @@ gnibbles_worm_move_head_pointer (GnibblesWorm *worm)
if (worm->yhead >= BOARDHEIGHT)
worm->yhead = 0;
- gnibbles_worm_handle_bonus (worm);
+ gnibbles_worm_handle_bonus (worm);
gnibbles_worm_add_actor (worm);
- //gnibbles_worm_move_actor (worm);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]