X-Git-Url: http://4ch.mooo.com/gitweb/?a=blobdiff_plain;f=src%2Feng_snd.cpp;h=c8f1598bbe94bd1de7ddb1b2b3ee4cfc9c9193ea;hb=e65b5401f0f5a953ca2e69d99fa927635e42fd41;hp=7ca496b0a4dee962f416273e3148dbf2a508fddc;hpb=8546b30d561c27e4b1eab164e17baf4c84a5c42e;p=16.git diff --git a/src/eng_snd.cpp b/src/eng_snd.cpp index 7ca496b0..c8f1598bb 100644 --- a/src/eng_snd.cpp +++ b/src/eng_snd.cpp @@ -1,13 +1,30 @@ #include "src\eng_snd.h" #include +#ifdef __cplusplus /* Functions must be declared C style */ +extern "C" { +#endif +extern void interrupt far newkb(void); +extern int keyp(byte c); +#ifdef __cplusplus +} +#endif + namespace engine { void do_sound() { //sound here //==== std::cout << "SOUND HERE" << std::endl; - //soundtest(); + if(keyp(44)){ + FMKeyOn(0, 0x106, 4); + }//else if(!keyp(44)) FMKeyOff(0); + if(keyp(KEY_A)) FMKeyOff(0); + if(keyp(KEY_X)){ + sound(440); + delay(100); + nosound(); + }else if(keyp(KEY_X+0x80)) nosound(); } -} \ No newline at end of file +}