Is that code in a header file? You might need to mark the method 'inline' if so.
On Thu, Mar 31, 2016 at 5:26 PM, colombia <[email protected]> wrote: > error: Linking globals named 'boost_tick': symbol multiply defined! > > > #include "../../y3d/y3d_yeti.h" > #include "../../y3d/y3d_engine.h" > #include "../models.h" > > void pickup_tick(yeti_t *yeti, entity_t *e, int z); > > > void boost_tick(yeti_t *yeti, entity_t *e) > { > pickup_tick(yeti, e, 256); > } > > > > void boost_init(yeti_t *yeti, entity_t *e) > { > e->tt = i2f(8); > e->visual.data = model_boost; > e->visual.ondraw = yeti_model_draw; > e->ontick = boost_tick; > //e->onhit = guard_hit; > > } > > > > my compile command > > ..\emcc src\platform\sdl\main.c src/game/data.c src/game/entities.c > src/game/game.c src/game/maps.c src/game/models.c src/game/screens.c > src/game/sprites.c > > src/game/ai/boost.c src/game/ai/bullet.c src/game/ai/death.c > src/game/ai/explode.c src/game/ai/pickup.c src/game/ai/quad.c > src/game/ai/sheba.c > > src/game/ai/static_model.c src/game/ai/static_sprite.c > src/game/ai/teleporter.c src/game/ai/torch.c src/y3d/y3d_all.c > src/y3d/y3d_animation.c src/y3d/y3d_ansic.c > > src/y3d/y3d_cell.c src/y3d/y3d_draw.c src/y3d/y3d_engine.c > src/y3d/y3d_entity.c src/y3d/y3d_file.c src/y3d/y3d_fixed.c > src/y3d/y3d_fruity.c src/y3d/y3d_image.c > > src/y3d/y3d_keyboard.c src/y3d/y3d_map.c src/y3d/y3d_matrix.c > src/y3d/y3d_pixel.c src/y3d/y3d_record.c src/y3d/y3d_sound.c > src/y3d/y3d_spanner.c src/y3d/y3d_surface.c > > src/y3d/y3d_vertex.c src/y3d/y3d_yeti.c -Isrc/game -Isrc/y3d > -s USE_ZLIB=1 -s ASSERTIONS=1 -s USE_LIBPNG=1 -s USE_SDL=2 -O0 -o > yeti3d.html > > > > > > > not have funtion duplicated ... possibly a bug? > > thanks > > > my project 4 u test.... > > > > http://www.mediafire.com/download/hhywkt5xh77dew3/3d_engine_compile_with_bat_file.rar > > -- > You received this message because you are subscribed to the Google Groups > "emscripten-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "emscripten-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
