aboutsummaryrefslogtreecommitdiff
path: root/contrib/extractor
diff options
context:
space:
mode:
authormegamage <none@none>2008-12-24 15:49:38 -0600
committermegamage <none@none>2008-12-24 15:49:38 -0600
commit808d79eb297c37a51f4c396152348e422c06d44f (patch)
treeeb29d88c8515fe8f2068291126c21934b316220d /contrib/extractor
parente71697462e487f20812bee265cae0c8a8458b160 (diff)
*Some clean up.
--HG-- branch : trunk
Diffstat (limited to 'contrib/extractor')
-rw-r--r--contrib/extractor/Makefile471
-rw-r--r--contrib/extractor/README.linux16
-rw-r--r--contrib/extractor/System.cpp15
-rw-r--r--contrib/extractor/adt.cpp44
-rw-r--r--contrib/extractor/adt.h1
-rw-r--r--contrib/extractor/libmpq/Makefile17
-rw-r--r--contrib/extractor/libmpq/mpq.cpp2
7 files changed, 20 insertions, 546 deletions
diff --git a/contrib/extractor/Makefile b/contrib/extractor/Makefile
deleted file mode 100644
index 55eb35f336a..00000000000
--- a/contrib/extractor/Makefile
+++ /dev/null
@@ -1,471 +0,0 @@
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005 Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-
-# Copyright (C) 2008 Trinity <http://www.trinitycore.org/>
-#
-# Thanks to the original authors: MaNGOS <http://www.mangosproject.org/>
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
-SOURCES = $(ad_SOURCES)
-
-srcdir = .
-top_srcdir = .
-
-pkgdatadir = $(datadir)/mangos
-pkglibdir = $(libdir)/mangos
-pkgincludedir = $(includedir)/mangos
-top_builddir = ../..
-am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
-INSTALL = /usr/bin/ginstall -c
-install_sh_DATA = $(install_sh) -c -m 644
-install_sh_PROGRAM = $(install_sh) -c
-install_sh_SCRIPT = $(install_sh) -c
-INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-build_triplet = i686-pc-linux-gnu
-host_triplet = i686-pc-linux-gnu
-bin_PROGRAMS = ad$(EXEEXT)
-subdir = contrib/extractor
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/configure.ac
-am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
- $(ACLOCAL_M4)
-mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
-CONFIG_HEADER = $(top_builddir)/config.h
-CONFIG_CLEAN_FILES =
-am__installdirs = "$(DESTDIR)$(bindir)"
-binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
-PROGRAMS = $(bin_PROGRAMS)
-am_ad_OBJECTS = System.$(OBJEXT) adt.$(OBJEXT) dbcfile.$(OBJEXT) \
- mpq_libmpq.$(OBJEXT)
-ad_OBJECTS = $(am_ad_OBJECTS)
-ad_DEPENDENCIES =
-DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)
-depcomp = $(SHELL) $(top_srcdir)/depcomp
-am__depfiles_maybe = depfiles
-CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
-LTCXXCOMPILE = $(LIBTOOL) --tag=CXX --mode=compile $(CXX) $(DEFS) \
- $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
- $(AM_CXXFLAGS) $(CXXFLAGS)
-CXXLD = $(CXX)
-CXXLINK = $(LIBTOOL) --tag=CXX --mode=link $(CXXLD) $(AM_CXXFLAGS) \
- $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
-COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) \
- $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
- $(AM_CFLAGS) $(CFLAGS)
-CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
- $(AM_LDFLAGS) $(LDFLAGS) -o $@
-SOURCES = $(ad_SOURCES)
-DIST_SOURCES = $(ad_SOURCES)
-ETAGS = etags
-CTAGS = ctags
-DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
-ACLOCAL =
-ALLOCA =
-AMDEP_FALSE = #
-AMDEP_TRUE =
-AMTAR = ${SHELL} /home/wow/MaNGOS/trunk/missing --run tar
-AR = ar
-AUTOCONF = ${SHELL} /home/wow/MaNGOS/trunk/missing --run autoconf
-AUTOHEADER = ${SHELL} /home/wow/MaNGOS/trunk/missing --run autoheader
-AUTOMAKE = ${SHELL} /home/wow/MaNGOS/trunk/missing --run automake-1.9
-AWK = gawk
-CC = gcc
-CCDEPMODE = depmode=gcc3
-CFLAGS = -g -O3
-COMPILER_OPTIONS = -g -O3
-CPP = gcc -E
-CPPFLAGS =
-CXX = g++
-CXXCPP = g++ -E
-CXXDEPMODE = depmode=gcc3
-CXXFLAGS = -g -O3
-CYGPATH_W = echo
-DEFS = -DHAVE_CONFIG_H
-DEPDIR = .deps
-ECHO = echo
-ECHO_C =
-ECHO_N = -n
-ECHO_T =
-EGREP = grep -E
-EXEEXT =
-EXTRA_COMPILER_OPTIONS =
-EXTRA_LINKER_OPTIONS =
-F77 =
-FFLAGS =
-INCLUDES = -I$(srcdir)
-INSTALL_DATA = ${INSTALL} -m 644
-INSTALL_PROGRAM = ${INSTALL}
-INSTALL_SCRIPT = ${INSTALL}
-INSTALL_STRIP_PROGRAM = ${SHELL} $(install_sh) -c -s
-LDFLAGS =
-LIBOBJS =
-LIBS = -lz -lpthread
-LIBTOOL = $(SHELL) $(top_builddir)/libtool
-LINKER_OPTIONS = -static
-LN_S = ln -s
-LTLIBOBJS =
-LT_AGE = 2
-LT_CURRENT = 2
-LT_RELEASE = 2.3.2
-LT_REVISION = 3
-MAINT = #
-MAINTAINER_MODE_FALSE =
-MAINTAINER_MODE_TRUE = #
-MAKEINFO =
-MANGOSD_CONFIG = /home/wow/server/etc/mangosd.conf
-MANGOSD_CONFIGDIR = /home/wow/server/etc
-MANGOSD_DATA = /home/wow/server/share/mangos
-OBJEXT = o
-PACKAGE = mangos
-PACKAGE_BUGREPORT = http://www.mangosproject.org/
-PACKAGE_NAME = MaNGOS
-PACKAGE_STRING = MaNGOS 0.2-SVN
-PACKAGE_TARNAME = mangos
-PACKAGE_VERSION = 0.2-SVN
-PATH_SEPARATOR = :
-RANLIB = ranlib
-SET_MAKE =
-SHELL = /bin/sh
-STRIP = strip
-VERSION = 0.2-SVN
-ac_ct_AR = ar
-ac_ct_CC = gcc
-ac_ct_CXX = g++
-ac_ct_F77 =
-ac_ct_RANLIB = ranlib
-ac_ct_STRIP = strip
-am__fastdepCC_FALSE = #
-am__fastdepCC_TRUE =
-am__fastdepCXX_FALSE = #
-am__fastdepCXX_TRUE =
-am__include = include
-am__leading_dot = .
-am__quote =
-am__tar = ${AMTAR} chof - "$$tardir"
-am__untar = ${AMTAR} xf -
-bindir = ${exec_prefix}/bin
-build = i686-pc-linux-gnu
-build_alias =
-build_cpu = i686
-build_os = linux-gnu
-build_vendor = pc
-datadir = ${prefix}/share
-exec_prefix = ${prefix}
-host = i686-pc-linux-gnu
-host_alias =
-host_cpu = i686
-host_os = linux-gnu
-host_vendor = pc
-includedir = ${prefix}/include
-infodir = ${prefix}/info
-install_sh = /home/wow/MaNGOS/trunk/install-sh
-libdir = ${exec_prefix}/lib
-libexecdir = ${exec_prefix}/libexec
-localstatedir = ${prefix}/var
-mandir = ${prefix}/man
-mkdir_p = mkdir -p --
-oldincludedir = /usr/include
-prefix = /home/wow/server
-program_transform_name = s,x,x,
-sbindir = ${exec_prefix}/sbin
-sharedstatedir = ${prefix}/com
-
-# use our configured sysconfdir
-sysconfdir = /home/wow/server/etc
-target_alias =
-ad_SOURCES = \
- System.cpp \
- adt.h \
- adt.cpp \
- dbcfile.cpp \
- dbcfile.h \
- mpq_libmpq.cpp \
- mpq_libmpq.h
-
-ad_LDADD = libmpq/libmpq.a
-add_LDFLAGS = -L$(srcdir) -L$(srcdir)/libmpq
-
-all: create-dir all-am
-
-.SUFFIXES:
-.SUFFIXES: .cpp .lo .o .obj
-
-.PRECIOUS: Makefile
-
-install-binPROGRAMS: $(bin_PROGRAMS)
- @$(NORMAL_INSTALL)
- test -z "$(bindir)" || $(mkdir_p) "$(DESTDIR)$(bindir)"
- @list='$(bin_PROGRAMS)'; for p in $$list; do \
- p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
- if test -f $$p \
- || test -f $$p1 \
- ; then \
- f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
- echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \
- $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \
- else :; fi; \
- done
-
-uninstall-binPROGRAMS:
- @$(NORMAL_UNINSTALL)
- @list='$(bin_PROGRAMS)'; for p in $$list; do \
- f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \
- echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \
- rm -f "$(DESTDIR)$(bindir)/$$f"; \
- done
-
-clean-binPROGRAMS:
- @list='$(bin_PROGRAMS)'; for p in $$list; do \
- f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
- echo " rm -f $$p $$f"; \
- rm -f $$p $$f ; \
- done
-ad$(EXEEXT): $(ad_OBJECTS) $(ad_DEPENDENCIES)
- @rm -f ad$(EXEEXT)
- $(CXXLINK) $(ad_LDFLAGS) $(ad_OBJECTS) $(ad_LDADD) $(LIBS)
-
-mostlyclean-compile:
- -rm -f *.$(OBJEXT)
-
-distclean-compile:
- -rm -f *.tab.c
-
-.cpp.o:
- if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \
- then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi
-# source='$<' object='$@' libtool=no \
-# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
-# $(CXXCOMPILE) -c -o $@ $<
-
-.cpp.obj:
- if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \
- then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi
-# source='$<' object='$@' libtool=no \
-# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
-# $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
-
-.cpp.lo:
- if $(LTCXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \
- then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Plo"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi
-# source='$<' object='$@' libtool=yes \
-# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
-# $(LTCXXCOMPILE) -c -o $@ $<
-
-mostlyclean-libtool:
- -rm -f *.lo
-
-clean-libtool:
- -rm -rf .libs _libs
- -rm .deps/*
-
-distclean-libtool:
- -rm -f libtool
-uninstall-info-am:
-
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
- list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
- unique=`for i in $$list; do \
- if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
- done | \
- $(AWK) ' { files[$$0] = 1; } \
- END { for (i in files) print i; }'`; \
- mkid -fID $$unique
-tags: TAGS
-
-TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
- $(TAGS_FILES) $(LISP)
- tags=; \
- here=`pwd`; \
- list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
- unique=`for i in $$list; do \
- if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
- done | \
- $(AWK) ' { files[$$0] = 1; } \
- END { for (i in files) print i; }'`; \
- if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
- test -n "$$unique" || unique=$$empty_fix; \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- $$tags $$unique; \
- fi
-ctags: CTAGS
-CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
- $(TAGS_FILES) $(LISP)
- tags=; \
- here=`pwd`; \
- list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
- unique=`for i in $$list; do \
- if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
- done | \
- $(AWK) ' { files[$$0] = 1; } \
- END { for (i in files) print i; }'`; \
- test -z "$(CTAGS_ARGS)$$tags$$unique" \
- || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
- $$tags $$unique
-
-GTAGS:
- here=`$(am__cd) $(top_builddir) && pwd` \
- && cd $(top_srcdir) \
- && gtags -i $(GTAGS_ARGS) $$here
-
-distclean-tags:
- -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
-distdir: $(DISTFILES)
- @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
- topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
- list='$(DISTFILES)'; for file in $$list; do \
- case $$file in \
- $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
- $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
- esac; \
- if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
- dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
- if test "$$dir" != "$$file" && test "$$dir" != "."; then \
- dir="/$$dir"; \
- $(mkdir_p) "$(distdir)$$dir"; \
- else \
- dir=''; \
- fi; \
- if test -d $$d/$$file; then \
- if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
- fi; \
- cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
- else \
- test -f $(distdir)/$$file \
- || cp -p $$d/$$file $(distdir)/$$file \
- || exit 1; \
- fi; \
- done
-check-am: all-am
-check: check-am
-all-am: Makefile $(PROGRAMS);
-installdirs:
- for dir in "$(DESTDIR)$(bindir)"; do \
- test -z "$$dir" || $(mkdir_p) "$$dir"; \
- done
-install: install-am
-install-exec: install-exec-am
-install-data: install-data-am
-uninstall: uninstall-am
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-
-installcheck: installcheck-am
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- `test -z '$(STRIP)' || \
- echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
-mostlyclean-generic:
-
-clean-generic:
-
-distclean-generic:
- -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-
-maintainer-clean-generic:
- @echo "This command is intended for maintainers to use"
- @echo "it deletes files that may require special tools to rebuild."
-clean: clean-am
-
-clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am
-
-distclean: distclean-am
- -rm -rf ./$(DEPDIR)
-distclean-am: clean-am distclean-compile distclean-generic \
- distclean-libtool distclean-tags
-
-dvi: dvi-am
-
-dvi-am:
-
-html: html-am
-
-info: info-am
-
-info-am:
-
-install-data-am:
-
-install-exec-am: install-binPROGRAMS
-
-install-info: install-info-am
-
-install-man:
-
-installcheck-am:
-
-maintainer-clean: maintainer-clean-am
- -rm -rf ./$(DEPDIR)
- -rm -f Makefile
-maintainer-clean-am: distclean-am maintainer-clean-generic
-
-mostlyclean: mostlyclean-am
-
-mostlyclean-am: mostlyclean-compile mostlyclean-generic \
- mostlyclean-libtool
-
-pdf: pdf-am
-
-pdf-am:
-
-ps: ps-am
-
-ps-am:
-
-uninstall-am: uninstall-binPROGRAMS uninstall-info-am
-
-create-dir:
- mkdir -p ".deps"
-
-.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \
- clean-generic clean-libtool ctags distclean distclean-compile \
- distclean-generic distclean-libtool distclean-tags distdir dvi \
- dvi-am html html-am info info-am install install-am \
- install-binPROGRAMS install-data install-data-am install-exec \
- install-exec-am install-info install-info-am install-man \
- install-strip installcheck installcheck-am installdirs \
- maintainer-clean maintainer-clean-generic mostlyclean \
- mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
- pdf pdf-am ps ps-am tags uninstall uninstall-am \
- uninstall-binPROGRAMS uninstall-info-am
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/contrib/extractor/README.linux b/contrib/extractor/README.linux
index 52b907391b8..e1ebdb8bb2e 100644
--- a/contrib/extractor/README.linux
+++ b/contrib/extractor/README.linux
@@ -1,7 +1,13 @@
-= Trinity Core -- Linux instructions for extractor =
+Linux instructions
+------------------
-Copyright (C) Trinity Core (http://www.trinitycore.org)
+1. Configure and build MaNGOS.
+2. cd contrib/map_extractor/libmpq/
+3. make
+4. cd ..
+5. make
+6. run ad
-1: Configure and build MaNGOS.
-2: cd contrib/extractor/libmpq && make && cd .. && make
-3: run ad \ No newline at end of file
+if there are any problems create folder named .deps in contrib/map_extractor/
+it is old bug from first extractor and i am too lasy to fix it :)
+
diff --git a/contrib/extractor/System.cpp b/contrib/extractor/System.cpp
index 1753f40801a..85d06369f24 100644
--- a/contrib/extractor/System.cpp
+++ b/contrib/extractor/System.cpp
@@ -278,7 +278,7 @@ void LoadLocaleMPQFiles(int const locale)
new MPQArchive(filename);
}
}
-
+
void LoadCommonMPQFiles()
{
char filename[512];
@@ -289,6 +289,7 @@ void LoadCommonMPQFiles()
new MPQArchive(filename);
sprintf(filename,"%s/Data/expansion.MPQ", input_path);
new MPQArchive(filename);
+
for(int i = 1; i < 5; ++i)
{
char ext[3] = "";
@@ -315,7 +316,7 @@ int main(int argc, char * arg[])
HandleArgs(argc, arg);
int FirstLocale = -1;
-
+
for (int i = 0; i < LANG_COUNT; i++)
{
char tmp1[512];
@@ -323,10 +324,10 @@ int main(int argc, char * arg[])
if (FileExists(tmp1))
{
printf("Detected locale: %s\n", langs[i]);
-
+
//Open MPQs
LoadLocaleMPQFiles(i);
-
+
if((extract & EXTRACT_DBC) == 0)
{
FirstLocale = i;
@@ -352,15 +353,15 @@ int main(int argc, char * arg[])
printf("No locales detected\n");
return 0;
}
-
+
if (extract & EXTRACT_MAP)
{
printf("Using locale: %s\n", langs[FirstLocale]);
-
+
// Open MPQs
LoadLocaleMPQFiles(FirstLocale);
LoadCommonMPQFiles();
-
+
// Extract maps
ExtractMapsFromMpq();
diff --git a/contrib/extractor/adt.cpp b/contrib/extractor/adt.cpp
index 71cbf88a37b..dde87e5fc28 100644
--- a/contrib/extractor/adt.cpp
+++ b/contrib/extractor/adt.cpp
@@ -111,24 +111,8 @@ bool LoadADT(char* filename)
{
ChunkLiqHeight[j] = -999999; // no liquid/water
}
-<<<<<<< HEAD:contrib/extractor/adt.cpp
-
- }*/
- break;
- }
- case 0x4d574d4f: // MWMO
- {
- /*
- if (size)
- {
- char *buf = new char[size];
- mf.read(buf, size);
- char *p=buf;
- while (p<buf+size)
-=======
// теперь вычисляем те что с водой и перезаписываем их в куске
for(int b = 0; b <= LiqChunkData1->height; ++b)
->>>>>>> upstream/master:contrib/extractor/adt.cpp
{
for(int c = LiqChunkData1->xOffset; c <= (LiqChunkData1->xOffset + LiqChunkData1->width); ++c)
{
@@ -156,31 +140,8 @@ bool LoadADT(char* filename)
MapLiqHeight[k] = ChunkLiqHeight[p + s];
++k;
}
-<<<<<<< HEAD:contrib/extractor/adt.cpp
- delete[] buf;
- }*/
- break;
- }
- case 0x4d564552: // MVER
- case 0x4d484452: // MHDR header
- case 0x4d434e4b: // MCNK
- case 0x4d544558: // MTEX textures (strings)
- case 0x4d4d4458: // MMDX m2 models (strings)
- case 0x4d4d4944: // MMID offsets for strings in MMDX
- case 0x4d574944: // MWID offsets for strings in MWMO
- case 0x4d444446: // MDDF
- case 0x4d46424f: // MFBO new in BC
- case 0x4d48324f: // MH2O new in WotLK
- break;
- default:
- {
- // mf.seekRelative(-3);
- printf("Unhandled map chunk: %u\n",fourcc);
- break;
-=======
k = k + 120;
}
->>>>>>> upstream/master:contrib/extractor/adt.cpp
}
delete LiqOffsData;
delete LiqChunkData1;
@@ -317,10 +278,6 @@ inline void LoadMapChunk(MPQFile &mf, chunk *_chunk)
if(chunkflags & 4 || chunkflags & 8)
MapLiqFlag[chunk_num] |= 1; // water
if(chunkflags & 16)
-<<<<<<< HEAD:contrib/extractor/adt.cpp
- _chunk->flag |=2;
-
-=======
MapLiqFlag[chunk_num] |= 2; // magma/slime
}
// заполнем так же как в MH2O
@@ -336,7 +293,6 @@ inline void LoadMapChunk(MPQFile &mf, chunk *_chunk)
++k;
}
k = k + 120;
->>>>>>> upstream/master:contrib/extractor/adt.cpp
}
delete []ChunkLiqHeight;
break;
diff --git a/contrib/extractor/adt.h b/contrib/extractor/adt.h
index ec607c9d7bc..52196c4e7e6 100644
--- a/contrib/extractor/adt.h
+++ b/contrib/extractor/adt.h
@@ -126,4 +126,3 @@ uint8 *MapLiqFlag;
uint32 k, m, chunk_num;
void LoadMapChunk(MPQFile &, chunk*);
#endif
-
diff --git a/contrib/extractor/libmpq/Makefile b/contrib/extractor/libmpq/Makefile
deleted file mode 100644
index eb1965e29f1..00000000000
--- a/contrib/extractor/libmpq/Makefile
+++ /dev/null
@@ -1,17 +0,0 @@
-CC = g++
-AR = ar
-objects = common.o explode.o extract.o huffman.o wave.o mpq.o parser.o
-zlib_objects = ../../../dep/src/zlib/*.o #adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o zutil.o inflate.o inftrees.o inffast.o
-
-all: libmpq.a libmpq.so
-
-clean:
- rm -f libmpq.a libmpq.so *.o
-
-libmpq.a: $(objects) $(zlib_objects)
- $(AR) cru $@ $+
-libmpq.so: $(objects) $(zlib_objects)
- $(CC) -fPIC -o $@ $+
-
-%.o:%.cpp
- $(CC) -I../ -c $+
diff --git a/contrib/extractor/libmpq/mpq.cpp b/contrib/extractor/libmpq/mpq.cpp
index 9d1cd883386..c6a5d7d7bdb 100644
--- a/contrib/extractor/libmpq/mpq.cpp
+++ b/contrib/extractor/libmpq/mpq.cpp
@@ -199,7 +199,7 @@ int libmpq_archive_info(mpq_archive *mpq_a, unsigned int infotype) {
/*
* This function returns some useful file information.
*/
-int libmpq_file_info(mpq_archive *mpq_a, unsigned int infotype, const int unsigned number) {
+int libmpq_file_info(mpq_archive *mpq_a, unsigned int infotype, const unsigned int number) {
int blockindex = number; //-1;
int i = 0;
mpq_block *mpq_b = NULL;