mirror of
https://github.com/vcmi/vcmi.git
synced 2024-11-24 08:32:34 +02:00
051094abcc
* upiększenie fragmentów kodu * przesuwanie mapy przejechaniem kursora na skraj wyświetlanego obszaru * ładne ramki przykrywające obiekty * ulepszenie obsługi defów i lodów * przyspieszenie przewijania map
28 lines
746 B
C++
28 lines
746 B
C++
#ifndef CSNDHANDLER_H
|
|
#define CSNDHANDLER_H
|
|
|
|
#include <vector>
|
|
#include <fstream>
|
|
class CSndHandler
|
|
{
|
|
protected:
|
|
const int CHUNK;
|
|
struct Entry
|
|
{
|
|
std::string name;
|
|
int size, offset;
|
|
};
|
|
std::ifstream file;
|
|
int readNormalNr (int pos, int bytCon);
|
|
bool opened;
|
|
public:
|
|
std::vector<Entry> entries;
|
|
~CSndHandler();
|
|
CSndHandler(std::string fname);
|
|
void extract(std::string srcfile, std::string dstfile, bool caseSens=true); //saves selected file
|
|
unsigned char * extract (std::string srcfile, int & size); //return selecte file
|
|
void extract(int index, std::string dstfile); //saves selected file
|
|
unsigned char * extract (int index, int & size); //return selecte file - NIE TESTOWANE
|
|
};
|
|
|
|
#endif //CSNDHANDLER_H
|