Mercurial > hg > Members > koba > t_dandy
changeset 45:e01948ce859a
fix.
author | koba <koba@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 15 Jan 2011 19:13:03 +0900 |
parents | 2c85322348cf |
children | fce767bb5e25 f5e112bffe26 f4140672ef9f |
files | Dandy.cc Makefile.mac TaskDandy.cc sample.dat |
diffstat | 4 files changed, 13 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/Dandy.cc Fri Jan 14 23:49:23 2011 +0900 +++ b/Dandy.cc Sat Jan 15 19:13:03 2011 +0900 @@ -609,10 +609,12 @@ { SpriteTable *m = &sptable[number]; char *name = (char *) m->texture; + if (!name) { - printf("PutSprite %d unknown\n",number); +// printf("PutSprite %d unknown\n",number); return; } + SceneGraphPtr object = sgroot->createSceneGraph(name); object->xyz[0] = x - object->c_xyz[0]*my_scale; object->xyz[1] = y - object->c_xyz[1]*my_scale; @@ -632,10 +634,11 @@ { SpriteTable *m = &sptable[number]; char *name = (char *) m->texture; -if (!name) { - printf("PutSpriteEx %d unknown\n",number); - return; -} + if (!name) { +// printf("PutSpriteEx %d unknown\n",number); + return; + } + SceneGraphPtr object = sgroot->createSceneGraph(name); object->xyz[0] = x - object->c_xyz[0]*my_scale - m->w*my_scale; object->xyz[1] = y - object->c_xyz[0]*my_scale - m->w*my_scale;
--- a/Makefile.mac Fri Jan 14 23:49:23 2011 +0900 +++ b/Makefile.mac Sat Jan 15 19:13:03 2011 +0900 @@ -20,13 +20,13 @@ ./demo -test demo: $(OBJS) main.o collision.o Character_state.o sgoex.o - $(CC) $(ABI) -o $@ $? $(LIBS) + $(CC) $(OPT) $(ABI) -o $@ $? $(LIBS) dandy: $(OBJS) Dandy.o collision.o Character_state.o - $(CC) $(ABI) -o $@ $? $(LIBS) + $(CC) $(OPT) $(ABI) -o $@ $? $(LIBS) t_dandy: $(OBJS) TaskDandy.o collision_task.o state_task.o $(TASK_OBJS) - $(CC) $(ABI) -o $@ $? $(LIBS) + $(CC) $(OPT) $(ABI) -o $@ $? $(LIBS) clean: rm -f $(TARGET) $(OBJS) $(TASK_OBJS) Dandy.o TaskDandy.o main.o Character_state.o collision_task.o state_task.o sgoex.o
--- a/TaskDandy.cc Fri Jan 14 23:49:23 2011 +0900 +++ b/TaskDandy.cc Sat Jan 15 19:13:03 2011 +0900 @@ -607,7 +607,7 @@ SpriteTable *m = &sptable[number]; char *name = (char *) m->texture; if (!name) { - printf("PutSprite %d unknown\n",number); +// printf("PutSprite %d unknown\n",number); return; } SceneGraphPtr object = sgroot->createSceneGraph(name); @@ -630,7 +630,7 @@ SpriteTable *m = &sptable[number]; char *name = (char *) m->texture; if (!name) { - printf("PutSpriteEx %d unknown\n",number); +// printf("PutSpriteEx %d unknown\n",number); return; } SceneGraphPtr object = sgroot->createSceneGraph(name);