# HG changeset patch # User koba # Date 1292255647 -32400 # Node ID 6382d8f6a973a1f17b87fb5619d0fd9fc6460fea # Parent b4c797eee72a2c67d9404fdd471fadf2187e6e22 not working. diff -r b4c797eee72a -r 6382d8f6a973 Character.c --- a/Character.c Mon Dec 13 04:56:23 2010 +0900 +++ b/Character.c Tue Dec 14 00:54:07 2010 +0900 @@ -152,7 +152,8 @@ CHARACTER *p; for(p = active_chara_list->next; p!=NULL;p = p->next) { - if((p->state != chara_state8) && (p->state != chara_state9)) + if((p->state != chara_state8) && (p->state != chara_state9) + && (p->collision != noaction)) { p=(*p->collision)(p); } diff -r b4c797eee72a -r 6382d8f6a973 Dandy.cc --- a/Dandy.cc Mon Dec 13 04:56:23 2010 +0900 +++ b/Dandy.cc Tue Dec 14 00:54:07 2010 +0900 @@ -27,9 +27,9 @@ #include #include "error.h" #include "matrix_calc.h" -#include "task_dandy.h" #include "Character.h" #include "Character_state.h" +#include "property.h" int use_keybord = 0; int cdp[20] = { 16, 16, 16, 17, 18, 0 }; @@ -185,7 +185,6 @@ _LightSysSwitch(sgroot); - init_sprite(0,0,0,0); __debug("syokikaが呼びだされました\n"); diff -r b4c797eee72a -r 6382d8f6a973 Makefile --- a/Makefile Mon Dec 13 04:56:23 2010 +0900 +++ b/Makefile Tue Dec 14 00:54:07 2010 +0900 @@ -10,7 +10,7 @@ TASK_SRCS = $(filter-out $(TASK_DIR)/$(TASK_SRCS_EXCLUDE),$(TASK_SRCS_TMP)) TASK_OBJS = $(TASK_SRCS:.cc=.o) -CFLAGS += -g $(ABI) -O2 -Wall `sdl-config --cflags` `xml2-config --cflags` $(INCLUDE) +CFLAGS += -g $(ABI) -Wall `sdl-config --cflags` `xml2-config --cflags` $(INCLUDE) LIBS += `sdl-config --libs`,-framework,OpenGL -lSDL_mixer -lSDL_image `xml2-config --libs` LIBS += -lCerium -lFifoManager @@ -33,7 +33,7 @@ clean: rm -f $(TARGET) $(OBJS) - rm -f Dandy.o tcollision.o ppe/collision.o ppe/task_init.o + rm -f Dandy.o collision.o sgoex.o tcollision.o main.o ppe/Atari.o ppe/task_init.o ppe/Bom.o .c.o: $(CC) $(CFLAGS) $(INCLUDES) -c $< diff -r b4c797eee72a -r 6382d8f6a973 game_task.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/game_task.h Tue Dec 14 00:54:07 2010 +0900 @@ -0,0 +1,2 @@ +// Game で使用する Task ID + ATARI, diff -r b4c797eee72a -r 6382d8f6a973 global_id.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/global_id.h Tue Dec 14 00:54:07 2010 +0900 @@ -0,0 +1,1 @@ +// global_alloc で使用する ID diff -r b4c797eee72a -r 6382d8f6a973 ppe/Atari.cc --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ppe/Atari.cc Tue Dec 14 00:54:07 2010 +0900 @@ -0,0 +1,311 @@ +#include "Atari.h" +#include "tobject.h" +#include "Func.h" + +SchedDefineTask(Atari); + +static int +run(SchedTask *smanager, void *rbuf, void *wbuf) +{ + int w = (int)smanager->get_param(0); + int h = (int)smanager->get_param(1); + int enemycount = (int)smanager->get_param(2); + int bomend = (int)smanager->get_param(3); + int tama_lv1_end = (int)smanager->get_param(4); + int tama_lv2_end = (int)smanager->get_param(5); + int laser_lv1_end = (int)smanager->get_param(6); + int infg_level = (int)smanager->get_param(7); + + CollisionPropertyPtr property + = (CollisionPropertyPtr)smanager->get_input(rbuf, 0); + + player *jiki = &property->jiki; + CHARACTER *p = &property->p; + tama1 *tlv3 = &property->tlv3; + stge lg = property->lg; + stge infg = property->infg; + + tama1 *tama_lv1 = property->tama_lv1; + tama2 *tama_lv2 = property->tama_lv2; + laser *laser_lv1 = property->laser_lv1; + laser *laser_lv2 = property->laser_lv2; + laser *laser_lv3 = property->laser_lv3; + bomchar *bchar = property->bchar; + + int i1, ex, ey; + int n; + ex = p->x; + ey = p->y; + +//自機やられ +#ifndef INVISIBLE_MODE + if ((ex < jiki->x + 128 / 2) && (ex + w > jiki->x + 128 / 2) + && (ey < jiki->y + 128 / 2) && (ey + h > jiki->y + 128 / 2) + && jiki->muteki == 0) { + Bom(jiki->x + 16, jiki->y + 16, bomend, bchar); + jiki->bf = FALSE; + jiki->zanki--; + jiki->muteki = 120; + + infg.stg = 0; + infg_level--; + if (infg_level < 0) + infg_level = 0; + + property->infg = infg; + smanager->swap(); + return 0; + } +#endif + + if (p->tama == TRUE) + goto jumping; + for (i1 = 0; i1 < tama_lv1_end + 1; i1++) { + + if ((tama_lv1[i1].x + 64 + 64 > ex) + && (ex + w > tama_lv1[i1].x + 16) + && (tama_lv1[i1].y + 128 > ey) && (tama_lv1[i1].y < ey + h) + && (tama_lv1[i1].r != -1)) { + tama_lv1[i1].r = -1; + p->vit -= TAMALV1P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + if ((tama_lv1[i1].x + 64 > ex) && (ex + w > tama_lv1[i1].x) + && (tama_lv1[i1].y + 128 > ey) && (tama_lv1[i1].y < ey + h) + && (tama_lv1[i1].l != -1)) { + tama_lv1[i1].l = -1; + p->vit -= TAMALV1P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + } + + for (i1 = 0; i1 < tama_lv2_end + 1; i1++) { + if ((tama_lv2[i1].x + 128 + 64 > ex) + && (ex + w > tama_lv2[i1].x + 128) + && (tama_lv2[i1].y + 192 > ey) && (tama_lv2[i1].y < ey + h) + && (tama_lv2[i1].rr != -1)) { + tama_lv2[i1].rr = -1; + p->vit -= TAMALV2P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + + if ((tama_lv2[i1].x + 64 + 64 > ex) + && (ex + w > tama_lv2[i1].x + 16) + && (tama_lv2[i1].y - 32 + 192 > ey) + && (tama_lv2[i1].y - 32 < ey + h) + && (tama_lv2[i1].sr != -1)) { + tama_lv2[i1].sr = -1; + p->vit -= TAMALV2P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + if ((tama_lv2[i1].x + 64 > ex) && (ex + w > tama_lv2[i1].x) + && (tama_lv2[i1].y - 32 + 192 > ey) + && (tama_lv2[i1].y - 32 < ey + h) + && (tama_lv2[i1].sl != -1)) { + tama_lv2[i1].sl = -1; + p->vit -= TAMALV2P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + if ((tama_lv2[i1].x - 64 + 64 > ex) + && (ex + w > tama_lv2[i1].x - 64) + && (tama_lv2[i1].y + 192 > ey) && (tama_lv2[i1].y < ey + h) + && (tama_lv2[i1].ll != -1)) { + tama_lv2[i1].ll = -1; + p->vit -= TAMALV2P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + } + if ((tlv3[0].r > 0) && (jiki->x < ex + w) && (jiki->x + 128 > ex) + && (jiki->y > ey + h)) { + p->vit -= TAMALV3P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + jumping: + if ((tlv3[0].r > 0) && (jiki->x < ex + w) && (jiki->x + 128 > ex) + && (jiki->y + 128 > ey) && (jiki->y < ey + h)) { + p->vit -= TAMALV3P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + /*laser lv1 */ + for (i1 = 0; i1 < laser_lv1_end + 1; i1++) { + n = laser_lv1[i1].r * 128 / 4096; + + if ((laser_lv1[i1].x + n > ex) && (ex + w > laser_lv1[i1].x) + && (laser_lv1[i1].y + n > ey) && (laser_lv1[i1].y < ey + h) + && (laser_lv1[i1].r != -1)) { + laser_lv1[i1].r = -1; + laser_lv1[i1].y = -1; + p->vit -= LASERLV1P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + } + /*shield(laser lv2) */ + if ((p->tama == TRUE) && (lg.stg > 0) && + (laser_lv2[0].x + 128 > ex) && (ex + w > laser_lv2[0].x - 128) + && (laser_lv2[0].y + 128 > ey) && (laser_lv2[0].y - 128 < ey + h) + && (laser_lv2[0].r != 0)) { + p->vit -= LASERLV2P; + lg.stg -= 26; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->lg = lg; + property->infg = infg; + smanager->swap(); + return 0; + } + } + /*bomber(laser lv3) */ + if (laser_lv3[0].r < 62) { + for (i1 = 1; i1 < 128; i1++) { + if ((laser_lv3[i1].x + 128 > ex) && (ex + w > laser_lv3[i1].x) + && (laser_lv3[i1].y + 128 > ey) + && (laser_lv3[i1].y < ey + h) + && (laser_lv3[i1].r > 0)) { + tama_lv2[i1].rr = -1; + p->vit -= LASERLV3P; + infg.stg++; + if (p->vit <= 0) { + infg.stg += 4; + Bom(p->x, p->y, bomend, bchar); + enemycount += (p->score * + ((infg.stg / 128) + infg_level + 1)); + p->state = delete_chara; + p->collision = noaction; + p->f = FALSE; + + property->infg = infg; + smanager->swap(); + return 0; + } + } + } + } + property->infg = infg; + smanager->swap(); + return 0; +} diff -r b4c797eee72a -r 6382d8f6a973 ppe/Atari.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ppe/Atari.h Tue Dec 14 00:54:07 2010 +0900 @@ -0,0 +1,8 @@ +#ifndef INCLUDE_COLLISION +#define INCLUDE_COLLISION + +#ifndef INCLUDED_SCHED_TASK +#include "SchedTask.h" +#endif + +#endif diff -r b4c797eee72a -r 6382d8f6a973 ppe/Bom.cc --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ppe/Bom.cc Tue Dec 14 00:54:07 2010 +0900 @@ -0,0 +1,19 @@ +#include "tobject.h" + +void +Bom(int x, int y, int bomend, bomchar *bchar) +{ + int i; + bomend++; + if (bomend > 49) { + bomend = 49; + return; + } + + i = bomend; + bchar[i].x = x; + bchar[i].y = y; + bchar[i].no = 0; + bchar[i].f = 0; + return; +} diff -r b4c797eee72a -r 6382d8f6a973 ppe/Character_state.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ppe/Character_state.h Tue Dec 14 00:54:07 2010 +0900 @@ -0,0 +1,49 @@ + +CHARACTER * noaction(CHARACTER *p); +CHARACTER * chara_state0(CHARACTER *p); +CHARACTER * chara_state1(CHARACTER *p); +CHARACTER * chara_state2(CHARACTER *p); +CHARACTER * chara_state3(CHARACTER *p); +CHARACTER * chara_state4(CHARACTER *p); +CHARACTER * chara_state5(CHARACTER *p); +CHARACTER * chara_state6(CHARACTER *p); +CHARACTER * chara_state7(CHARACTER *p); +CHARACTER * chara_state8(CHARACTER *p); +CHARACTER * chara_state9(CHARACTER *p); +CHARACTER * chara_state10(CHARACTER *p); +CHARACTER * chara_state11(CHARACTER *p); +CHARACTER * chara_state12(CHARACTER *p); +CHARACTER * chara_state13(CHARACTER *p); +CHARACTER * chara_state20(CHARACTER *p); +CHARACTER * chara_state21(CHARACTER *p); +CHARACTER * chara_state22(CHARACTER *p); +CHARACTER * chara_state23(CHARACTER *p); +CHARACTER * chara_state24(CHARACTER *p); +CHARACTER * chara_state25(CHARACTER *p); +CHARACTER * chara_state26(CHARACTER *p); +CHARACTER * chara_state27(CHARACTER *p); +CHARACTER * chara_state28(CHARACTER *p); +CHARACTER * chara_state29(CHARACTER *p); +CHARACTER * chara_state30(CHARACTER *p); +CHARACTER * chara_state31(CHARACTER *p); +CHARACTER * chara_state32(CHARACTER *p); +CHARACTER * chara_state33(CHARACTER *p); +CHARACTER * chara_state34(CHARACTER *p); +CHARACTER * chara_state35(CHARACTER *p); +CHARACTER * chara_state40(CHARACTER *p); +CHARACTER * chara_state41(CHARACTER *p); +CHARACTER * chara_state400(CHARACTER *p); +CHARACTER * chara_state401(CHARACTER *p); +CHARACTER * chara_state402(CHARACTER *p); +CHARACTER * chara_state410(CHARACTER *p); +CHARACTER * chara_state411(CHARACTER *p); +CHARACTER * chara_state500(CHARACTER *p); +CHARACTER * chara_state501(CHARACTER *p); +CHARACTER * chara_state600(CHARACTER *p); +CHARACTER * chara_state601(CHARACTER *p); +CHARACTER * chara_state602(CHARACTER *p); +CHARACTER * asteroid(CHARACTER *p); + +extern int enemyfaste; +extern int fastebos; +extern int asteroidi; diff -r b4c797eee72a -r 6382d8f6a973 ppe/task_init.cc --- a/ppe/task_init.cc Mon Dec 13 04:56:23 2010 +0900 +++ b/ppe/task_init.cc Tue Dec 14 00:54:07 2010 +0900 @@ -1,4 +1,4 @@ -#include "../Func.h" +#include "Func.h" #include "Scheduler.h" /* 必ずこの位置に書いて */ @@ -12,5 +12,5 @@ void task_init(void) { - SchedRegister(Atari); + SchedRegisterTask(ATARI, Atari); } diff -r b4c797eee72a -r 6382d8f6a973 ppe/tobject.h --- a/ppe/tobject.h Mon Dec 13 04:56:23 2010 +0900 +++ b/ppe/tobject.h Tue Dec 14 00:54:07 2010 +0900 @@ -89,8 +89,27 @@ } CHARACTER; +typedef struct CollisionProperty { + int infg_level; + int enemycount; + + player jiki; + CHARACTER p; + stge lg; + stge infg; + + tama1 tama_lv1[20]; + tama2 tama_lv2[20]; + tama1 tlv3; + laser laser_lv1[20]; + laser laser_lv2[20]; + laser laser_lv3[128]; + bomchar bchar[100]; + +} CollisionProperty, *CollisionPropertyPtr; + CHARACTER * noaction(CHARACTER *p); CHARACTER * delete_chara(CHARACTER *p); -extern void Bom(int x, int y, int bchar, bomchar bchar); +extern void Bom(int x, int y, int bchar, bomchar *bchar); #endif diff -r b4c797eee72a -r 6382d8f6a973 property.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/property.h Tue Dec 14 00:54:07 2010 +0900 @@ -0,0 +1,27 @@ +#ifndef INCLUDE_PROPERTY +#define INCLUDE_PROPERTY + +#include "Character.h" +#include "bom.h" +#include "count2.h" +#include "sgoex.h" + +typedef struct CollisionProperty { + int infg_level; + int enemycount; + + player jiki; + CHARACTER p; + stge lg; + stge infg; + + tama1 tama_lv1[20]; + tama2 tama_lv2[20]; + tama1 tlv3; + laser laser_lv1[20]; + laser laser_lv2[20]; + laser laser_lv3[128]; + bomchar bchar[100]; + +} CollisionProperty, *CollisionPropertyPtr; +#endif diff -r b4c797eee72a -r 6382d8f6a973 tcollision.cc --- a/tcollision.cc Mon Dec 13 04:56:23 2010 +0900 +++ b/tcollision.cc Tue Dec 14 00:54:07 2010 +0900 @@ -12,54 +12,92 @@ #include "sgoex.h" #include "TaskManager.h" #include "Func.h" -#include "task_dandy.h" +#include "property.h" extern SpriteTable sptable[DEFOBJ]; +extern TaskManager *tmanager; + +CollisionPropertyPtr +get_property(CHARACTER *p) +{ + CollisionPropertyPtr property = new(CollisionProperty); + + property->infg_level = infg_level; + property->enemycount = 0; + + property->jiki = jiki; + property->p = *p; + property->tlv3 = tlv3[0]; + property->lg = lg; + property->infg = infg; + + + memcpy(property->tama_lv1, &tama_lv1, sizeof(tama1)*20); + memcpy(property->tama_lv2, &tama_lv2, sizeof(tama2)*20); + memcpy(property->laser_lv1, &laser_lv1, sizeof(laser)*20); + memcpy(property->laser_lv2, &laser_lv2, sizeof(laser)*20); + memcpy(property->laser_lv3, &laser_lv3, sizeof(laser)*128); + memcpy(property->bchar, &bchar, sizeof(bomchar)*100); + + return property; +} + +void +free_property(SchedTask *s, void *prop, void *chara) +{ + CollisionPropertyPtr property = (CollisionPropertyPtr)prop; + CHARACTER *character = (CHARACTER *)chara; + + if(infg_level <= property->infg_level||infg_level != 0) { + infg_level--; + } + if(lg.stg <= property->lg.stg) { + lg.stg -= 26; + } + enemycount += property->enemycount; + + jiki = property->jiki; + *character = property->p; + tlv3[0] = property->tlv3; + infg = property->infg; + + memcpy(tama_lv1, property->tama_lv1, sizeof(tama1)*20); + memcpy(tama_lv2, property->tama_lv2, sizeof(tama2)*20); + memcpy(laser_lv1, property->laser_lv1, sizeof(laser)*20); + memcpy(laser_lv2, property->laser_lv2, sizeof(laser)*20); + memcpy(laser_lv3, property->laser_lv3, sizeof(laser)*128); + memcpy(bchar, property->bchar, sizeof(bomchar)*100); + + delete property; +} + CHARACTER * atari(CHARACTER *p) { int w, h, charno; + CollisionPropertyPtr property = get_property(p); charno = p->charano; w = sptable[charno].w; h = sptable[charno].h; - HTaskPtr collision = tmanager->create_task(Atari); - collision->set_param(0,(memaddr)w); - collision->set_param(1,(memaddr)h); - collision->set_param(2,(memaddr)enemycount); - collision->set_param(3,(memaddr)bomend); - collision->set_param(4,(memaddr)tama_lv1_end); - collision->set_param(5,(memaddr)tama_lv2_end); - collision->set_param(6,(memaddr)laser_lv1_end); - collision->set_param(7,(memaddr)infg_level); - - collision->add_inData(&jiki, sizeof(player)); - collision->add_inData(tama_lv1, sizeof(tama1)*tama_lv1_end); - collision->add_inData(tama_lv2, sizeof(tama2)*tama_lv2_end); - collision->add_inData(&tlv3[0], sizeof(tama1)); - collision->add_inData(laser_lv1, sizeof(laser)*laser_lv1_end); - collision->add_inData(&laser_lv2[0], sizeof(laser)); - collision->add_inData(laser_lv3, sizeof(laser)*128); - collision->add_inData(&bchar[0], sizeof(bomchar)); - collision->add_inData(&p, sizeof(CHARACTER)); - collision->add_inData(&lg, sizeof(stge)); - collision->add_inData(&infg, sizeof(stge)); + HTaskPtr collision_task = tmanager->create_task(ATARI); - collision->add_outData(&jiki, sizeof(player)); - collision->add_outData(tama_lv1, sizeof(tama1)*tama_lv1_end); - collision->add_outData(tama_lv2, sizeof(tama2)*tama_lv2_end); - collision->add_outData(&tlv3[0], sizeof(tama1)); - collision->add_outData(laser_lv1, sizeof(laser)*laser_lv1_end); - collision->add_outData(&laser_lv2[0], sizeof(laser)); - collision->add_outData(laser_lv3, sizeof(laser)*128); - collision->add_outData(&bchar[0], sizeof(bomchar)); - collision->add_outData(&p, sizeof(CHARACTER)); - collision->add_outData(&lg, sizeof(stge)); - collision->add_outData(&infg, sizeof(stge)); + collision_task->set_param(0,(memaddr)w); + collision_task->set_param(1,(memaddr)h); + collision_task->set_param(2,(memaddr)enemycount); + collision_task->set_param(3,(memaddr)bomend); + collision_task->set_param(4,(memaddr)tama_lv1_end); + collision_task->set_param(5,(memaddr)tama_lv2_end); + collision_task->set_param(6,(memaddr)laser_lv1_end); + collision_task->set_param(7,(memaddr)infg_level); - collision->set_cpu(SPE_ANY); - collision->spawn(); + collision_task->add_inData(property, sizeof(CollisionProperty)); + collision_task->add_outData(property, sizeof(CollisionProperty)); +// collision_task->set_post(free_property, property, p); + + collision_task->set_cpu(SPE_ANY); + collision_task->spawn(); return p; }