diff options
author | Eugenio Favalli <elvenprogrammer@gmail.com> | 2005-04-11 12:10:36 +0000 |
---|---|---|
committer | Eugenio Favalli <elvenprogrammer@gmail.com> | 2005-04-11 12:10:36 +0000 |
commit | a85e6c544912b9ebd261b5da29b26e3232284173 (patch) | |
tree | 07b989c73225d0855e9a4298de002f8fce2d3f0c /src/game.cpp | |
parent | 2eae5c2914731091ee25929250a701e5e2c2c724 (diff) | |
download | mana-client-a85e6c544912b9ebd261b5da29b26e3232284173.tar.gz mana-client-a85e6c544912b9ebd261b5da29b26e3232284173.tar.bz2 mana-client-a85e6c544912b9ebd261b5da29b26e3232284173.tar.xz mana-client-a85e6c544912b9ebd261b5da29b26e3232284173.zip |
- First step toward syncing attack animation with attack speed
- Added a nice sample when attacking to stress test sound engine/
loading samples through resource manager.
Diffstat (limited to 'src/game.cpp')
-rw-r--r-- | src/game.cpp | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/game.cpp b/src/game.cpp index fdd8899e..30eb5f29 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -224,12 +224,8 @@ void do_input() } else if ((keysym.sym == SDLK_F7)) { - /*SOUND_SID id = sound.loadItem("data/sfx/fist-swish.ogg"); - sound.startItem(id, 120);*/ - ResourceManager *resman = ResourceManager::getInstance(); - SoundEffect *sample = resman->getSoundEffect( - "sfx/fist-swish.ogg"); - sample->play(0, 120); + SOUND_SID id = sound.loadItem("data/sfx/fist-swish.ogg"); + sound.startItem(id, 120); } // Emotions, Skill dialog @@ -365,7 +361,7 @@ void do_input() } else { // Search for player character to trade with - /* + id = find_pc(mx, my); if (id != 0) { // Begin a trade @@ -373,7 +369,6 @@ void do_input() WFIFOL(2) = net_l_value(id); WFIFOSET(6); } - */ } @@ -537,6 +532,11 @@ void do_input() player_node->y, player_node->direction); player_node->walk_time = tick_time; + + ResourceManager *resman = ResourceManager::getInstance(); + SoundEffect *sample = resman->getSoundEffect( + "sfx/fist-swish.ogg"); + sample->play(0, 120); } } @@ -1017,6 +1017,9 @@ void do_parse() { sprintf(points, "b0 0x0009 %i", RFIFOL(4)); chatWindow->chat_log(points, BY_SERVER);*/ break; + case 0x0035: + player_node->aspd = RFIFOW(4); + break; default: /*char unknown[20]; sprintf(unknown, "b0 %x %i", RFIFOW(2),RFIFOL(4)); |