Compare commits

..

No commits in common. 'main/yubo-dev' and 'main/gingo-test' have entirely different histories.

18
.gitattributes vendored

@ -1,18 +0,0 @@
*.cpp ident
*.h ident
# Set the default behavior, in case people don't have core.autocrlf set.
* text=auto
# Explicitly declare text files you want to always be normalized and converted
# to native line endings on checkout.
*.c text
*.h text
*.cs text
*.jade text
*.json text
*.js text
*.css text
*.htm text
*.txt text
*.sh text eol=lf

1
.gitignore vendored

@ -267,7 +267,6 @@ web/public_php/db_version_tool
web/public_php/db_version_web web/public_php/db_version_web
web/public_php/role_service web/public_php/role_service
web/public_php/role_support web/public_php/role_support
web/public_php/role_admin
web/public_php/role_domain web/public_php/role_domain
web/public_php/db_version_ring web/public_php/db_version_ring
web/public_php/config_user.php web/public_php/config_user.php

@ -79,8 +79,8 @@ ENDIF()
CMAKE_MINIMUM_REQUIRED(VERSION 2.6) CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
PROJECT(RyzomCore CXX C) PROJECT(RyzomCore CXX C)
SET(NL_VERSION_MAJOR 4) SET(NL_VERSION_MAJOR 1)
SET(NL_VERSION_MINOR 0) SET(NL_VERSION_MINOR 1)
SET(NL_VERSION_PATCH 0 CACHE STRING "Patch version") SET(NL_VERSION_PATCH 0 CACHE STRING "Patch version")
SET(YEAR "2001-${CURRENT_YEAR}") SET(YEAR "2001-${CURRENT_YEAR}")
SET(AUTHOR "Winch Gate and The Ryzom Core Community") SET(AUTHOR "Winch Gate and The Ryzom Core Community")
@ -124,14 +124,14 @@ RYZOM_SETUP_PREFIX_PATHS()
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
# Default values for URL's # Default values for URL's
SET(RYZOM_CLIENT_CREATE_ACCOUNT_URL "https://core.ryzom.dev/ams/" CACHE STRING "Ryzom Client Create Account URL") SET(RYZOM_CLIENT_CREATE_ACCOUNT_URL "https://open.ryzom.dev/ams/" CACHE STRING "Ryzom Client Create Account URL")
SET(RYZOM_CLIENT_EDIT_ACCOUNT_URL "https://core.ryzom.dev/ams/" CACHE STRING "Ryzom Client Edit Account URL") SET(RYZOM_CLIENT_EDIT_ACCOUNT_URL "https://open.ryzom.dev/ams/" CACHE STRING "Ryzom Client Edit Account URL")
SET(RYZOM_CLIENT_FORGET_PASSWORD_URL "https://core.ryzom.dev/ams/" CACHE STRING "Ryzom Client Forget Password URL") SET(RYZOM_CLIENT_FORGET_PASSWORD_URL "https://open.ryzom.dev/ams/" CACHE STRING "Ryzom Client Forget Password URL")
SET(RYZOM_CLIENT_PATCH_URL "https://cdn.ryzom.dev/core4/patch/" CACHE STRING "Ryzom Client Patch URL") SET(RYZOM_CLIENT_PATCH_URL "https://cdn.ryzom.dev/open/patch/" CACHE STRING "Ryzom Client Patch URL")
SET(RYZOM_CLIENT_APP_NAME "core4") SET(RYZOM_CLIENT_APP_NAME "default")
SET(RYZOM_CLIENT_RELEASENOTES_URL "https://core4.ryzom.dev/releasenotes/index.php" CACHE STRING "Ryzom Client Release Notes URL") SET(RYZOM_WEBIG_MAIN_URL "https://open.ryzom.dev/" CACHE STRING "Ryzom Client WebIG Main URL")
SET(RYZOM_CLIENT_RELEASENOTES_RING_URL "https://core4.ryzom.dev/releasenotes_ring/index.php" CACHE STRING "Ryzom Client Release Notes URL") SET(RYZOM_WEBIG_TRUSTED_DOMAIN "open.ryzom.dev" CACHE STRING "Ryzom Client WebIG Trusted Domain")
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
# urls when compiling ryzom live client # urls when compiling ryzom live client
@ -145,9 +145,6 @@ IF(WITH_RYZOM_LIVE)
SET(RYZOM_WEBIG_MAIN_URL "https://app.ryzom.com/") SET(RYZOM_WEBIG_MAIN_URL "https://app.ryzom.com/")
SET(RYZOM_WEBIG_TRUSTED_DOMAIN "app.ryzom.com") SET(RYZOM_WEBIG_TRUSTED_DOMAIN "app.ryzom.com")
SET(RYZOM_CLIENT_RELEASENOTES_URL "https://app.ryzom.com/releasenotes/index.php")
SET(RYZOM_CLIENT_RELEASENOTES_RING_URL "https://app.ryzom.com/releasenotes_ring/index.php")
ENDIF() ENDIF()
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------

@ -16,14 +16,7 @@ ENDIF (ICONV_INCLUDE_DIR AND ICONV_LIBRARIES)
FIND_PATH(ICONV_INCLUDE_DIR iconv.h HINTS /sw/include/ PATHS /opt/local) FIND_PATH(ICONV_INCLUDE_DIR iconv.h HINTS /sw/include/ PATHS /opt/local)
FIND_LIBRARY(ICONV_LIBRARIES_RELEASE NAMES iconv libiconv c PATHS /opt/local) FIND_LIBRARY(ICONV_LIBRARIES NAMES iconv libiconv c PATHS /opt/local)
FIND_LIBRARY(ICONV_LIBRARIES_DEBUG NAMES iconvd libiconvd c PATHS /opt/local)
IF (ICONV_LIBRARIES_RELEASE AND ICONV_LIBRARIES_DEBUG)
SET(ICONV_LIBRARIES optimized ${ICONV_LIBRARIES_RELEASE} debug ${ICONV_LIBRARIES_DEBUG})
ELSE()
SET(ICONV_LIBRARIES ${ICONV_LIBRARIES_RELEASE})
ENDIF()
IF(ICONV_INCLUDE_DIR AND ICONV_LIBRARIES) IF(ICONV_INCLUDE_DIR AND ICONV_LIBRARIES)
SET(ICONV_FOUND TRUE) SET(ICONV_FOUND TRUE)
@ -67,6 +60,5 @@ ENDIF()
MARK_AS_ADVANCED( MARK_AS_ADVANCED(
ICONV_INCLUDE_DIR ICONV_INCLUDE_DIR
ICONV_LIBRARIES ICONV_LIBRARIES
ICONV_LIBRARIES_DEBUG
ICONV_SECOND_ARGUMENT_IS_CONST ICONV_SECOND_ARGUMENT_IS_CONST
) )

@ -38,25 +38,11 @@ find_path(LUA_INCLUDE_DIR lua.h
/opt /opt
) )
FIND_LIBRARY(LUA_LIBRARY find_library(LUA_LIBRARY
NAMES lua53 lua5.3 lua-5.3 lua NAMES lua53 lua5.3 lua-5.3 lua
HINTS HINTS
$ENV{LUA_DIR} ENV LUA_DIR
PATH_SUFFIXES lib64 lib PATH_SUFFIXES lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/sw
/opt/local
/opt/csw
/opt
)
FIND_LIBRARY(LUA_LIBRARY_DEBUG
NAMES lua53-d lua5.3-d lua-5.3-d lua-d lua53d lua5.3d lua-5.3d luad
HINTS
$ENV{LUA_DIR}
PATH_SUFFIXES lib64 lib
PATHS PATHS
~/Library/Frameworks ~/Library/Frameworks
/Library/Frameworks /Library/Frameworks
@ -73,11 +59,7 @@ if(LUA_LIBRARY)
set( LUA_LIBRARIES "${LUA_LIBRARY};${LUA_MATH_LIBRARY}" CACHE STRING "Lua Libraries") set( LUA_LIBRARIES "${LUA_LIBRARY};${LUA_MATH_LIBRARY}" CACHE STRING "Lua Libraries")
# For Windows and Mac, don't need to explicitly include the math library # For Windows and Mac, don't need to explicitly include the math library
else() else()
if (LUA_LIBRARY_DEBUG) set( LUA_LIBRARIES "${LUA_LIBRARY}" CACHE STRING "Lua Libraries")
set( LUA_LIBRARIES optimized ${LUA_LIBRARY} debug ${LUA_LIBRARY_DEBUG} CACHE STRING "Lua Libraries")
else()
set( LUA_LIBRARIES "${LUA_LIBRARY}" CACHE STRING "Lua Libraries")
endif()
endif() endif()
endif() endif()
@ -95,5 +77,5 @@ FIND_PACKAGE_HANDLE_STANDARD_ARGS(Lua53
REQUIRED_VARS LUA_LIBRARIES LUA_INCLUDE_DIR REQUIRED_VARS LUA_LIBRARIES LUA_INCLUDE_DIR
VERSION_VAR LUA_VERSION_STRING) VERSION_VAR LUA_VERSION_STRING)
mark_as_advanced(LUA_INCLUDE_DIR LUA_LIBRARIES LUA_LIBRARY LUA_LIBRARY_DEBUG LUA_MATH_LIBRARY) mark_as_advanced(LUA_INCLUDE_DIR LUA_LIBRARIES LUA_LIBRARY LUA_MATH_LIBRARY)

@ -1,99 +0,0 @@
# Locate Lua library
# This module defines
# LUA54_FOUND, if false, do not try to link to Lua
# LUA_LIBRARIES
# LUA_INCLUDE_DIR, where to find lua.h
# LUA_VERSION_STRING, the version of Lua found (since CMake 2.8.8)
#
# Note that the expected include convention is
# #include "lua.h"
# and not
# #include <lua/lua.h>
# This is because, the lua location is not standardized and may exist
# in locations other than lua/
#=============================================================================
# Copyright 2007-2009 Kitware, Inc.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# (To distribute this file outside of CMake, substitute the full
# License text for the above reference.)
find_path(LUA_INCLUDE_DIR lua.h
HINTS
ENV LUA_DIR
PATH_SUFFIXES include/lua54 include/lua5.4 include/lua-5.4 include/lua include
PATHS
~/Library/Frameworks
/Library/Frameworks
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
)
FIND_LIBRARY(LUA_LIBRARY
NAMES lua54 lua5.4 lua-5.4 lua
HINTS
$ENV{LUA_DIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/sw
/opt/local
/opt/csw
/opt
)
FIND_LIBRARY(LUA_LIBRARY_DEBUG
NAMES lua54-d lua5.4-d lua-5.4-d lua-d lua54d lua5.4d lua-5.4d luad
HINTS
$ENV{LUA_DIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/sw
/opt/local
/opt/csw
/opt
)
if(LUA_LIBRARY)
# include the math library for Unix
if(UNIX AND NOT APPLE AND NOT BEOS)
find_library(LUA_MATH_LIBRARY m)
set( LUA_LIBRARIES "${LUA_LIBRARY};${LUA_MATH_LIBRARY}" CACHE STRING "Lua Libraries")
# For Windows and Mac, don't need to explicitly include the math library
else()
if (LUA_LIBRARY_DEBUG)
set( LUA_LIBRARIES optimized ${LUA_LIBRARY} debug ${LUA_LIBRARY_DEBUG} CACHE STRING "Lua Libraries")
else()
set( LUA_LIBRARIES "${LUA_LIBRARY}" CACHE STRING "Lua Libraries")
endif()
endif()
endif()
if(LUA_INCLUDE_DIR AND EXISTS "${LUA_INCLUDE_DIR}/lua.h")
file(STRINGS "${LUA_INCLUDE_DIR}/lua.h" lua_version_str REGEX "^#define[ \t]+LUA_RELEASE[ \t]+\"Lua .+\"")
string(REGEX REPLACE "^#define[ \t]+LUA_RELEASE[ \t]+\"Lua ([^\"]+)\".*" "\\1" LUA_VERSION_STRING "${lua_version_str}")
unset(lua_version_str)
endif()
include(FindPackageHandleStandardArgs)
# handle the QUIETLY and REQUIRED arguments and set LUA_FOUND to TRUE if
# all listed variables are TRUE
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Lua54
REQUIRED_VARS LUA_LIBRARIES LUA_INCLUDE_DIR
VERSION_VAR LUA_VERSION_STRING)
mark_as_advanced(LUA_INCLUDE_DIR LUA_LIBRARIES LUA_LIBRARY LUA_LIBRARY_DEBUG LUA_MATH_LIBRARY)

@ -10,32 +10,18 @@ MACRO(FIND_CORRECT_LUA_VERSION)
IF(LUABIND_LIBRARY_RELEASE MATCHES "\\.so") IF(LUABIND_LIBRARY_RELEASE MATCHES "\\.so")
INCLUDE(CheckDepends) INCLUDE(CheckDepends)
# check for Lua 5.4 # check for Lua 5.3
SET(LUA54_LIBRARIES liblua5.4 liblua-5.4 liblua.so.5.4) SET(LUA53_LIBRARIES liblua5.3 liblua-5.3 liblua.so.5.3)
FOREACH(_LIB ${LUA54_LIBRARIES}) FOREACH(_LIB ${LUA53_LIBRARIES})
CHECK_LINKED_LIBRARY(LUABIND_LIBRARY_RELEASE _LIB LUALIB_FOUND) CHECK_LINKED_LIBRARY(LUABIND_LIBRARY_RELEASE _LIB LUALIB_FOUND)
IF(LUALIB_FOUND) IF(LUALIB_FOUND)
MESSAGE(STATUS "Luabind is using Lua 5.4") MESSAGE(STATUS "Luabind is using Lua 5.3")
FIND_PACKAGE(Lua54 REQUIRED) FIND_PACKAGE(Lua53 REQUIRED)
BREAK() BREAK()
ENDIF() ENDIF()
ENDFOREACH() ENDFOREACH()
IF(NOT LUALIB_FOUND)
# check for Lua 5.3
SET(LUA53_LIBRARIES liblua5.3 liblua-5.3 liblua.so.5.3)
FOREACH(_LIB ${LUA53_LIBRARIES})
CHECK_LINKED_LIBRARY(LUABIND_LIBRARY_RELEASE _LIB LUALIB_FOUND)
IF(LUALIB_FOUND)
MESSAGE(STATUS "Luabind is using Lua 5.3")
FIND_PACKAGE(Lua53 REQUIRED)
BREAK()
ENDIF()
ENDFOREACH()
ENDIF()
IF(NOT LUALIB_FOUND) IF(NOT LUALIB_FOUND)
# check for Lua 5.2 # check for Lua 5.2
SET(LUA52_LIBRARIES liblua5.2 liblua-5.2 liblua.so.5.2) SET(LUA52_LIBRARIES liblua5.2 liblua-5.2 liblua.so.5.2)

@ -393,7 +393,6 @@ MACRO(NL_SETUP_RYZOM_DEFAULT_OPTIONS)
OPTION(WITH_LUA51 "Build Ryzom Core using Lua 5.1" ON ) OPTION(WITH_LUA51 "Build Ryzom Core using Lua 5.1" ON )
OPTION(WITH_LUA52 "Build Ryzom Core using Lua 5.2" OFF) OPTION(WITH_LUA52 "Build Ryzom Core using Lua 5.2" OFF)
OPTION(WITH_LUA53 "Build Ryzom Core using Lua 5.3" OFF) OPTION(WITH_LUA53 "Build Ryzom Core using Lua 5.3" OFF)
OPTION(WITH_LUA54 "Build Ryzom Core using Lua 5.4" OFF)
OPTION(WITH_RYZOM_CLIENT_UAC "Ask to run as Administrator" OFF) OPTION(WITH_RYZOM_CLIENT_UAC "Ask to run as Administrator" OFF)
OPTION(WITH_RYZOM_PATCH "Enable Ryzom in-game patch support" OFF) OPTION(WITH_RYZOM_PATCH "Enable Ryzom in-game patch support" OFF)
OPTION(WITH_RYZOM_CUSTOM_PATCH_SERVER "Only use patch server from CFG file" OFF) OPTION(WITH_RYZOM_CUSTOM_PATCH_SERVER "Only use patch server from CFG file" OFF)

@ -42,9 +42,6 @@
#cmakedefine RYZOM_WEBIG_MAIN_URL "${RYZOM_WEBIG_MAIN_URL}" #cmakedefine RYZOM_WEBIG_MAIN_URL "${RYZOM_WEBIG_MAIN_URL}"
#cmakedefine RYZOM_WEBIG_TRUSTED_DOMAIN "${RYZOM_WEBIG_TRUSTED_DOMAIN}" #cmakedefine RYZOM_WEBIG_TRUSTED_DOMAIN "${RYZOM_WEBIG_TRUSTED_DOMAIN}"
#cmakedefine RYZOM_CLIENT_RELEASENOTES_RING_URL "${RYZOM_CLIENT_RELEASENOTES_RING_URL}"
#cmakedefine RYZOM_CLIENT_RELEASENOTES_URL "${RYZOM_CLIENT_RELEASENOTES_URL}"
#cmakedefine AUTHOR "${AUTHOR}" #cmakedefine AUTHOR "${AUTHOR}"
#cmakedefine YEAR "${YEAR}" #cmakedefine YEAR "${YEAR}"
#cmakedefine COPYRIGHT "${COPYRIGHT}" #cmakedefine COPYRIGHT "${COPYRIGHT}"

@ -85,10 +85,7 @@ namespace NLGUI
/// Language code of the browser( e.g.: en, hu ) /// Language code of the browser( e.g.: en, hu )
std::string languageCode; std::string languageCode;
/// List of domains the widget can consider secure. /// List of domains the widget can consider secure.
std::vector<std::string> trustedDomains; std::vector< std::string > trustedDomains;
/// Web server
std::string webServer;
std::string webServerDomain;
/// Maximum concurrent MultiCurl connections per CGroupHTML instance /// Maximum concurrent MultiCurl connections per CGroupHTML instance
sint32 curlMaxConnections; sint32 curlMaxConnections;

@ -99,8 +99,6 @@ namespace NLGUI
// Get the number of active children // Get the number of active children
uint getNumActiveChildren() const; uint getNumActiveChildren() const;
uint getMaxElements() const { return _MaxElements; }
/** /**
* set the template that will be used to add text; * set the template that will be used to add text;
* \templ : a CViewText object. Only its font size, color and shadow are required. * \templ : a CViewText object. Only its font size, color and shadow are required.

@ -3,7 +3,7 @@
// //
// This source file has been modified by the following contributors: // This source file has been modified by the following contributors:
// Copyright (C) 2013-2014 Laszlo KIS-ADAM (dfighter) <dfighter1985@gmail.com> // Copyright (C) 2013-2014 Laszlo KIS-ADAM (dfighter) <dfighter1985@gmail.com>
// Copyright (C) 2019-2020 Jan BOON (Kaetemi) <jan.boon@kaetemi.be> // Copyright (C) 2019 Jan BOON (Kaetemi) <jan.boon@kaetemi.be>
// //
// This program is free software: you can redistribute it and/or modify // This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as // it under the terms of the GNU Affero General Public License as
@ -383,6 +383,7 @@ namespace NLGUI
void dummySet(const std::string &value); void dummySet(const std::string &value);
public: public:
// export some properties // export some properties
REFLECT_EXPORT_START(CInterfaceElement, CReflectable) REFLECT_EXPORT_START(CInterfaceElement, CReflectable)
REFLECT_BOOL ("active", getActive, setActive); REFLECT_BOOL ("active", getActive, setActive);
@ -397,7 +398,6 @@ namespace NLGUI
REFLECT_SINT32 ("h_real", getHReal, dummySet); REFLECT_SINT32 ("h_real", getHReal, dummySet);
REFLECT_STRING ("id", getIdByValue, dummySet); REFLECT_STRING ("id", getIdByValue, dummySet);
REFLECT_STRING ("sizeref", getSizeRefAsString, setSizeRef); REFLECT_STRING ("sizeref", getSizeRefAsString, setSizeRef);
REFLECT_STRING ("posparent", getPosParent, setPosParent);
REFLECT_LUA_METHOD("updateCoords", luaUpdateCoords); REFLECT_LUA_METHOD("updateCoords", luaUpdateCoords);
REFLECT_LUA_METHOD("invalidateCoords", luaInvalidateCoords); REFLECT_LUA_METHOD("invalidateCoords", luaInvalidateCoords);
REFLECT_LUA_METHOD("invalidateContent", luaInvalidateContent); REFLECT_LUA_METHOD("invalidateContent", luaInvalidateContent);
@ -524,8 +524,6 @@ namespace NLGUI
void parseSizeParent( const std::string &id ); void parseSizeParent( const std::string &id );
void setSizeParent( const std::string &id ); void setSizeParent( const std::string &id );
void getSizeParent( std::string &id ) const; void getSizeParent( std::string &id ) const;
std::string getPosParent() const;
void setSerializable( bool b ){ serializable = b; } void setSerializable( bool b ){ serializable = b; }
bool IsSerializable() const{ return serializable; } bool IsSerializable() const{ return serializable; }

@ -489,8 +489,6 @@ namespace NLGUI
uint8 getGlobalContainerAlpha() const { return _GlobalContainerAlpha; } uint8 getGlobalContainerAlpha() const { return _GlobalContainerAlpha; }
uint8 getGlobalRolloverFactorContent() const { return _GlobalRolloverFactorContent; } uint8 getGlobalRolloverFactorContent() const { return _GlobalRolloverFactorContent; }
uint8 getGlobalRolloverFactorContainer() const { return _GlobalRolloverFactorContainer; } uint8 getGlobalRolloverFactorContainer() const { return _GlobalRolloverFactorContainer; }
uint8 getContextHelpContentAlpha() const { return _ContextHelpContentAlpha; }
uint8 getContextHelpContainerAlpha() const { return _ContextHelpContainerAlpha; }
void updateGlobalAlphas(); void updateGlobalAlphas();
void resetGlobalAlphasProps(); void resetGlobalAlphasProps();
@ -610,16 +608,12 @@ namespace NLGUI
NLMISC::CCDBNodeLeaf *_GlobalContainerAlphaDB; NLMISC::CCDBNodeLeaf *_GlobalContainerAlphaDB;
NLMISC::CCDBNodeLeaf *_GlobalContentRolloverFactorDB; NLMISC::CCDBNodeLeaf *_GlobalContentRolloverFactorDB;
NLMISC::CCDBNodeLeaf *_GlobalContainerRolloverFactorDB; NLMISC::CCDBNodeLeaf *_GlobalContainerRolloverFactorDB;
NLMISC::CCDBNodeLeaf * _ContextHelpContentAlphaDB;
NLMISC::CCDBNodeLeaf * _ContextHelpContainerAlphaDB;
uint8 _ContainerAlpha; uint8 _ContainerAlpha;
uint8 _GlobalContentAlpha; uint8 _GlobalContentAlpha;
uint8 _GlobalContainerAlpha; uint8 _GlobalContainerAlpha;
uint8 _GlobalRolloverFactorContent; uint8 _GlobalRolloverFactorContent;
uint8 _GlobalRolloverFactorContainer; uint8 _GlobalRolloverFactorContainer;
uint8 _ContextHelpContentAlpha;
uint8 _ContextHelpContainerAlpha;
bool _MouseHandlingEnabled; bool _MouseHandlingEnabled;
@ -660,8 +654,6 @@ namespace NLGUI
bool _GroupSelection; bool _GroupSelection;
bool multiSelection; bool multiSelection;
uint32 _WidgetCount; uint32 _WidgetCount;
std::set<std::string> m_LoggedMissingElement;
}; };
} }

@ -412,13 +412,8 @@ public:
Exception(); Exception();
Exception(const std::string &reason); Exception(const std::string &reason);
Exception(const char *format, ...); Exception(const char *format, ...);
#if defined(NL_COMP_GCC) && (GCC_VERSION < 40800)
virtual ~Exception() throw() {}
virtual const char *what() const throw();
#else
virtual ~Exception() NL_OVERRIDE {} virtual ~Exception() NL_OVERRIDE {}
virtual const char *what() const throw() NL_OVERRIDE; virtual const char *what() const throw() NL_OVERRIDE;
#endif
}; };

@ -25,7 +25,6 @@
#include "debug.h" #include "debug.h"
#include "common.h" #include "common.h"
#include "stream.h" #include "stream.h"
#include "wang_hash.h"
namespace NLMISC { namespace NLMISC {
@ -578,7 +577,6 @@ public:
};*/ };*/
// Traits for hash_map using CEntityId // Traits for hash_map using CEntityId
#if 0
struct CEntityIdHashMapTraits struct CEntityIdHashMapTraits
{ {
enum { bucket_size = 4, min_buckets = 8 }; enum { bucket_size = 4, min_buckets = 8 };
@ -598,27 +596,7 @@ struct CEntityIdHashMapTraits
return id1.getShortId() < id2.getShortId(); return id1.getShortId() < id2.getShortId();
} }
}; };
#else
struct CEntityIdHashMapTraits
{
enum { bucket_size = 4, min_buckets = 8 };
CEntityIdHashMapTraits() { }
size_t operator() (const NLMISC::CEntityId &id ) const
{
uint64 hash64 = id.getUniqueId();
if (sizeof(size_t) == 8)
{
return (size_t)NLMISC::wangHash64(hash64);
}
else
{
uint32 hash32a = NLMISC::wangHash((uint32)(hash64 & 0xFFFFFFFF));
uint32 hash32b = NLMISC::wangHash((uint32)(hash64 >> 32));
return hash32a ^ hash32b;
}
}
};
#endif
/*inline std::stringstream &operator << (std::stringstream &__os, const CEntityId &__t) /*inline std::stringstream &operator << (std::stringstream &__os, const CEntityId &__t)
{ {

@ -41,11 +41,8 @@ struct EFile : public EStream
EFile (const std::string& filename) : EStream( "Unknown file error in '"+filename+"'" ), Filename(filename) {} EFile (const std::string& filename) : EStream( "Unknown file error in '"+filename+"'" ), Filename(filename) {}
EFile (const std::string& filename, const std::string& text, bool ) : EStream( text ), Filename(filename) {} EFile (const std::string& filename, const std::string& text, bool ) : EStream( text ), Filename(filename) {}
#if defined(NL_COMP_GCC) && (GCC_VERSION < 40800)
virtual ~EFile() throw() {}
#else
virtual ~EFile() NL_OVERRIDE {} virtual ~EFile() NL_OVERRIDE {}
#endif
std::string Filename; std::string Filename;
}; };

@ -81,12 +81,7 @@ struct EStream : public Exception
EStream( const IStream &f, const std::string& str ); EStream( const IStream &f, const std::string& str );
#if defined(NL_COMP_GCC) && (GCC_VERSION < 40800)
virtual ~EStream() throw() {}
#else
virtual ~EStream() NL_OVERRIDE {} virtual ~EStream() NL_OVERRIDE {}
#endif
// May Not be Filled... // May Not be Filled...
std::string StreamName; std::string StreamName;

@ -1,9 +1,6 @@
// NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/> // NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
// Copyright (C) 2010 Winch Gate Property Limited // Copyright (C) 2010 Winch Gate Property Limited
// //
// This source file has been modified by the following contributors:
// Copyright (C) 2020 Jan BOON (Kaetemi) <jan.boon@kaetemi.be>
//
// This program is free software: you can redistribute it and/or modify // This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as // it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the // published by the Free Software Foundation, either version 3 of the
@ -95,11 +92,6 @@ public:
/// exchange memory data /// exchange memory data
void swap(CMessage &other); void swap(CMessage &other);
#ifdef NL_CPP14
/// Move operator
CMessage &operator=(CMessage &&other) noexcept { swap(other); return *this; }
#endif
/// Sets the message type as a string and put it in the buffer if we are in writing mode /// Sets the message type as a string and put it in the buffer if we are in writing mode
void setType (const std::string &name, TMessageType type=OneWay); void setType (const std::string &name, TMessageType type=OneWay);

@ -244,7 +244,7 @@ private:
CCollisionOTStaticInfo *staticColInfo); CCollisionOTStaticInfo *staticColInfo);
// Add a trigger in the trigger array // Add a trigger in the trigger array
bool newTrigger (CMovePrimitive* first, CMovePrimitive* second, const CCollisionDesc& desc, uint triggerType); void newTrigger (CMovePrimitive* first, CMovePrimitive* second, const CCollisionDesc& desc, uint triggerType);
// Clear modified primitive list // Clear modified primitive list
void clearModifiedList (uint8 worldImage); void clearModifiedList (uint8 worldImage);

@ -251,28 +251,6 @@ public:
_Height=height; _Height=height;
} }
void setZFinalPosition(float pos)
{
_ZFinalPosition = pos;
}
float getZFinalPosition()
{
return _ZFinalPosition;
}
bool haveZOffset()
{
return _HaveZOffset;
}
void enableZOffset(bool enabled)
{
_HaveZOffset = enabled;
}
/** /**
* Set the cylinder size. Only for cylinder. * Set the cylinder size. Only for cylinder.
* *
@ -488,11 +466,6 @@ private:
// Iteration count // Iteration count
sint32 _IterationCount; sint32 _IterationCount;
float _ZOffset;
float _ZFinalPosition;
bool _HaveZOffset;
}; };
} // NLPACS } // NLPACS

@ -114,12 +114,6 @@ public:
* This is an overlap trigger. This trigger is actived each time the object overlap the trigger. * This is an overlap trigger. This trigger is actived each time the object overlap the trigger.
*/ */
OverlapTrigger=0x400, OverlapTrigger=0x400,
/**
* This is an stairs trigger. This trigger is actived each time the object overlap the trigger and change Z position.
*/
OverlapStairsTrigger=0x800,
}; };
/** /**
@ -280,14 +274,6 @@ public:
*/ */
virtual float getHeight () const =0; virtual float getHeight () const =0;
virtual void setZFinalPosition(float pos) =0;
virtual float getZFinalPosition() =0;
virtual bool haveZOffset() =0;
virtual void enableZOffset(bool enabled) =0;
/** /**
* Set the cylinder size. Only for cylinder. * Set the cylinder size. Only for cylinder.
* *

@ -52,12 +52,8 @@ public:
/// filePath: [out] ex. /games/nel/stream/00/00/000000000.. /// filePath: [out] ex. /games/nel/stream/00/00/000000000..
/// hash: [in] /// hash: [in]
/// name: [in] name for debugging purposes /// name: [in] name for debugging purposes
#if defined(NL_COMP_GCC) && (GCC_VERSION < 40800) virtual bool getFile(std::string &filePath, const NLMISC::CHashKey &hash, const std::string &name) NL_OVERRIDE;
virtual bool getFile(std::string &filePath, const NLMISC::CHashKey &hash, const std::string &name);
#else
virtual bool getFile(std::string &filePath, const NLMISC::CHashKey &hash, const std::string &name) NL_OVERRIDE;
#endif
public: public:
/// Set storage path (ex. stream/) /// Set storage path (ex. stream/)
std::string Path; std::string Path;
@ -65,7 +61,7 @@ public:
/// Loads a package into the package manager (ex. http://cdn.ryzom.dev/open/stream/) /// Loads a package into the package manager (ex. http://cdn.ryzom.dev/open/stream/)
typedef std::vector<std::string> THosts; typedef std::vector<std::string> THosts;
THosts Hosts; THosts Hosts;
}; /* class CHttpPackageProvider */ }; /* class CHttpPackageProvider */
} /* namespace NLMISC */ } /* namespace NLMISC */

@ -1,7 +1,7 @@
/** \file driver_direct3d_pixel_program.cpp /** \file driver_direct3d_pixel_program.cpp
* Direct 3d driver implementation * Direct 3d driver implementation
* *
* $Id$ * $Id: driver_direct3d_pixel_program.cpp,v 1.1.2.4 2007/07/09 15:26:35 legallo Exp $
* *
* \todo manage better the init/release system (if a throw occurs in the init, we must release correctly the driver) * \todo manage better the init/release system (if a throw occurs in the init, we must release correctly the driver)
*/ */

@ -1,7 +1,7 @@
/** \file driver_opengl_pixel_program.cpp /** \file driver_opengl_pixel_program.cpp
* OpenGL driver implementation for pixel program manipulation. * OpenGL driver implementation for pixel program manipulation.
* *
* $Id$ * $Id: driver_opengl_pixel_program.cpp,v 1.1.2.4 2007/07/09 15:29:00 legallo Exp $
* *
* \todo manage better the init/release system (if a throw occurs in the init, we must release correctly the driver) * \todo manage better the init/release system (if a throw occurs in the init, we must release correctly the driver)
*/ */

@ -428,7 +428,7 @@ namespace NLGUI
if (bg.repeatX == CSS_VALUE_ROUND) if (bg.repeatX == CSS_VALUE_ROUND)
{ {
sint numTiles = std::max(1, (sint)std::ceil(((float)areaW / texW) - 0.5f)); sint numTiles = std::max(1, (sint)std::round((float)areaW / texW));
texW = areaW / numTiles; texW = areaW / numTiles;
if (bg.height.isAuto() && bg.repeatY != CSS_VALUE_ROUND) if (bg.height.isAuto() && bg.repeatY != CSS_VALUE_ROUND)
{ {
@ -439,7 +439,7 @@ namespace NLGUI
if (bg.repeatY == CSS_VALUE_ROUND) if (bg.repeatY == CSS_VALUE_ROUND)
{ {
sint numTiles = std::max(1, (sint)std::ceil(((float)areaH / texH) - 0.5f)); sint numTiles = std::max(1, (sint)std::round((float)areaH / texH));
texH = areaH / numTiles; texH = areaH / numTiles;
if (bg.width.isAuto() && bg.repeatX != CSS_VALUE_ROUND) if (bg.width.isAuto() && bg.repeatX != CSS_VALUE_ROUND)
{ {

@ -30,10 +30,9 @@ namespace NLGUI
bool CSSLength::parseValue(const std::string &value, bool allowPercent, bool allowNegative) bool CSSLength::parseValue(const std::string &value, bool allowPercent, bool allowNegative)
{ {
static const std::string knownUnitsArr[] = { static const std::set<std::string> knownUnits = {
"%", "rem", "em", "px", "pt", "vw", "vh", "vi", "vb", "vmin", "vmax" "%", "rem", "em", "px", "pt", "vw", "vh", "vi", "vb", "vmin", "vmax"
}; };
static const std::set<std::string> knownUnits(knownUnitsArr, &knownUnitsArr[sizeof(knownUnitsArr) / sizeof(knownUnitsArr[0])]);
std::string::size_type pos = 0; std::string::size_type pos = 0;
std::string::size_type len = value.size(); std::string::size_type len = value.size();

@ -408,11 +408,8 @@ namespace NLGUI
// Check if domain is on TrustedDomain // Check if domain is on TrustedDomain
bool CGroupHTML::isTrustedDomain(const string &domain) bool CGroupHTML::isTrustedDomain(const string &domain)
{ {
if (domain == options.webServerDomain)
return true;
vector<string>::iterator it; vector<string>::iterator it;
it = find(options.trustedDomains.begin(), options.trustedDomains.end(), domain); it = find ( options.trustedDomains.begin(), options.trustedDomains.end(), domain);
return it != options.trustedDomains.end(); return it != options.trustedDomains.end();
} }
@ -3424,16 +3421,6 @@ namespace NLGUI
string finalUrl; string finalUrl;
bool isLocal = lookupLocalFile (finalUrl, _URL.c_str(), true); bool isLocal = lookupLocalFile (finalUrl, _URL.c_str(), true);
if (!isLocal && _URL.c_str()[0] == '/')
{
if (options.webServer.empty())
{
// Try again later
return;
}
finalUrl = options.webServer + finalUrl;
}
_URL = finalUrl; _URL = finalUrl;
CUrlParser uri (_URL); CUrlParser uri (_URL);

@ -438,14 +438,6 @@ namespace NLGUI
parseSizeRef(sizeref.c_str()); parseSizeRef(sizeref.c_str());
} }
// ------------------------------------------------------------------------------------------------
std::string CInterfaceElement::getPosParent() const
{
std::string id;
getPosParent(id);
return id;
}
// ------------------------------------------------------------------------------------------------ // ------------------------------------------------------------------------------------------------
std::string CInterfaceElement::getSizeRefAsString() const std::string CInterfaceElement::getSizeRefAsString() const
{ {

@ -208,10 +208,9 @@ namespace NLGUI
// *************************************************************************** // ***************************************************************************
bool getCssLength (float &value, std::string &unit, const std::string &str, bool neg) bool getCssLength (float &value, std::string &unit, const std::string &str, bool neg)
{ {
static const std::string knownUnitsArr[] = { static const std::set<std::string> knownUnits = {
"%", "rem", "em", "px", "pt", "vw", "vh", "vi", "vb", "vmin", "vmax" "%", "rem", "em", "px", "pt", "vw", "vh", "vi", "vb", "vmin", "vmax"
}; };
static const std::set<std::string> knownUnits(knownUnitsArr, &knownUnitsArr[sizeof(knownUnitsArr) / sizeof(knownUnitsArr[0])]);
std::string::size_type pos = 0; std::string::size_type pos = 0;
std::string::size_type len = str.size(); std::string::size_type len = str.size();

File diff suppressed because it is too large Load Diff

@ -435,22 +435,7 @@ namespace NLGUI
CWidgetManager::SMasterGroup &rMG = _MasterGroups[nMasterGroup]; CWidgetManager::SMasterGroup &rMG = _MasterGroups[nMasterGroup];
CInterfaceElement *pIEL = rMG.Group->getElement (sEltId); CInterfaceElement *pIEL = rMG.Group->getElement (sEltId);
if (pIEL != NULL) if (pIEL != NULL)
{
#if !FINAL_VERSION
if (m_LoggedMissingElement.find(sEltId) != m_LoggedMissingElement.end())
{
m_LoggedMissingElement.erase(sEltId);
nlwarning("Previously missing UI element with Id '%s' was now found!", sEltId.c_str());
}
#endif
return pIEL; return pIEL;
}
}
if (m_LoggedMissingElement.find(sEltId) == m_LoggedMissingElement.end())
{
m_LoggedMissingElement.insert(sEltId);
nlwarning("Could not find UI element from Id '%s'...", sEltId.c_str());
} }
return NULL; return NULL;
} }
@ -1794,69 +1779,33 @@ namespace NLGUI
getWindowForActiveMasterGroup(_CurCtrlContextHelp->getContextHelpWindowName()); getWindowForActiveMasterGroup(_CurCtrlContextHelp->getContextHelpWindowName());
if(groupContextHelp) if(groupContextHelp)
{ {
/** If there's a modal box around, should be sure that the context help doesn't intersect it. /** If there's a modal box around, should be sure that the context help doesn't intersect it.
* If this is the case, we just disable it, unless the tooltip was generated by the current modal window * If this is the case, we just disable it, unless the tooltip was generated by the current modal window
*/ */
bool draw = false;
if ( hasModal() ) if ( hasModal() )
{ {
CInterfaceGroup *mw = getModal().ModalWindow; CInterfaceGroup *mw = getModal().ModalWindow;
if (mw && mw->isIn(*groupContextHelp)) if (mw && mw->isIn(*groupContextHelp))
{ {
if (_CurCtrlContextHelp->isSonOf(mw)) if (_CurCtrlContextHelp->isSonOf(mw))
draw = true; {
groupContextHelp->executeLuaScriptOnDraw();
groupContextHelp->draw ();
// flush layers
CViewRenderer::getInstance()->flush();
}
} }
else else
draw = true;
}
else
draw = true;
if (draw) {
// apply opacity settings
const std::vector< CViewBase* > &vs = groupContextHelp->getViews();
// content opacity: only target views or else breaks
for( uint i = 0; i < vs.size(); ++i)
{ {
CViewBase *pVB = vs[i]; groupContextHelp->executeLuaScriptOnDraw();
pVB->setAlpha(_ContextHelpContentAlpha); groupContextHelp->draw ();
// flush layers
CViewRenderer::getInstance()->flush();
} }
// go into sub groups and apply opacity to views and controls (this is mainly for crystallized_spell_context_help) }
const std::vector<CInterfaceGroup*> &rG = groupContextHelp->getGroups(); else
if (!rG.empty()) { {
for(uint i = 0; i < rG.size(); ++i) {
const std::vector< CInterfaceGroup* > &vs = rG[i]->getGroups();
if (!vs.empty()) {
for( uint j = 0; j < vs.size(); ++j)
{
const std::vector< CViewBase* > &vb = vs[j]->getViews();
if (!vb.empty()) {
for( uint k = 0; k < vb.size(); ++k)
{
CViewBase *pVB = vb[k];
pVB->setAlpha(_ContextHelpContentAlpha);
}
}
}
}
const std::vector< CViewBase* > &vb = rG[i]->getViews();
if (!vb.empty()) {
for( uint k = 0; k < vb.size(); ++k)
{
CViewBase *pVB = vb[k];
pVB->setAlpha(_ContextHelpContentAlpha);
}
}
}
}
// container opacity
CInterfaceGroup* container = dynamic_cast<CInterfaceGroup*>(groupContextHelp->findFromShortId("border"));
if (container)
container->setAlpha(_ContextHelpContainerAlpha);
// draw the tooltip
groupContextHelp->executeLuaScriptOnDraw(); groupContextHelp->executeLuaScriptOnDraw();
groupContextHelp->draw (); groupContextHelp->draw ();
// flush layers // flush layers
@ -2355,16 +2304,16 @@ namespace NLGUI
SModalWndInfo mwi = getModal(); SModalWndInfo mwi = getModal();
if (mwi.ModalExitKeyPushed) if (mwi.ModalExitKeyPushed)
disableModalWindow(); disableModalWindow();
handled= true;
} }
}
// Manage "quit window" If the Key is ESCAPE, no captureKeyboard
if( eventDesc.getKeyEventType() == CEventDescriptorKey::keydown && eventDesc.getKey() == NLMISC::KeyESCAPE )
{
// Get the last escapable active top window. NB: this is ergonomically better.
CInterfaceGroup *win= getLastEscapableTopWindow(); CInterfaceGroup *win= getLastEscapableTopWindow();
if ( win ) if( win )
{ {
// Manage "quit window" If the Key is ESCAPE, no captureKeyboard
// Get the last escapable active top window. NB: this is ergonomically better.
// If the window is a modal, must pop it. // If the window is a modal, must pop it.
if( dynamic_cast<CGroupModal*>(win) ) if( dynamic_cast<CGroupModal*>(win) )
{ {
@ -2450,13 +2399,7 @@ namespace NLGUI
} }
} }
if (eventDesc.getKeyEventType() == CEventDescriptorKey::keydown && eventDesc.getKey() == NLMISC::KeyESCAPE && !handled && !isKeyboardCaptured()) // General case: handle it in the Captured keyboard
{
CAHManager::getInstance()->runActionHandler("enter_modal", NULL, "group=ui:interface:quit_dialog");
handled = true;
}
// General case: handle it in the Captured keyboard
if ( getCaptureKeyboard() != NULL && !handled) if ( getCaptureKeyboard() != NULL && !handled)
{ {
bool result = getCaptureKeyboard()->handleEvent(evnt); bool result = getCaptureKeyboard()->handleEvent(evnt);
@ -3395,17 +3338,11 @@ namespace NLGUI
nlassert(_GlobalContentRolloverFactorDB); nlassert(_GlobalContentRolloverFactorDB);
_GlobalContainerRolloverFactorDB = CDBManager::getInstance()->getDbProp("UI:SAVE:CONTAINER_ROLLOVER_FACTOR"); _GlobalContainerRolloverFactorDB = CDBManager::getInstance()->getDbProp("UI:SAVE:CONTAINER_ROLLOVER_FACTOR");
nlassert(_GlobalContainerRolloverFactorDB); nlassert(_GlobalContainerRolloverFactorDB);
_ContextHelpContentAlphaDB = CDBManager::getInstance()->getDbProp("UI:SAVE:CONTEXT_HELP_CONTENT_ALPHA");
nlassert(_ContextHelpContentAlphaDB);
_ContextHelpContainerAlphaDB = CDBManager::getInstance()->getDbProp("UI:SAVE:CONTEXT_HELP_CONTAINER_ALPHA");
nlassert(_ContextHelpContainerAlphaDB);
} }
_GlobalContentAlpha = (uint8)_GlobalContentAlphaDB->getValue32(); _GlobalContentAlpha = (uint8)_GlobalContentAlphaDB->getValue32();
_GlobalContainerAlpha = (uint8)_GlobalContainerAlphaDB->getValue32(); _GlobalContainerAlpha = (uint8)_GlobalContainerAlphaDB->getValue32();
_GlobalRolloverFactorContent = (uint8)_GlobalContentRolloverFactorDB->getValue32(); _GlobalRolloverFactorContent = (uint8)_GlobalContentRolloverFactorDB->getValue32();
_GlobalRolloverFactorContainer = (uint8)_GlobalContainerRolloverFactorDB->getValue32(); _GlobalRolloverFactorContainer = (uint8)_GlobalContainerRolloverFactorDB->getValue32();
_ContextHelpContentAlpha = (uint8)_ContextHelpContentAlphaDB->getValue32();
_ContextHelpContainerAlpha = (uint8)_ContextHelpContainerAlphaDB->getValue32();
} }
void CWidgetManager::resetGlobalAlphasProps() void CWidgetManager::resetGlobalAlphasProps()
@ -3414,8 +3351,6 @@ namespace NLGUI
_GlobalContainerAlphaDB = NULL; _GlobalContainerAlphaDB = NULL;
_GlobalContentRolloverFactorDB = NULL; _GlobalContentRolloverFactorDB = NULL;
_GlobalContainerRolloverFactorDB = NULL; _GlobalContainerRolloverFactorDB = NULL;
_ContextHelpContentAlphaDB = NULL;
_ContextHelpContainerAlphaDB = NULL;
} }
void CWidgetManager::registerNewScreenSizeHandler( INewScreenSizeHandler *handler ) void CWidgetManager::registerNewScreenSizeHandler( INewScreenSizeHandler *handler )
@ -3949,8 +3884,6 @@ namespace NLGUI
_GlobalRolloverFactorContent = 255; _GlobalRolloverFactorContent = 255;
_GlobalRolloverFactorContainer = 255; _GlobalRolloverFactorContainer = 255;
_AlphaRolloverSpeedDB = NULL; _AlphaRolloverSpeedDB = NULL;
_ContextHelpContentAlpha = 255;
_ContextHelpContainerAlpha = 255;
_MouseHandlingEnabled = true; _MouseHandlingEnabled = true;
_MouseOverWindow = false; _MouseOverWindow = false;

@ -17,7 +17,6 @@
// You should have received a copy of the GNU Affero General Public License // You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>. // along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "stdmisc.h"
#include <nel/misc/seven_zip.h> #include <nel/misc/seven_zip.h>
#include <nel/misc/types_nl.h> #include <nel/misc/types_nl.h>

@ -266,14 +266,9 @@ void uncbServiceIdentification(CMessage &msgin, TSockId from, CCallbackNetBase &
nlinfo ("HNETL5: + connect ident '%s' %s-%hu pos %hu ext %d", from->asString().c_str(), inSName.c_str(), inSid.get(), (uint16)pos, (uint8)isExternal); nlinfo ("HNETL5: + connect ident '%s' %s-%hu pos %hu ext %d", from->asString().c_str(), inSName.c_str(), inSid.get(), (uint16)pos, (uint8)isExternal);
if (isExternal) if(isExternal)
{ {
nlassert (pos == 0);
#ifdef NL_OS_WINDOWS
pos = 0;
#else
nlassert(pos == 0);
#endif
} }
if (inSid.get() == 0) if (inSid.get() == 0)

@ -918,10 +918,8 @@ bool CMoveContainer::evalPrimAgainstPrimCollision (double beginTime, CMovePrimit
|| (otherPrimitive->getTriggerType()&UMovePrimitive::EnterTrigger)); || (otherPrimitive->getTriggerType()&UMovePrimitive::EnterTrigger));
bool exit = (beginTime<=lastTime) && (lastTime<_DeltaTime) && ((primitive->getTriggerType()&UMovePrimitive::ExitTrigger) bool exit = (beginTime<=lastTime) && (lastTime<_DeltaTime) && ((primitive->getTriggerType()&UMovePrimitive::ExitTrigger)
|| (otherPrimitive->getTriggerType()&UMovePrimitive::ExitTrigger)); || (otherPrimitive->getTriggerType()&UMovePrimitive::ExitTrigger));
bool overlap = ((firstTime<=beginTime) && (lastTime>_DeltaTime) && ((primitive->getTriggerType()&UMovePrimitive::OverlapTrigger) bool overlap = (firstTime<=beginTime) && (lastTime>_DeltaTime) && ((primitive->getTriggerType()&UMovePrimitive::OverlapTrigger)
|| (otherPrimitive->getTriggerType()&UMovePrimitive::OverlapTrigger)) || || (otherPrimitive->getTriggerType()&UMovePrimitive::OverlapTrigger));
(firstTime<=beginTime) && (lastTime>_DeltaTime) && ((primitive->getTriggerType()&UMovePrimitive::OverlapStairsTrigger)
|| (otherPrimitive->getTriggerType()&UMovePrimitive::OverlapStairsTrigger)));
bool contact = ( beginTime<((firstTime+lastTime)/2) ) && (firstTime<=_DeltaTime); bool contact = ( beginTime<((firstTime+lastTime)/2) ) && (firstTime<=_DeltaTime);
bool collision = contact && (primitive->isObstacle() && otherPrimitive->isObstacle ()); bool collision = contact && (primitive->isObstacle() && otherPrimitive->isObstacle ());
@ -1213,7 +1211,7 @@ void CMoveContainer::newCollision (CMovePrimitive* first, const CCollisionSurfac
// *************************************************************************** // ***************************************************************************
bool CMoveContainer::newTrigger (CMovePrimitive* first, CMovePrimitive* second, const CCollisionDesc& desc, uint triggerType) void CMoveContainer::newTrigger (CMovePrimitive* first, CMovePrimitive* second, const CCollisionDesc& desc, uint triggerType)
{ {
// Element index // Element index
uint index=(uint)_Triggers.size(); uint index=(uint)_Triggers.size();
@ -1226,14 +1224,6 @@ bool CMoveContainer::newTrigger (CMovePrimitive* first, CMovePrimitive* second,
_Triggers[index].Object1=second->UserData; _Triggers[index].Object1=second->UserData;
_Triggers[index].CollisionDesc=desc; _Triggers[index].CollisionDesc=desc;
_Triggers[index].CollisionType = uint8(triggerType); _Triggers[index].CollisionType = uint8(triggerType);
if (second->_StaticFlags&UMovePrimitive::OverlapStairsTrigger) {
nlinfo("Col Stairs height %f", second->getHeight());
return true;
}
return false;
} }
// *************************************************************************** // ***************************************************************************
@ -1669,17 +1659,8 @@ void CMoveContainer::reaction (const CCollisionOTInfo& first)
newTrigger (dynInfo->getFirstPrimitive (), dynInfo->getSecondPrimitive (), dynInfo->getCollisionDesc (), UTriggerInfo::In); newTrigger (dynInfo->getFirstPrimitive (), dynInfo->getSecondPrimitive (), dynInfo->getCollisionDesc (), UTriggerInfo::In);
if (dynInfo->isExit()) if (dynInfo->isExit())
newTrigger (dynInfo->getFirstPrimitive (), dynInfo->getSecondPrimitive (), dynInfo->getCollisionDesc (), UTriggerInfo::Out); newTrigger (dynInfo->getFirstPrimitive (), dynInfo->getSecondPrimitive (), dynInfo->getCollisionDesc (), UTriggerInfo::Out);
if (dynInfo->isInside()) { if (dynInfo->isInside())
if (newTrigger (dynInfo->getFirstPrimitive (), dynInfo->getSecondPrimitive (), dynInfo->getCollisionDesc (), UTriggerInfo::Inside)) newTrigger (dynInfo->getFirstPrimitive (), dynInfo->getSecondPrimitive (), dynInfo->getCollisionDesc (), UTriggerInfo::Inside);
{
dynInfo->getFirstPrimitive()->enableZOffset(true);
CVectorD first_pos = dynInfo->getFirstPrimitive()->getFinalPosition(dynInfo->getFirstWorldImage());
CVectorD second_pos = dynInfo->getSecondPrimitive()->getFinalPosition(dynInfo->getSecondWorldImage());
dynInfo->getFirstPrimitive()->setZFinalPosition(second_pos.z+dynInfo->getSecondPrimitive()->getHeight()-10.0f);
}
}
if (dynInfo->isExit())
newTrigger (dynInfo->getFirstPrimitive (), dynInfo->getSecondPrimitive (), dynInfo->getCollisionDesc (), UTriggerInfo::Out);
} }
} }
} }

@ -49,8 +49,6 @@ CMovePrimitive::CMovePrimitive (CMoveContainer* container, uint8 firstWorldImage
_StaticFlags=0; _StaticFlags=0;
_RootOTInfo=NULL; _RootOTInfo=NULL;
_LastTestTime=0xffffffff; _LastTestTime=0xffffffff;
_ZOffset = 0;
_HaveZOffset = false;
// Ptr table alloc // Ptr table alloc
_WorldImages=_Container->allocateWorldImagesPtrs (numWorldImage); _WorldImages=_Container->allocateWorldImagesPtrs (numWorldImage);
@ -151,11 +149,6 @@ bool CMovePrimitive::isTriggered (CMovePrimitive& second, bool enter, bool exit)
{ {
// Generate a trigger ? // Generate a trigger ?
// Is one of them is a stairs trigger ?
if ( second._StaticFlags&OverlapStairsTrigger )
return true;
// Is the two are not triggers ? // Is the two are not triggers ?
if ( ( (_StaticFlags&TriggerMask) == NotATrigger ) && ( (second._StaticFlags&TriggerMask) == NotATrigger ) ) if ( ( (_StaticFlags&TriggerMask) == NotATrigger ) && ( (second._StaticFlags&TriggerMask) == NotATrigger ) )
return false; return false;

@ -262,7 +262,7 @@ void CSound::importForm(const std::string& filename, NLGEORGES::UFormElm& roo
_GroupController = CGroupControllerRoot::getInstance()->getGroupController(NLSOUND_SHEET_V1_DEFAULT_SOUND_GROUP_CONTROLLER); _GroupController = CGroupControllerRoot::getInstance()->getGroupController(NLSOUND_SHEET_V1_DEFAULT_SOUND_GROUP_CONTROLLER);
#else #else
std::string groupControllerPath; std::string groupControllerPath;
root.getValueByName(groupControllerPath, ".GroupController"); root.getValueByName(groupControllerPath, ".GroupControllerPath");
_GroupController = CGroupControllerRoot::getInstance()->getGroupController(groupControllerPath); _GroupController = CGroupControllerRoot::getInstance()->getGroupController(groupControllerPath);
#endif #endif

@ -1,16 +1,16 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build anim : optimze >> log.log echo --- Build anim : optimze >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build anim : optimze echo --- Build anim : optimze
echo ------- echo -------
date >> log.log date >> log.log
date date
# Execute the build # Execute the build
anim_builder.exe anim_export anim ../../cfg/properties.cfg anim_builder.exe anim_export anim ../../cfg/properties.cfg

@ -1,57 +1,57 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export animation files (.anim) from Max # *** Export animation files (.anim) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "anim_export_timeout" | sed -e 's/anim_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "anim_export_timeout" | sed -e 's/anim_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the anim directories # Get the anim directories
anim_source_directories=`cat ../../cfg/directories.cfg | grep "anim_source_directory" | sed -e 's/anim_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` anim_source_directories=`cat ../../cfg/directories.cfg | grep "anim_source_directory" | sed -e 's/anim_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export animation >> log.log echo --- Export animation >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export animation echo --- Export animation
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $anim_source_directories ; do for i in $anim_source_directories ; do
# Copy the script # Copy the script
cat maxscript/anim_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/anim/log.log&g" | sed -e "s&anim_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/anim/anim_export&g" > $max_directory/scripts/anim_export.ms cat maxscript/anim_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/anim/log.log&g" | sed -e "s&anim_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/anim/anim_export&g" > $max_directory/scripts/anim_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript anim_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript anim_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript anim_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript anim_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript anim_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript anim_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install anim in the client data # Install anim in the client data
# Get the anim install directory # Get the anim install directory
anim_install_directory=`cat ../../cfg/directories.cfg | grep "anim_install_directory" | sed -e 's/anim_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` anim_install_directory=`cat ../../cfg/directories.cfg | grep "anim_install_directory" | sed -e 's/anim_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install animation >> log.log echo --- Install animation >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install animation echo --- Install animation
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R anim/. $client_directory/$anim_install_directory 2>> log.log cp -u -p -R anim/. $client_directory/$anim_install_directory 2>> log.log

@ -1,26 +1,26 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build clod : build .clodbank >> log.log echo --- Build clod : build .clodbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build clod : build .clodbank echo --- Build clod : build .clodbank
echo ------- echo -------
date >> log.log date >> log.log
date date
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the lod config file in the database # Get the lod config file in the database
clod_config_file=`cat ../../cfg/config.cfg | grep "clod_config_file" | sed -e 's/clod_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'` clod_config_file=`cat ../../cfg/config.cfg | grep "clod_config_file" | sed -e 's/clod_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the Lod character bank name # Get the Lod character bank name
clod_bank_file_name=`cat ../../cfg/config.cfg | grep "clod_bank_file_name" | sed -e 's/clod_bank_file_name//' | sed -e 's/ //g' | sed -e 's/=//g'` clod_bank_file_name=`cat ../../cfg/config.cfg | grep "clod_bank_file_name" | sed -e 's/clod_bank_file_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Execute the build # Execute the build
build_clod_bank.exe cfg/local_path.cfg $database_directory/$clod_config_file clodbank/$clod_bank_file_name build_clod_bank.exe cfg/local_path.cfg $database_directory/$clod_config_file clodbank/$clod_bank_file_name

@ -1,60 +1,60 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export character lod shape files (.clod) from Max # *** Export character lod shape files (.clod) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "shape_export_timeout" | sed -e 's/shape_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "shape_export_timeout" | sed -e 's/shape_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the shape directories # Get the shape directories
clod_source_directories=`cat ../../cfg/directories.cfg | grep "clod_source_directory" | sed -e 's/clod_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` clod_source_directories=`cat ../../cfg/directories.cfg | grep "clod_source_directory" | sed -e 's/clod_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export clod >> log.log echo --- Export clod >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export clod echo --- Export clod
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $clod_source_directories ; do for i in $clod_source_directories ; do
# Copy the script # Copy the script
cat maxscript/clod_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/clodbank/log.log&g" | sed -e "s&shape_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_clod&$build_gamedata_directory/processes/clodbank/clod&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/clodbank/tag&g" > $max_directory/scripts/clod_export.ms cat maxscript/clod_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/clodbank/log.log&g" | sed -e "s&shape_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_clod&$build_gamedata_directory/processes/clodbank/clod&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/clodbank/tag&g" > $max_directory/scripts/clod_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install clodbank in the client data, in the "shapes/" directory # Install clodbank in the client data, in the "shapes/" directory
# Get the shape install directory # Get the shape install directory
shape_install_directory=`cat ../../cfg/directories.cfg | grep "shape_install_directory" | sed -e 's/shape_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` shape_install_directory=`cat ../../cfg/directories.cfg | grep "shape_install_directory" | sed -e 's/shape_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install clodbank >> log.log echo --- Install clodbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install clodbank echo --- Install clodbank
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R clodbank/. $client_directory/$shape_install_directory 2>> log.log cp -u -p -R clodbank/. $client_directory/$shape_install_directory 2>> log.log

@ -1,29 +1,29 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export displace tile (.tga) # *** Export displace tile (.tga)
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the displace directories # Get the displace directories
displace_source_directories=`cat ../../cfg/directories.cfg | grep "displace_source_directories" | sed -e 's/displace_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` displace_source_directories=`cat ../../cfg/directories.cfg | grep "displace_source_directories" | sed -e 's/displace_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export displace >> log.log echo --- Export displace >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export displace echo --- Export displace
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each displace directory # For each displace directory
for i in $displace_source_directories ; do for i in $displace_source_directories ; do
# Copy # Copy
cp -u -p $database_directory/$i/*.[tT][gG][aA] tga 2>> log.log cp -u -p $database_directory/$i/*.[tT][gG][aA] tga 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the displace in the client data # Install the displace in the client data
# Get the displace install directory # Get the displace install directory
displace_install_directory=`cat ../../cfg/directories.cfg | grep "displace_install_directory" | sed -e 's/displace_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` displace_install_directory=`cat ../../cfg/directories.cfg | grep "displace_install_directory" | sed -e 's/displace_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install displace >> log.log echo --- Install displace >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install displace echo --- Install displace
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R tga/. $client_directory/$displace_install_directory 2>> log.log cp -u -p -R tga/. $client_directory/$displace_install_directory 2>> log.log

@ -1,89 +1,89 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Build the farbank # Build the farbank
build_farbank='build_far_bank.exe' build_farbank='build_far_bank.exe'
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "farbank_build_timeout" | sed -e 's/farbank_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "farbank_build_timeout" | sed -e 's/farbank_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the tiles root directories # Get the tiles root directories
tile_root_source_directory=`cat ../../cfg/directories.cfg | grep "tile_root_source_directory" | sed -e 's/tile_root_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` tile_root_source_directory=`cat ../../cfg/directories.cfg | grep "tile_root_source_directory" | sed -e 's/tile_root_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the extension list # Get the extension list
multiple_tiles_postfix=`cat ../../cfg/config.cfg | grep "multiple_tiles_postfix" | sed -e 's/multiple_tiles_postfix//' | sed -e 's/ //g' | sed -e 's/=//g'` multiple_tiles_postfix=`cat ../../cfg/config.cfg | grep "multiple_tiles_postfix" | sed -e 's/multiple_tiles_postfix//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build farbank >> log.log echo --- Build farbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build farbank echo --- Build farbank
echo ------- echo -------
date >> log.log date >> log.log
date date
# list all the bank # list all the bank
bank_list=`ls -1 ../smallbank/smallbank/*.[sS][mM][aA][lL][lL][bB][aA][nN][kK]` bank_list=`ls -1 ../smallbank/smallbank/*.[sS][mM][aA][lL][lL][bB][aA][nN][kK]`
# For each bank # For each bank
for i in $bank_list ; do for i in $bank_list ; do
if ( test "$multiple_tiles_postfix" ) then if ( test "$multiple_tiles_postfix" ) then
for j in $multiple_tiles_postfix ; do for j in $multiple_tiles_postfix ; do
# Destination the name # Destination the name
dest=`echo $i | sed -e "s&\.smallbank&\$j.farbank&g" | sed -e 's&../smallbank/smallbank&farbank&g'` dest=`echo $i | sed -e "s&\.smallbank&\$j.farbank&g" | sed -e 's&../smallbank/smallbank&farbank&g'`
echo $i echo $i
echo $dest echo $dest
# Make the dependencies # Make the dependencies
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
$exec_timeout $timeout $build_farbank $i $dest -d$database_directory/$tile_root_source_directory$j/ -p$j $exec_timeout $timeout $build_farbank $i $dest -d$database_directory/$tile_root_source_directory$j/ -p$j
if ( test -e $dest ) if ( test -e $dest )
then then
echo OK $dest >> log.log echo OK $dest >> log.log
else else
echo ERROR building $dest >> log.log echo ERROR building $dest >> log.log
fi fi
else else
echo SKIPPED $dest >> log.log echo SKIPPED $dest >> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
else else
# Destination the name # Destination the name
dest=`echo $i | sed -e 's&\.smallbank&\.farbank&g' | sed -e 's&../smallbank/smallbank&farbank&g'` dest=`echo $i | sed -e 's&\.smallbank&\.farbank&g' | sed -e 's&../smallbank/smallbank&farbank&g'`
echo $i echo $i
echo $dest echo $dest
# Make the dependencies # Make the dependencies
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
$exec_timeout $timeout $build_farbank $i $dest $exec_timeout $timeout $build_farbank $i $dest
if ( test -e $dest ) if ( test -e $dest )
then then
echo OK $dest >> log.log echo OK $dest >> log.log
else else
echo ERROR building $dest >> log.log echo ERROR building $dest >> log.log
fi fi
else else
echo SKIPPED $dest >> log.log echo SKIPPED $dest >> log.log
fi fi
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the farbank in the client data # Install the farbank in the client data
# Get the bank install directory # Get the bank install directory
bank_install_directory=`cat ../../cfg/directories.cfg | grep "bank_install_directory" | sed -e 's/bank_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` bank_install_directory=`cat ../../cfg/directories.cfg | grep "bank_install_directory" | sed -e 's/bank_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install farbank >> log.log echo --- Install farbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install farbank echo --- Install farbank
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R farbank/. $client_directory/$bank_install_directory 2>> log.log cp -u -p -R farbank/. $client_directory/$bank_install_directory 2>> log.log

@ -1,32 +1,32 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export fonts # *** Export fonts
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the ps directories # Get the ps directories
font_source_directories=`cat ../../cfg/directories.cfg | grep "font_source_directories" | sed -e 's/font_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` font_source_directories=`cat ../../cfg/directories.cfg | grep "font_source_directories" | sed -e 's/font_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export fonts >> log.log echo --- Export fonts >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export fonts echo --- Export fonts
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each font directory # For each font directory
for i in $font_source_directories ; do for i in $font_source_directories ; do
# Copy # Copy
cp -u -p $database_directory/$i/*.[tT][tT][fF] fonts 2>> log.log cp -u -p $database_directory/$i/*.[tT][tT][fF] fonts 2>> log.log
cp -u -p $database_directory/$i/*.[aA][fF][mM] fonts 2>> log.log cp -u -p $database_directory/$i/*.[aA][fF][mM] fonts 2>> log.log
cp -u -p $database_directory/$i/*.[pP][fF][bB] fonts 2>> log.log cp -u -p $database_directory/$i/*.[pP][fF][bB] fonts 2>> log.log
cp -u -p $database_directory/$i/*.[pP][fF][mM] fonts 2>> log.log cp -u -p $database_directory/$i/*.[pP][fF][mM] fonts 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the fonts in the client data # Install the fonts in the client data
# Get the fonts install directory # Get the fonts install directory
fonts_install_directory=`cat ../../cfg/directories.cfg | grep "fonts_install_directory" | sed -e 's/fonts_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` fonts_install_directory=`cat ../../cfg/directories.cfg | grep "fonts_install_directory" | sed -e 's/fonts_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install fonts >> log.log echo --- Install fonts >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install fonts echo --- Install fonts
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R fonts/. $client_directory/$fonts_install_directory 2>> log.log cp -u -p -R fonts/. $client_directory/$fonts_install_directory 2>> log.log

@ -1,304 +1,304 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# ig_land_max: landscape IG eported from 3dsmax not elevated by the heightmap # ig_land_max: landscape IG eported from 3dsmax not elevated by the heightmap
# ig_land_max_elev: landscape IG eported from 3dsmax elevated by the heightmap # ig_land_max_elev: landscape IG eported from 3dsmax elevated by the heightmap
# ig_land_ligo: landscape IG found in ligo bricks not elevated by the heightmap # ig_land_ligo: landscape IG found in ligo bricks not elevated by the heightmap
# ig_land_ligo_elev: landscape IG found in ligo bricks from 3dsmax elevated by the heightmap # ig_land_ligo_elev: landscape IG found in ligo bricks from 3dsmax elevated by the heightmap
# ig_land_ld: landscape IG generated by the land exporter (already elevated by the land exporter) # ig_land_ld: landscape IG generated by the land exporter (already elevated by the land exporter)
# ig_land: final IG directory for landscape IGs # ig_land: final IG directory for landscape IGs
# ig_land_compare: Tmp final IG directory for landscape IGs before comparison # ig_land_compare: Tmp final IG directory for landscape IGs before comparison
# ig_other: final IG directory for village or construction IGs # ig_other: final IG directory for village or construction IGs
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build ig >> log.log echo --- Build ig >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build ig echo --- Build ig
echo ------- echo -------
date >> log.log date >> log.log
date date
# ************************************************ # ************************************************
# Build the IG_LAND made with the LevelDesign Tool # Build the IG_LAND made with the LevelDesign Tool
# ************************************************ # ************************************************
# Get the primitive directory # Get the primitive directory
continentdir=`cat ../../cfg/config.cfg | grep "leveldesign_igexport_continent_dir" | sed -e 's/leveldesign_igexport_continent_dir//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/;//g'` continentdir=`cat ../../cfg/config.cfg | grep "leveldesign_igexport_continent_dir" | sed -e 's/leveldesign_igexport_continent_dir//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/;//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the primitive directories # Get the primitive directories
ligo_ig_primitive_directory=`cat ../../cfg/directories.cfg | grep "ligo_ig_primitive_directory" | sed -e 's/ligo_ig_primitive_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ligo_ig_primitive_directory=`cat ../../cfg/directories.cfg | grep "ligo_ig_primitive_directory" | sed -e 's/ligo_ig_primitive_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the form directory # Get the form directory
form_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` form_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
if ( test "$continentdir" || test "$ligo_ig_primitive_directory" ) if ( test "$continentdir" || test "$ligo_ig_primitive_directory" )
then then
land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'` land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'`
if ( test "$land_name" ) if ( test "$land_name" )
then then
echo [Prim IG] ON echo [Prim IG] ON
echo [Prim IG] ON >> log.log echo [Prim IG] ON >> log.log
# create cfg file # create cfg file
# +++++++++++++++ # +++++++++++++++
rm prim_export.cfg rm prim_export.cfg
echo "// prim_export.cfg" > prim_export.cfg echo "// prim_export.cfg" > prim_export.cfg
echo "OutIGDir = \"ig_land_ld\";" >> prim_export.cfg echo "OutIGDir = \"ig_land_ld\";" >> prim_export.cfg
echo "ZoneWDir = \"..\\zone\\zone_welded\";" >> prim_export.cfg echo "ZoneWDir = \"..\\zone\\zone_welded\";" >> prim_export.cfg
name_bank=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g'` name_bank=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "SmallBank = $name_bank" >> prim_export.cfg echo "SmallBank = $name_bank" >> prim_export.cfg
name_farbank=`cat ../../cfg/properties.cfg | grep "bankfar_name" | sed -e 's/bankfar_name//' | sed -e 's/ //g' | sed -e 's/=//g'` name_farbank=`cat ../../cfg/properties.cfg | grep "bankfar_name" | sed -e 's/bankfar_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "FarBank = $name_farbank" >> prim_export.cfg echo "FarBank = $name_farbank" >> prim_export.cfg
displacedir=`cat ../../cfg/directories.cfg | grep "displace_source_directory" | sed -e 's/displace_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` displacedir=`cat ../../cfg/directories.cfg | grep "displace_source_directory" | sed -e 's/displace_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "DisplaceDir = \"$dir_database/$displacedir\";" >> prim_export.cfg echo "DisplaceDir = \"$dir_database/$displacedir\";" >> prim_export.cfg
echo "CellSize = 160.0;" >> prim_export.cfg echo "CellSize = 160.0;" >> prim_export.cfg
# Set the continent directory to export # Set the continent directory to export
echo "PrimDirs = {" >> prim_export.cfg echo "PrimDirs = {" >> prim_export.cfg
echo " $continentdir," >> prim_export.cfg echo " $continentdir," >> prim_export.cfg
for dir in $ligo_ig_primitive_directory ; do for dir in $ligo_ig_primitive_directory ; do
echo " \"$database_directory/$dir\"," >> prim_export.cfg echo " \"$database_directory/$dir\"," >> prim_export.cfg
done done
echo "};" >> prim_export.cfg echo "};" >> prim_export.cfg
# Set the dfn directory to export # Set the dfn directory to export
echo "FormDir = \"$form_dir\";" >> prim_export.cfg echo "FormDir = \"$form_dir\";" >> prim_export.cfg
# ******************* # *******************
# Launch the exporter # Launch the exporter
# ******************* # *******************
prim_export.exe prim_export.cfg prim_export.exe prim_export.cfg
# ******************* # *******************
# Merge it with the IG_LAND exported from Max + elvated with heightmap # Merge it with the IG_LAND exported from Max + elvated with heightmap
# ******************* # *******************
# elevation of the heightmap for land_max # elevation of the heightmap for land_max
# ++++++++++++++++++++++++++++++++++++++++++++ # ++++++++++++++++++++++++++++++++++++++++++++
rm ig_elevation.cfg rm ig_elevation.cfg
echo "// ig_elevation.cfg" > ig_elevation.cfg echo "// ig_elevation.cfg" > ig_elevation.cfg
echo "OutputIGDir = \"ig_land_max_elev\";" >> ig_elevation.cfg echo "OutputIGDir = \"ig_land_max_elev\";" >> ig_elevation.cfg
echo "InputIGDir = \"ig_land_max\";" >> ig_elevation.cfg echo "InputIGDir = \"ig_land_max\";" >> ig_elevation.cfg
echo "CellSize = 160.0;" >> ig_elevation.cfg echo "CellSize = 160.0;" >> ig_elevation.cfg
# HeightMapFile1 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor) # HeightMapFile1 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor)
dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
hmf1=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap1" | sed -e 's/ligo_export_heightmap1//' | sed -e 's/ //g' | sed -e 's/=//g'` hmf1=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap1" | sed -e 's/ligo_export_heightmap1//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "HeightMapFile1 = \"$dir_database/$dir_ligosrc/$hmf1\";" >> ig_elevation.cfg echo "HeightMapFile1 = \"$dir_database/$dir_ligosrc/$hmf1\";" >> ig_elevation.cfg
# ZFactor1 is the heightmap factor # ZFactor1 is the heightmap factor
zf1=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor1" | sed -e 's/ligo_export_zfactor1//' | sed -e 's/ //g' | sed -e 's/=//g'` zf1=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor1" | sed -e 's/ligo_export_zfactor1//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ZFactor1 = $zf1;" >> ig_elevation.cfg echo "ZFactor1 = $zf1;" >> ig_elevation.cfg
# HeightMapFile2 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor) # HeightMapFile2 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor)
hmf2=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap2" | sed -e 's/ligo_export_heightmap2//' | sed -e 's/ //g' | sed -e 's/=//g'` hmf2=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap2" | sed -e 's/ligo_export_heightmap2//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "HeightMapFile2 = \"$dir_database/$dir_ligosrc/$hmf2\";" >> ig_elevation.cfg echo "HeightMapFile2 = \"$dir_database/$dir_ligosrc/$hmf2\";" >> ig_elevation.cfg
# ZFactor2 is the heightmap factor # ZFactor2 is the heightmap factor
zf2=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor2" | sed -e 's/ligo_export_zfactor2//' | sed -e 's/ //g' | sed -e 's/=//g'` zf2=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor2" | sed -e 's/ligo_export_zfactor2//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ZFactor2 = $zf2;" >> ig_elevation.cfg echo "ZFactor2 = $zf2;" >> ig_elevation.cfg
echo "LandFile = \"$dir_database/$dir_ligosrc/$land_name\";" >> ig_elevation.cfg echo "LandFile = \"$dir_database/$dir_ligosrc/$land_name\";" >> ig_elevation.cfg
ig_elevation ig_elevation.cfg ig_elevation ig_elevation.cfg
# elevation of the heightmap for land_ligo # elevation of the heightmap for land_ligo
# ++++++++++++++++++++++++++++++++++++++++++++ # ++++++++++++++++++++++++++++++++++++++++++++
rm ig_elevation.cfg rm ig_elevation.cfg
echo "// ig_elevation.cfg" > ig_elevation.cfg echo "// ig_elevation.cfg" > ig_elevation.cfg
echo "OutputIGDir = \"ig_land_ligo_elev\";" >> ig_elevation.cfg echo "OutputIGDir = \"ig_land_ligo_elev\";" >> ig_elevation.cfg
echo "InputIGDir = \"ig_land_ligo\";" >> ig_elevation.cfg echo "InputIGDir = \"ig_land_ligo\";" >> ig_elevation.cfg
echo "CellSize = 160.0;" >> ig_elevation.cfg echo "CellSize = 160.0;" >> ig_elevation.cfg
# HeightMapFile1 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor) # HeightMapFile1 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor)
dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
hmf1=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap1" | sed -e 's/ligo_export_heightmap1//' | sed -e 's/ //g' | sed -e 's/=//g'` hmf1=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap1" | sed -e 's/ligo_export_heightmap1//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "HeightMapFile1 = \"$dir_database/$dir_ligosrc/$hmf1\";" >> ig_elevation.cfg echo "HeightMapFile1 = \"$dir_database/$dir_ligosrc/$hmf1\";" >> ig_elevation.cfg
# ZFactor1 is the heightmap factor # ZFactor1 is the heightmap factor
zf1=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor1" | sed -e 's/ligo_export_zfactor1//' | sed -e 's/ //g' | sed -e 's/=//g'` zf1=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor1" | sed -e 's/ligo_export_zfactor1//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ZFactor1 = $zf1;" >> ig_elevation.cfg echo "ZFactor1 = $zf1;" >> ig_elevation.cfg
# HeightMapFile2 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor) # HeightMapFile2 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor)
hmf2=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap2" | sed -e 's/ligo_export_heightmap2//' | sed -e 's/ //g' | sed -e 's/=//g'` hmf2=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap2" | sed -e 's/ligo_export_heightmap2//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "HeightMapFile2 = \"$dir_database/$dir_ligosrc/$hmf2\";" >> ig_elevation.cfg echo "HeightMapFile2 = \"$dir_database/$dir_ligosrc/$hmf2\";" >> ig_elevation.cfg
# ZFactor2 is the heightmap factor # ZFactor2 is the heightmap factor
zf2=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor2" | sed -e 's/ligo_export_zfactor2//' | sed -e 's/ //g' | sed -e 's/=//g'` zf2=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor2" | sed -e 's/ligo_export_zfactor2//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ZFactor2 = $zf2;" >> ig_elevation.cfg echo "ZFactor2 = $zf2;" >> ig_elevation.cfg
land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'` land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "LandFile = \"$dir_database/$dir_ligosrc/$land_name\";" >> ig_elevation.cfg echo "LandFile = \"$dir_database/$dir_ligosrc/$land_name\";" >> ig_elevation.cfg
ig_elevation ig_elevation.cfg ig_elevation ig_elevation.cfg
else else
echo [Prim IG] OFF echo [Prim IG] OFF
echo [Prim IG] OFF >> log.log echo [Prim IG] OFF >> log.log
fi fi
else else
echo [Prim IG] OFF echo [Prim IG] OFF
echo [Prim IG] OFF >> log.log echo [Prim IG] OFF >> log.log
fi fi
# Erase ig in ig_merge_tmp and ig_land_compare # Erase ig in ig_merge_tmp and ig_land_compare
rm ig_merge_tmp/* rm ig_merge_tmp/*
rm ig_land_compare/* rm ig_land_compare/*
# Merge ig in ig_land_ld with ig_land_max_elev in ig_merge_tmp # Merge ig in ig_land_ld with ig_land_max_elev in ig_merge_tmp
dir_current=`pwd` dir_current=`pwd`
cd ig_land_ld cd ig_land_ld
list_ig=`ls -1 *.[iI][gG] 2> /dev/null` list_ig=`ls -1 *.[iI][gG] 2> /dev/null`
cd $dir_current cd $dir_current
for filename in $list_ig ; do for filename in $list_ig ; do
# Does this file exist in ig_land_max_elev ? # Does this file exist in ig_land_max_elev ?
if test -e ig_land_max_elev/$filename ; then if test -e ig_land_max_elev/$filename ; then
# Yes, lets merge it # Yes, lets merge it
ig_add ig_merge_tmp/$filename ig_land_max_elev/$filename ig_land_ld/$filename ; ig_add ig_merge_tmp/$filename ig_land_max_elev/$filename ig_land_ld/$filename ;
else else
# No, only copy it # No, only copy it
cp ig_land_ld/$filename ig_merge_tmp/$filename ; cp ig_land_ld/$filename ig_merge_tmp/$filename ;
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Merge ig in ig_land_max_elev with ig_land_ld in ig_merge_tmp # Merge ig in ig_land_max_elev with ig_land_ld in ig_merge_tmp
cd ig_land_max_elev cd ig_land_max_elev
list_ig=`ls -1 *.[iI][gG] 2> /dev/null` list_ig=`ls -1 *.[iI][gG] 2> /dev/null`
cd $dir_current cd $dir_current
for filename in $list_ig ; do for filename in $list_ig ; do
# Does this file exist in ig_land_ld ? # Does this file exist in ig_land_ld ?
if !(test -e ig_land_ld/$filename) then if !(test -e ig_land_ld/$filename) then
# No, only copy it # No, only copy it
cp ig_land_max_elev/$filename ig_merge_tmp/$filename ; cp ig_land_max_elev/$filename ig_merge_tmp/$filename ;
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Merge ig in ig_merge_tmp with ig_land_ligo_elev in ig_land_compare # Merge ig in ig_merge_tmp with ig_land_ligo_elev in ig_land_compare
cd ig_merge_tmp cd ig_merge_tmp
list_ig=`ls -1 *.[iI][gG] 2> /dev/null` list_ig=`ls -1 *.[iI][gG] 2> /dev/null`
cd $dir_current cd $dir_current
for filename in $list_ig ; do for filename in $list_ig ; do
# Does this file exist in ig_land_ligo_elev ? # Does this file exist in ig_land_ligo_elev ?
if (test -e ig_land_ligo_elev/$filename) then if (test -e ig_land_ligo_elev/$filename) then
# Yes, lets merge it # Yes, lets merge it
ig_add ig_land_compare/$filename ig_merge_tmp/$filename ig_land_ligo_elev/$filename ; ig_add ig_land_compare/$filename ig_merge_tmp/$filename ig_land_ligo_elev/$filename ;
else else
# No, only copy it # No, only copy it
cp ig_merge_tmp/$filename ig_land_compare/$filename ; cp ig_merge_tmp/$filename ig_land_compare/$filename ;
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Merge ig in ig_land_ligo_elev with ig_merge_tmp in ig_land_compare # Merge ig in ig_land_ligo_elev with ig_merge_tmp in ig_land_compare
cd ig_land_ligo_elev cd ig_land_ligo_elev
list_ig=`ls -1 *.[iI][gG] 2> /dev/null` list_ig=`ls -1 *.[iI][gG] 2> /dev/null`
cd $dir_current cd $dir_current
for filename in $list_ig ; do for filename in $list_ig ; do
# Does this file exist in ig_merge_tmp ? # Does this file exist in ig_merge_tmp ?
if !(test -e ig_merge_tmp/$filename) then if !(test -e ig_merge_tmp/$filename) then
# No, only copy it # No, only copy it
cp ig_land_ligo_elev/$filename ig_land_compare/$filename ; cp ig_land_ligo_elev/$filename ig_land_compare/$filename ;
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Compare and update # Compare and update
cd ig_land_compare cd ig_land_compare
list_ig=`ls -1 *.[iI][gG]` list_ig=`ls -1 *.[iI][gG]`
for filename in $list_ig ; do for filename in $list_ig ; do
echo "Checking $filename for update" echo "Checking $filename for update"
if test -e ../ig_land/$filename ; then if test -e ../ig_land/$filename ; then
must_update=`diff --binary -q $filename ../ig_land/$filename` ; must_update=`diff --binary -q $filename ../ig_land/$filename` ;
else else
must_update=YES ; must_update=YES ;
fi fi
if test -n "$must_update" ; then if test -n "$must_update" ; then
echo " Updating" echo " Updating"
cp -u -p $filename ../ig_land/$filename ; cp -u -p $filename ../ig_land/$filename ;
fi fi
# Idle # Idle
../../../idle.bat ../../../idle.bat
done done
cd ../ig_land cd ../ig_land
list_ig=`ls -1 *.[iI][gG]` list_ig=`ls -1 *.[iI][gG]`
for filename in $list_ig ; do for filename in $list_ig ; do
if !(test -e ../ig_land_compare/$filename) then if !(test -e ../ig_land_compare/$filename) then
echo "Remove $filename" echo "Remove $filename"
rm $filename ; rm $filename ;
fi fi
# Idle # Idle
../../../idle.bat ../../../idle.bat
done done
cd $dir_current cd $dir_current
# ****************** # ******************
# List all the zones # List all the zones
# ****************** # ******************
# Get the landscape name # Get the landscape name
landscape_name=`cat ../../cfg/config.cfg | grep "landscape_name" | sed -e 's/landscape_name//' | sed -e 's/ //g' | sed -e 's/=//g'` landscape_name=`cat ../../cfg/config.cfg | grep "landscape_name" | sed -e 's/landscape_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Landscape name exist ? # Landscape name exist ?
if ( test "$landscape_name" ) if ( test "$landscape_name" )
then then
# If the list file exists, erase it # If the list file exists, erase it
if ( test -f "$landscape_name"_ig.txt ) if ( test -f "$landscape_name"_ig.txt )
then then
rm "$landscape_name"_ig.txt rm "$landscape_name"_ig.txt
fi fi
cd ig_land cd ig_land
for i in *.[iI][gG] ; do for i in *.[iI][gG] ; do
# Build an ig list # Build an ig list
if ( test -f $i ) if ( test -f $i )
then then
echo $i >> ../"$landscape_name"_ig.txt echo $i >> ../"$landscape_name"_ig.txt
else else
echo >> ../"$landscape_name"_ig.txt echo >> ../"$landscape_name"_ig.txt
fi fi
done done
cd .. cd ..
# Idle # Idle
../../idle.bat ../../idle.bat
fi fi

@ -1,90 +1,90 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export ig files (.ig) from Max # *** Export ig files (.ig) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "ig_export_timeout" | sed -e 's/ig_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "ig_export_timeout" | sed -e 's/ig_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the ig directories # Get the ig directories
ig_land_source_directories=`cat ../../cfg/directories.cfg | grep "ig_land_source_directory" | sed -e 's/ig_land_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ig_land_source_directories=`cat ../../cfg/directories.cfg | grep "ig_land_source_directory" | sed -e 's/ig_land_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the ig directories # Get the ig directories
ig_other_source_directories=`cat ../../cfg/directories.cfg | grep "ig_other_source_directory" | sed -e 's/ig_other_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ig_other_source_directories=`cat ../../cfg/directories.cfg | grep "ig_other_source_directory" | sed -e 's/ig_other_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export ig >> log.log echo --- Export ig >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export ig echo --- Export ig
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
# List landscape ig # List landscape ig
for i in $ig_land_source_directories ; do for i in $ig_land_source_directories ; do
# Copy the script # Copy the script
cat maxscript/ig_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/ig/log.log&g" | sed -e "s&ig_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/ig/tag&g" | sed -e "s&output_directory_ig&$build_gamedata_directory/processes/ig/ig_land_max&g" > $max_directory/scripts/ig_export.ms cat maxscript/ig_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/ig/log.log&g" | sed -e "s&ig_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/ig/tag&g" | sed -e "s&output_directory_ig&$build_gamedata_directory/processes/ig/ig_land_max&g" > $max_directory/scripts/ig_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done
for i in $ig_other_source_directories ; do for i in $ig_other_source_directories ; do
# Copy the script # Copy the script
cat maxscript/ig_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/ig/log.log&g" | sed -e "s&ig_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/ig/tag&g" | sed -e "s&output_directory_ig&$build_gamedata_directory/processes/ig/ig_other&g" > $max_directory/scripts/ig_export.ms cat maxscript/ig_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/ig/log.log&g" | sed -e "s&ig_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/ig/tag&g" | sed -e "s&output_directory_ig&$build_gamedata_directory/processes/ig/ig_other&g" > $max_directory/scripts/ig_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript ig_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,30 +1,30 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install ig in the client data # Install ig in the client data
# Get the ig install directory # Get the ig install directory
ig_install_directory=`cat ../../cfg/directories.cfg | grep "ig_install_directory" | sed -e 's/ig_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ig_install_directory=`cat ../../cfg/directories.cfg | grep "ig_install_directory" | sed -e 's/ig_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the landscape name # Get the landscape name
landscape_name=`cat ../../cfg/config.cfg | grep "landscape_name" | sed -e 's/landscape_name//' | sed -e 's/ //g' | sed -e 's/=//g'` landscape_name=`cat ../../cfg/config.cfg | grep "landscape_name" | sed -e 's/landscape_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install Ig >> log.log echo --- Install Ig >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install Ig echo --- Install Ig
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p "$landscape_name"_ig.txt $client_directory/$ig_install_directory 2>> log.log cp -u -p "$landscape_name"_ig.txt $client_directory/$ig_install_directory 2>> log.log
# Do not copy ig_land, because zone process will copy zone ig lighted versions into client directory. # Do not copy ig_land, because zone process will copy zone ig lighted versions into client directory.
#cp -u -p ig_land/*.[iI][gG] $client_directory/$ig_install_directory 2>> log.log #cp -u -p ig_land/*.[iI][gG] $client_directory/$ig_install_directory 2>> log.log
# Do not copy ig_other, because ig_light process will copy ig lighted versions into client directory. # Do not copy ig_other, because ig_light process will copy ig lighted versions into client directory.
#cp -u -p ig_other/*.[iI][gG] $client_directory/$ig_install_directory 2>> log.log #cp -u -p ig_other/*.[iI][gG] $client_directory/$ig_install_directory 2>> log.log

@ -1,23 +1,23 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install ig in the client data # Install ig in the client data
# Get the ig install directory # Get the ig install directory
ig_install_directory=`cat ../../cfg/directories.cfg | grep "ig_install_directory" | sed -e 's/ig_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ig_install_directory=`cat ../../cfg/directories.cfg | grep "ig_install_directory" | sed -e 's/ig_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install Lighted Ig >> log.log echo --- Install Lighted Ig >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install Lighted Ig echo --- Install Lighted Ig
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R ig_other_lighted/. $client_directory/$ig_install_directory 2>> log.log cp -u -p -R ig_other_lighted/. $client_directory/$ig_install_directory 2>> log.log

@ -1,60 +1,60 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Build interface # *** Build interface
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the interface directories # Get the interface directories
interface_source_directories=`cat ../../cfg/directories.cfg | grep "interface_source_directories" | sed -e 's/interface_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` interface_source_directories=`cat ../../cfg/directories.cfg | grep "interface_source_directories" | sed -e 's/interface_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the interface directories to compress in one DXTC only # Get the interface directories to compress in one DXTC only
interface_source_dxtc_directories=`cat ../../cfg/directories.cfg | grep "interface_source_dxtc_directories" | sed -e 's/interface_source_dxtc_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` interface_source_dxtc_directories=`cat ../../cfg/directories.cfg | grep "interface_source_dxtc_directories" | sed -e 's/interface_source_dxtc_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build interface >> log.log echo --- Build interface >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build interface echo --- Build interface
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each interface directory # For each interface directory
for i in $interface_source_directories ; do for i in $interface_source_directories ; do
# Copy # Copy
niouname=`echo $i | sed -e 's&/&_&g'` niouname=`echo $i | sed -e 's&/&_&g'`
rm tga_tmp/*.[tT][gG][aA] rm tga_tmp/*.[tT][gG][aA]
cp -u -p $database_directory/$i/*.[tT][gG][aA] tga_tmp 2>> log.log cp -u -p $database_directory/$i/*.[tT][gG][aA] tga_tmp 2>> log.log
build_interface.exe tga/texture_$niouname.tga tga_tmp build_interface.exe tga/texture_$niouname.tga tga_tmp
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# For each interface directory to compress in one DXTC # For each interface directory to compress in one DXTC
rm tga_tmp/*.[tT][gG][aA] rm tga_tmp/*.[tT][gG][aA]
for i in $interface_source_dxtc_directories ; do for i in $interface_source_dxtc_directories ; do
# Copy # Copy
cp -u -p $database_directory/$i/*.[tT][gG][aA] tga_tmp 2>> log.log cp -u -p $database_directory/$i/*.[tT][gG][aA] tga_tmp 2>> log.log
done done
# build all files in tga_tmp into one tga. Let the OpenGL compress it at runTime (better result for some important cases) # build all files in tga_tmp into one tga. Let the OpenGL compress it at runTime (better result for some important cases)
build_interface.exe tga/texture_interfaces_dxtc.tga tga_tmp build_interface.exe tga/texture_interfaces_dxtc.tga tga_tmp
# DO NOT COMPRESS ../../bin/tga2dds tga_tmp/texture_interfaces_dxtc.tga -o tga/texture_interfaces_dxtc.dds -a 5 # DO NOT COMPRESS ../../bin/tga2dds tga_tmp/texture_interfaces_dxtc.tga -o tga/texture_interfaces_dxtc.dds -a 5
# Compress animation. Important to avoid 'memory fragmentation' # Compress animation. Important to avoid 'memory fragmentation'
mv -u 3d/*.[aA][nN][iI][mM] anim_tmp 2>> log.log mv -u 3d/*.[aA][nN][iI][mM] anim_tmp 2>> log.log
anim_builder.exe anim_tmp 3d ../../cfg/properties.cfg anim_builder.exe anim_tmp 3d ../../cfg/properties.cfg
# Idle # Idle
../../idle.bat ../../idle.bat

@ -1,62 +1,62 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Bin # Bin
tga_2_dds='tga2dds.exe' tga_2_dds='tga2dds.exe'
# *** Export interface tile (.tga) # *** Export interface tile (.tga)
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the interface fullscreen directories # Get the interface fullscreen directories
interface_fullscreen_directories=`cat ../../cfg/directories.cfg | grep "interface_fullscreen_directories" | sed -e 's/interface_fullscreen_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` interface_fullscreen_directories=`cat ../../cfg/directories.cfg | grep "interface_fullscreen_directories" | sed -e 's/interface_fullscreen_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the interface 3d directories # Get the interface 3d directories
interface_3d_directories=`cat ../../cfg/directories.cfg | grep "interface_3d_directories" | sed -e 's/interface_3d_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` interface_3d_directories=`cat ../../cfg/directories.cfg | grep "interface_3d_directories" | sed -e 's/interface_3d_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export interface >> log.log echo --- Export interface >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export interface echo --- Export interface
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each interface fullscreen directory compress independently all in dds # For each interface fullscreen directory compress independently all in dds
rm tga_tmp/*.[tT][gG][aA] rm tga_tmp/*.[tT][gG][aA]
for i in $interface_fullscreen_directories; do for i in $interface_fullscreen_directories; do
# Copy # Copy
cp -u -p $database_directory/$i/*.[tT][gG][aA] tga_tmp 2>> log.log cp -u -p $database_directory/$i/*.[tT][gG][aA] tga_tmp 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done
for i in tga_tmp/*.[tT][gG][aA] ; do for i in tga_tmp/*.[tT][gG][aA] ; do
# Destination file # Destination file
dest=`echo $i | sed -e 's/tga_tmp/tga/g'` dest=`echo $i | sed -e 's/tga_tmp/tga/g'`
dest=`echo $dest | sed -e 's/\.[tT][gG][aA]/.dds/g'` dest=`echo $dest | sed -e 's/\.[tT][gG][aA]/.dds/g'`
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
# Convert # Convert
$tga_2_dds $i -o $dest -a 5 2>> log.log $tga_2_dds $i -o $dest -a 5 2>> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# For each interface 3d directory # For each interface 3d directory
for i in $interface_3d_directories; do for i in $interface_3d_directories; do
# Copy # Copy
cp -u -p $database_directory/$i/* 3d 2>> log.log cp -u -p $database_directory/$i/* 3d 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,24 +1,24 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the interface in the client data # Install the interface in the client data
# Get the interface install directory # Get the interface install directory
interface_install_directory=`cat ../../cfg/directories.cfg | grep "interface_install_directory" | sed -e 's/interface_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` interface_install_directory=`cat ../../cfg/directories.cfg | grep "interface_install_directory" | sed -e 's/interface_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install interface >> log.log echo --- Install interface >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install interface echo --- Install interface
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R tga/. $client_directory/$interface_install_directory 2>> log.log cp -u -p -R tga/. $client_directory/$interface_install_directory 2>> log.log
cp -u -p -R 3d/. $client_directory/$interface_install_directory 2>> log.log cp -u -p -R 3d/. $client_directory/$interface_install_directory 2>> log.log

@ -1,202 +1,202 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
echo > log.log echo > log.log
# ******************** # ********************
# Make the config file # Make the config file
# ******************** # ********************
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
land_exporter_timeout=`cat ../../cfg/config.cfg | grep "ligo_build_timeout" | sed -e 's/ligo_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` land_exporter_timeout=`cat ../../cfg/config.cfg | grep "ligo_build_timeout" | sed -e 's/ligo_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
rm land_exporter.cfg rm land_exporter.cfg
echo "// land_exporter.cfg" > land_exporter.cfg echo "// land_exporter.cfg" > land_exporter.cfg
# OutZoneDir is Where to put all .zone generated # OutZoneDir is Where to put all .zone generated
#dir_gamedata=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` #dir_gamedata=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
#echo "OutZoneDir = \"$dir_gamedata/processes/ligo/output\";" >> land_exporter.cfg #echo "OutZoneDir = \"$dir_gamedata/processes/ligo/output\";" >> land_exporter.cfg
echo "OutZoneDir = \"output\";" >> land_exporter.cfg echo "OutZoneDir = \"output\";" >> land_exporter.cfg
echo "OutIGDir = \"../ig/ig_land_ligo\";" >> land_exporter.cfg echo "OutIGDir = \"../ig/ig_land_ligo\";" >> land_exporter.cfg
echo "AdditionnalIGOutDir = \"../ig/ig_other\";" >> land_exporter.cfg echo "AdditionnalIGOutDir = \"../ig/ig_other\";" >> land_exporter.cfg
# RefZoneDir is Where the reference zones are # RefZoneDir is Where the reference zones are
dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
dir_ligobricks=`cat ../../cfg/directories.cfg | grep "ligo_bricks_directory" | sed -e 's/ligo_bricks_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_ligobricks=`cat ../../cfg/directories.cfg | grep "ligo_bricks_directory" | sed -e 's/ligo_bricks_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
dir_dfn=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_dfn=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
continent_file=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//' | sed -e 's/ //g' | sed -e 's/=//g'` continent_file=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//' | sed -e 's/ //g' | sed -e 's/=//g'`
dir_world=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_world=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# dir_continents=`cat ../../cfg/site.cfg | grep "continents_directory" | sed -e 's/continents_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` # dir_continents=`cat ../../cfg/site.cfg | grep "continents_directory" | sed -e 's/continents_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "RefZoneDir = \"$dir_ligobricks/zones\";" >> land_exporter.cfg echo "RefZoneDir = \"$dir_ligobricks/zones\";" >> land_exporter.cfg
echo "RefIGDir = \"$dir_ligobricks/igs\";" >> land_exporter.cfg echo "RefIGDir = \"$dir_ligobricks/igs\";" >> land_exporter.cfg
echo "AdditionnalIGInDir = \"$dir_ligobricks/igs\";" >> land_exporter.cfg echo "AdditionnalIGInDir = \"$dir_ligobricks/igs\";" >> land_exporter.cfg
# echo "ContinentsDir = \"$dir_continents\";" >> land_exporter.cfg # echo "ContinentsDir = \"$dir_continents\";" >> land_exporter.cfg
echo "ContinentsDir = \"$dir_world\";" >> land_exporter.cfg echo "ContinentsDir = \"$dir_world\";" >> land_exporter.cfg
# LigoBankDir is Where all .ligozone are (those used by the .land) # LigoBankDir is Where all .ligozone are (those used by the .land)
echo "LigoBankDir = \"$dir_ligobricks/zoneligos\";" >> land_exporter.cfg echo "LigoBankDir = \"$dir_ligobricks/zoneligos\";" >> land_exporter.cfg
# TileBankFile is the .bank file (used to know if a tile is oriented and the like) # TileBankFile is the .bank file (used to know if a tile is oriented and the like)
name_bank=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g'` name_bank=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "TileBankFile = $name_bank" >> land_exporter.cfg echo "TileBankFile = $name_bank" >> land_exporter.cfg
# ColorMapFile # ColorMapFile
cmf=`cat ../../cfg/config.cfg | grep "ligo_export_colormap" | sed -e 's/ligo_export_colormap//' | sed -e 's/ //g' | sed -e 's/=//g'` cmf=`cat ../../cfg/config.cfg | grep "ligo_export_colormap" | sed -e 's/ligo_export_colormap//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ColorMapFile = \"$dir_database/$dir_ligosrc/$cmf\";" >> land_exporter.cfg echo "ColorMapFile = \"$dir_database/$dir_ligosrc/$cmf\";" >> land_exporter.cfg
# HeightMapFile1 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor) # HeightMapFile1 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor)
hmf1=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap1" | sed -e 's/ligo_export_heightmap1//' | sed -e 's/ //g' | sed -e 's/=//g'` hmf1=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap1" | sed -e 's/ligo_export_heightmap1//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "HeightMapFile1 = \"$dir_database/$dir_ligosrc/$hmf1\";" >> land_exporter.cfg echo "HeightMapFile1 = \"$dir_database/$dir_ligosrc/$hmf1\";" >> land_exporter.cfg
# ZFactor1 is the heightmap factor # ZFactor1 is the heightmap factor
zf1=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor1" | sed -e 's/ligo_export_zfactor1//' | sed -e 's/ //g' | sed -e 's/=//g'` zf1=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor1" | sed -e 's/ligo_export_zfactor1//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ZFactor1 = $zf1;" >> land_exporter.cfg echo "ZFactor1 = $zf1;" >> land_exporter.cfg
# HeightMapFile2 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor) # HeightMapFile2 is the grayscale .tga file (127 is 0, 0 is -127*ZFactor and 255 is +128*ZFactor)
hmf2=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap2" | sed -e 's/ligo_export_heightmap2//' | sed -e 's/ //g' | sed -e 's/=//g'` hmf2=`cat ../../cfg/config.cfg | grep "ligo_export_heightmap2" | sed -e 's/ligo_export_heightmap2//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "HeightMapFile2 = \"$dir_database/$dir_ligosrc/$hmf2\";" >> land_exporter.cfg echo "HeightMapFile2 = \"$dir_database/$dir_ligosrc/$hmf2\";" >> land_exporter.cfg
# ZFactor2 is the heightmap factor # ZFactor2 is the heightmap factor
zf2=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor2" | sed -e 's/ligo_export_zfactor2//' | sed -e 's/ //g' | sed -e 's/=//g'` zf2=`cat ../../cfg/config.cfg | grep "ligo_export_zfactor2" | sed -e 's/ligo_export_zfactor2//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ZFactor2 = $zf2;" >> land_exporter.cfg echo "ZFactor2 = $zf2;" >> land_exporter.cfg
# ZoneLight is Roughly light the zone (0-none, 1-patch, 2-noise) # ZoneLight is Roughly light the zone (0-none, 1-patch, 2-noise)
echo "ZoneLight = 0;" >> land_exporter.cfg echo "ZoneLight = 0;" >> land_exporter.cfg
# CellSize is the size of the cell (zone size) in meter # CellSize is the size of the cell (zone size) in meter
echo "CellSize = 160;" >> land_exporter.cfg echo "CellSize = 160;" >> land_exporter.cfg
# Threshild is the weld threshold in meter # Threshild is the weld threshold in meter
echo "Threshold = 1;" >> land_exporter.cfg echo "Threshold = 1;" >> land_exporter.cfg
# Where to take dfn files # Where to take dfn files
echo "DFNDir = \"$dir_dfn\";" >> land_exporter.cfg echo "DFNDir = \"$dir_dfn\";" >> land_exporter.cfg
# CMB input directory # CMB input directory
echo "RefCMBDir = \"$dir_ligobricks/cmb\";" >> land_exporter.cfg echo "RefCMBDir = \"$dir_ligobricks/cmb\";" >> land_exporter.cfg
# CMB output directory # CMB output directory
echo "OutCMBDir = \"../rbank/cmb\";" >> land_exporter.cfg echo "OutCMBDir = \"../rbank/cmb\";" >> land_exporter.cfg
#input .continent file #input .continent file
echo "ContinentFile = \"$dir_world/$continent_file\";" >> land_exporter.cfg echo "ContinentFile = \"$dir_world/$continent_file\";" >> land_exporter.cfg
# Force export of collisions and additionnal igs # Force export of collisions and additionnal igs
echo "ExportCollisions = 1;" >> land_exporter.cfg echo "ExportCollisions = 1;" >> land_exporter.cfg
echo "ExportAdditionnalIGs = 1;" >> land_exporter.cfg echo "ExportAdditionnalIGs = 1;" >> land_exporter.cfg
# ZoneRegionFile is the .land to compute # ZoneRegionFile is the .land to compute
dir_current=`pwd` dir_current=`pwd`
land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'` land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "ZoneRegionFile = \"$dir_database/$dir_ligosrc/$land_name\";" >> land_exporter.cfg echo "ZoneRegionFile = \"$dir_database/$dir_ligosrc/$land_name\";" >> land_exporter.cfg
# if there is no .land then do not generate all zones and zone welded # if there is no .land then do not generate all zones and zone welded
if test -z "$land_name" ; then if test -z "$land_name" ; then
echo No .land set -- Exiting -- echo No .land set -- Exiting --
exit; exit;
fi fi
# ******************* # *******************
# launch the exporter # launch the exporter
# ******************* # *******************
echo ------- >> log.log echo ------- >> log.log
echo --- Generate ligo zone >> log.log echo --- Generate ligo zone >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Generate ligo zone echo --- Generate ligo zone
echo ------- echo -------
date >> log.log date >> log.log
date date
echo Exporting echo Exporting
$exec_timeout $land_exporter_timeout land_export.exe land_exporter.cfg $exec_timeout $land_exporter_timeout land_export.exe land_exporter.cfg
# rename *.[zZ][oO][nN][eE][lL] *.[zZ][oO][nN][eE] # rename *.[zZ][oO][nN][eE][lL] *.[zZ][oO][nN][eE]
# script is just too slow to do renaming... And we can't call directly dos command # script is just too slow to do renaming... And we can't call directly dos command
cd output cd output
../sh/renametozone.bat ../sh/renametozone.bat
cd .. cd ..
# ************** # **************
# Copy the zones # Copy the zones
# ************** # **************
cd ../zone cd ../zone
mkdir zone_exported 2> /dev/null mkdir zone_exported 2> /dev/null
# Try to copy ligo zone if any # Try to copy ligo zone if any
# **************************** # ****************************
ligo_flag=`cat ../../cfg/config.cfg | grep "process_to_complete" | grep "ligo"` ligo_flag=`cat ../../cfg/config.cfg | grep "process_to_complete" | grep "ligo"`
dir_current=`pwd` dir_current=`pwd`
cd ../ligo/output cd ../ligo/output
list_zone=`ls -1 *.[zZ][oO][nN][eE]*` list_zone=`ls -1 *.[zZ][oO][nN][eE]*`
for filename in $list_zone ; do for filename in $list_zone ; do
echo "Checking $filename for update" echo "Checking $filename for update"
if test -e ../../zone/zone_exported/$filename ; then if test -e ../../zone/zone_exported/$filename ; then
must_update=`diff --binary -q $filename ../../zone/zone_exported/$filename` ; must_update=`diff --binary -q $filename ../../zone/zone_exported/$filename` ;
else else
must_update=YES ; must_update=YES ;
fi fi
if test -n "$must_update" ; then if test -n "$must_update" ; then
echo " Updating" echo " Updating"
cp -u -p $filename ../../zone/zone_exported/$filename ; cp -u -p $filename ../../zone/zone_exported/$filename ;
fi fi
# Idle # Idle
../../../idle.bat ../../../idle.bat
done done
cd $dir_current cd $dir_current
# delete files only present in the zone_exported directory # delete files only present in the zone_exported directory
if ( test "$ligo_flag" ) if ( test "$ligo_flag" )
then then
cd ./zone_exported cd ./zone_exported
list_zone=`ls -1 *.[zZ][oO][nN][eE]*` list_zone=`ls -1 *.[zZ][oO][nN][eE]*`
for filename in $list_zone ; do for filename in $list_zone ; do
if test -e ../../ligo/output/$filename ; then if test -e ../../ligo/output/$filename ; then
must_update=NO ; must_update=NO ;
else else
echo "Removing $filename" echo "Removing $filename"
rm $filename ; rm $filename ;
fi fi
# Idle # Idle
../../../idle.bat ../../../idle.bat
done done
cd .. cd ..
fi fi

@ -1,72 +1,72 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
echo > log.log echo > log.log
# *** Export ligo zone files from Max *** # *** Export ligo zone files from Max ***
# *** ******************************* *** # *** ******************************* ***
echo ------- >> log.log echo ------- >> log.log
echo --- Export ligo zone >> log.log echo --- Export ligo zone >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export ligo zone echo --- Export ligo zone
echo ------- echo -------
date >> log.log date >> log.log
date date
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "ligo_export_timeout" | sed -e 's/ligo_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "ligo_export_timeout" | sed -e 's/ligo_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get current directory # Get current directory
dir_gamedata=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's&\/&\\\&g'` dir_gamedata=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's&\/&\\\&g'`
dir_gamedata_maxscript=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` dir_gamedata_maxscript=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the bank filename # Get the bank filename
bank_filename=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'` bank_filename=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'`
bankfar_filename=`cat ../../cfg/properties.cfg | grep "bankfar_name" | sed -e 's/bankfar_name//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'` bankfar_filename=`cat ../../cfg/properties.cfg | grep "bankfar_name" | sed -e 's/bankfar_name//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'`
# Copy the bank file # Copy the bank file
cp $bank_filename smallbank/ligo.smallbank 2>> log.log cp $bank_filename smallbank/ligo.smallbank 2>> log.log
cp $bankfar_filename smallbank/ligo.farbank 2>> log.log cp $bankfar_filename smallbank/ligo.farbank 2>> log.log
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# delete ini file # delete ini file
rm $max_directory/plugcfg/nelligo.ini rm $max_directory/plugcfg/nelligo.ini
# echo "$max_directory/plugcfg/nelligo.ini" >> log.log # echo "$max_directory/plugcfg/nelligo.ini" >> log.log
# create the ini file # create the ini file
echo "[LigoConfig]" > $max_directory/plugcfg/nelligo.ini echo "[LigoConfig]" > $max_directory/plugcfg/nelligo.ini
# copy the ligo export script # copy the ligo export script
cat maxscript/nel_ligo_export.ms | sed -e "s&output_directory_tag&$dir_gamedata_maxscript/processes/ligo/tag&g" | sed -e "s&output_logfile&$dir_gamedata_maxscript/processes/ligo/log.log&g" | sed -e "s&bankFilename&$dir_gamedata_maxscript/processes/ligo/smallbank/ligo.smallbank&g" > $max_directory/scripts/nel_ligo_export.ms cat maxscript/nel_ligo_export.ms | sed -e "s&output_directory_tag&$dir_gamedata_maxscript/processes/ligo/tag&g" | sed -e "s&output_logfile&$dir_gamedata_maxscript/processes/ligo/log.log&g" | sed -e "s&bankFilename&$dir_gamedata_maxscript/processes/ligo/smallbank/ligo.smallbank&g" > $max_directory/scripts/nel_ligo_export.ms
dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's&\/&\\\&g'` dir_database=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's&\/&\\\&g'`
dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's&\/&\\\&g'` dir_ligosrc=`cat ../../cfg/directories.cfg | grep "ligo_source_directory" | sed -e 's/ligo_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's&\/&\\\&g'`
echo "LigoPath=$dir_database\\$dir_ligosrc\\max\\" >> $max_directory/plugcfg/nelligo.ini echo "LigoPath=$dir_database\\$dir_ligosrc\\max\\" >> $max_directory/plugcfg/nelligo.ini
#echo "LigoExportPath=$dir_database\\$dir_ligosrc\\" >> $max_directory/plugcfg/nelligo.ini #echo "LigoExportPath=$dir_database\\$dir_ligosrc\\" >> $max_directory/plugcfg/nelligo.ini
echo "LigoExportPath=$dir_gamedata\\processes\\ligo\\" >> $max_directory/plugcfg/nelligo.ini echo "LigoExportPath=$dir_gamedata\\processes\\ligo\\" >> $max_directory/plugcfg/nelligo.ini
# export only if no .land set # export only if no .land set
land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'` land_name=`cat ../../cfg/config.cfg | grep "ligo_export_land" | sed -e 's/ligo_export_land//' | sed -e 's/ //g' | sed -e 's/=//g'`
ligo_export_one_pass=`cat ../../cfg/config.cfg | grep "ligo_export_one_pass" | sed -e 's/ligo_export_one_pass//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'` ligo_export_one_pass=`cat ../../cfg/config.cfg | grep "ligo_export_one_pass" | sed -e 's/ligo_export_one_pass//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'`
if [ -z "$land_name" -o "$ligo_export_one_pass" == "1" ] ; then if [ -z "$land_name" -o "$ligo_export_one_pass" == "1" ] ; then
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript nel_ligo_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript nel_ligo_export.ms -q -mi -vn
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript nel_ligo_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript nel_ligo_export.ms -q -mi -vn
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript nel_ligo_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript nel_ligo_export.ms -q -mi -vn
fi fi

@ -1,140 +1,140 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Build map files (.tga / .dds) # *** Build map files (.tga / .dds)
# Bin # Bin
tga_2_dds='tga2dds.exe' tga_2_dds='tga2dds.exe'
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build map >> log.log echo --- Build map >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build map echo --- Build map
echo ------- echo -------
date >> log.log date >> log.log
date date
#*** Build panoply files (.tga / .dds), and copy the result in the tga directory #*** Build panoply files (.tga / .dds), and copy the result in the tga directory
# Copy panoply containt into cache if the process as been stopped before the end of build. # Copy panoply containt into cache if the process as been stopped before the end of build.
echo Copy panoply into cache echo Copy panoply into cache
cp -u -p -R panoply/. cache 2>> log.log cp -u -p -R panoply/. cache 2>> log.log
echo Remove panoply directory echo Remove panoply directory
rm -r panoply 2>> log.log rm -r panoply 2>> log.log
echo Copy hlsinfo into cache echo Copy hlsinfo into cache
cp -u -p -R hlsinfo/. cache 2>> log.log cp -u -p -R hlsinfo/. cache 2>> log.log
echo Remove hlsinfo directory echo Remove hlsinfo directory
rm -r hlsinfo 2>> log.log rm -r hlsinfo 2>> log.log
mkdir panoply mkdir panoply
mkdir hlsinfo mkdir hlsinfo
# Bin # Bin
panoply_maker='panoply_maker.exe' panoply_maker='panoply_maker.exe'
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build panoply >> log.log echo --- Build panoply >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build panoply echo --- Build panoply
echo ------- echo -------
date >> log.log date >> log.log
date date
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Reduce bitmap size factor # Reduce bitmap size factor
reduce_bitmap_factor=`cat ../../cfg/config.cfg | grep "reduce_bitmap_factor" | sed -e 's/reduce_bitmap_factor//' | sed -e 's/ //g' | sed -e 's/=//g'` reduce_bitmap_factor=`cat ../../cfg/config.cfg | grep "reduce_bitmap_factor" | sed -e 's/reduce_bitmap_factor//' | sed -e 's/ //g' | sed -e 's/=//g'`
panoply_file_list=`cat ../../cfg/config.cfg | grep "panoply_file_list" | sed -e 's/panoply_file_list//' | sed -e 's/ //g' | sed -e 's/=//g'` panoply_file_list=`cat ../../cfg/config.cfg | grep "panoply_file_list" | sed -e 's/panoply_file_list//' | sed -e 's/ //g' | sed -e 's/=//g'`
if test "$panoply_file_list" ; then if test "$panoply_file_list" ; then
rm $panoply_file_list rm $panoply_file_list
panoply_config_file=`cat ../../cfg/directories.cfg | grep "panoply_config_file" | sed -e 's/panoply_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'` panoply_config_file=`cat ../../cfg/directories.cfg | grep "panoply_config_file" | sed -e 's/panoply_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'`
for psource in $panoply_config_file ; do for psource in $panoply_config_file ; do
cp $database_directory/$psource current_panoply.cfg cp $database_directory/$psource current_panoply.cfg
echo "output_path=\"panoply\";" >> current_panoply.cfg echo "output_path=\"panoply\";" >> current_panoply.cfg
echo "cache_path=\"cache\";" >> current_panoply.cfg echo "cache_path=\"cache\";" >> current_panoply.cfg
panoply_maker.exe current_panoply.cfg panoply_maker.exe current_panoply.cfg
# Idle # Idle
../../idle.bat ../../idle.bat
done done
ls panoply >> $panoply_file_list ls panoply >> $panoply_file_list
fi fi
# For each directoy # For each directoy
for i in tga/*.[tT][gG][aA] ; do for i in tga/*.[tT][gG][aA] ; do
# Destination file # Destination file
dest=`echo $i | sed -e 's/[tT][gG][aA]/dds/' | sed -e 's/\.[tT][gG][aA]/.dds/g'` dest=`echo $i | sed -e 's/[tT][gG][aA]/dds/' | sed -e 's/\.[tT][gG][aA]/.dds/g'`
dds=`echo $i | sed -e 's/\.[tT][gG][aA]/.dds/g'` dds=`echo $i | sed -e 's/\.[tT][gG][aA]/.dds/g'`
# Convert the lightmap in 16 bits mode # Convert the lightmap in 16 bits mode
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
# Copy the dds file # Copy the dds file
if (test -f $dds) if (test -f $dds)
then then
cp $dds $dest cp $dds $dest
fi fi
# Convert # Convert
$tga_2_dds $i -o $dest -m -r$reduce_bitmap_factor 2>> log.log $tga_2_dds $i -o $dest -m -r$reduce_bitmap_factor 2>> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
for i in panoply/*.[tT][gG][aA] ; do for i in panoply/*.[tT][gG][aA] ; do
# Destination file # Destination file
dest=`echo $i | sed -e 's%panoply/%dds/%g' | sed -e 's/[tT][gG][aA]/dds/g'` dest=`echo $i | sed -e 's%panoply/%dds/%g' | sed -e 's/[tT][gG][aA]/dds/g'`
dds=`echo $i | sed -e 's/\.[tT][gG][aA]/.dds/g'` dds=`echo $i | sed -e 's/\.[tT][gG][aA]/.dds/g'`
# Convert the lightmap in 16 bits mode # Convert the lightmap in 16 bits mode
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
# Copy the dds file # Copy the dds file
if (test -f $dds) if (test -f $dds)
then then
cp $dds $dest cp $dds $dest
fi fi
# Convert # Convert
$tga_2_dds $i -o $dest -m -r$reduce_bitmap_factor 2>> log.log $tga_2_dds $i -o $dest -m -r$reduce_bitmap_factor 2>> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Bin # Bin
hls_bank_maker='hls_bank_maker.exe' hls_bank_maker='hls_bank_maker.exe'
# build the HLSBank (if hlsInfo present, and if build wanted) # build the HLSBank (if hlsInfo present, and if build wanted)
hls_bank_file_name=`cat ../../cfg/config.cfg | grep "hls_bank_file_name" | sed -e 's/hls_bank_file_name//' | sed -e 's/ //g' | sed -e 's/=//g'` hls_bank_file_name=`cat ../../cfg/config.cfg | grep "hls_bank_file_name" | sed -e 's/hls_bank_file_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
if test "$hls_bank_file_name" ; then if test "$hls_bank_file_name" ; then
rm $hls_bank_file_name rm $hls_bank_file_name
$hls_bank_maker hlsinfo $hls_bank_file_name $hls_bank_maker hlsinfo $hls_bank_file_name
fi fi
# Put old panoply in cache # Put old panoply in cache
echo Remove the panoply cache echo Remove the panoply cache
rm -r cache 2>> log.log rm -r cache 2>> log.log
echo Rename panoply as cache echo Rename panoply as cache
mv panoply cache 2>> log.log mv panoply cache 2>> log.log
echo Move hlsinfo into cache echo Move hlsinfo into cache
cp -u -p -R hlsinfo/. cache 2>> log.log cp -u -p -R hlsinfo/. cache 2>> log.log
echo Remove the hlsinfo echo Remove the hlsinfo
rm -r hlsinfo 2>> log.log rm -r hlsinfo 2>> log.log

@ -1,57 +1,57 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export maps files (.tga / *.[dD][dD][sS]) from the database # *** Export maps files (.tga / *.[dD][dD][sS]) from the database
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the maps directories # Get the maps directories
map_source_directories=`cat ../../cfg/directories.cfg | grep "map_source_directory" | sed -e 's/map_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` map_source_directories=`cat ../../cfg/directories.cfg | grep "map_source_directory" | sed -e 's/map_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
map_uncompressed_source_directories=`cat ../../cfg/directories.cfg | grep "map_uncompressed_source_directory" | sed -e 's/map_uncompressed_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` map_uncompressed_source_directories=`cat ../../cfg/directories.cfg | grep "map_uncompressed_source_directory" | sed -e 's/map_uncompressed_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export map >> log.log echo --- Export map >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export map echo --- Export map
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $map_source_directories; do for i in $map_source_directories; do
for j in $database_directory/$i/*.[tT][gG][aA]; do for j in $database_directory/$i/*.[tT][gG][aA]; do
if ( test -f $j ) if ( test -f $j )
then then
# Get the dds version # Get the dds version
dds=`echo $j | sed -e 's&.tga&.dds&g'` dds=`echo $j | sed -e 's&.tga&.dds&g'`
# Copy the dds and the tga # Copy the dds and the tga
cp -u -p $j tga 2>> log.log cp -u -p $j tga 2>> log.log
if ( test -f $dds ) if ( test -f $dds )
then then
cp -u -p $dds tga 2>> log.log cp -u -p $dds tga 2>> log.log
fi fi
fi fi
done done
# Idle # Idle
../../idle.bat ../../idle.bat
done done
for i in $map_uncompressed_source_directories; do for i in $map_uncompressed_source_directories; do
for j in $database_directory/$i/*.[tT][gG][aA]; do for j in $database_directory/$i/*.[tT][gG][aA]; do
if ( test -f $j ) if ( test -f $j )
then then
# Copy the dds and the tga # Copy the dds and the tga
cp -u -p $j tga_uncompressed 2>> log.log cp -u -p $j tga_uncompressed 2>> log.log
fi fi
done done
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,55 +1,55 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install maps in the client data # Install maps in the client data
# Get the skel install directory # Get the skel install directory
bitmap_install_directory=`cat ../../cfg/directories.cfg | grep "bitmap_install_directory" | sed -e 's/bitmap_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` bitmap_install_directory=`cat ../../cfg/directories.cfg | grep "bitmap_install_directory" | sed -e 's/bitmap_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install maps >> log.log echo --- Install maps >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install maps echo --- Install maps
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R dds/. $client_directory/$bitmap_install_directory 2>> log.log cp -u -p -R dds/. $client_directory/$bitmap_install_directory 2>> log.log
cp -u -p -R tga_uncompressed/. $client_directory/$bitmap_install_directory 2>> log.log cp -u -p -R tga_uncompressed/. $client_directory/$bitmap_install_directory 2>> log.log
panoply_file_list=`cat ../../cfg/config.cfg | grep "panoply_file_list" | sed -e 's/panoply_file_list//' | sed -e 's/ //g' | sed -e 's/=//g'` panoply_file_list=`cat ../../cfg/config.cfg | grep "panoply_file_list" | sed -e 's/panoply_file_list//' | sed -e 's/ //g' | sed -e 's/=//g'`
if test "$panoply_file_list" ; then if test "$panoply_file_list" ; then
cp -u -p $panoply_file_list $client_directory/$bitmap_install_directory 2>> log.log cp -u -p $panoply_file_list $client_directory/$bitmap_install_directory 2>> log.log
panoply_config_file=`cat ../../cfg/directories.cfg | grep "panoply_config_file" | sed -e 's/panoply_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'` panoply_config_file=`cat ../../cfg/directories.cfg | grep "panoply_config_file" | sed -e 's/panoply_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'`
for psource in $panoply_config_file ; do for psource in $panoply_config_file ; do
cp $database_directory/$psource $client_directory/$bitmap_install_directory/panoply.cfg cp $database_directory/$psource $client_directory/$bitmap_install_directory/panoply.cfg
done done
ls panoply >> $panoply_file_list ls panoply >> $panoply_file_list
fi fi
# Install hlsbank in the client data, in the "maps/" directory # Install hlsbank in the client data, in the "maps/" directory
# Log error # Log error
echo --- Install hlsbank >> log.log echo --- Install hlsbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install hlsbank echo --- Install hlsbank
echo ------- echo -------
date >> log.log date >> log.log
date date
# build the HLSBank (if hlsInfo present, and if build wanted) # build the HLSBank (if hlsInfo present, and if build wanted)
hls_bank_file_name=`cat ../../cfg/config.cfg | grep "hls_bank_file_name" | sed -e 's/hls_bank_file_name//' | sed -e 's/ //g' | sed -e 's/=//g'` hls_bank_file_name=`cat ../../cfg/config.cfg | grep "hls_bank_file_name" | sed -e 's/hls_bank_file_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
if test "$hls_bank_file_name" ; then if test "$hls_bank_file_name" ; then
cp -u -p -R $hls_bank_file_name $client_directory/$bitmap_install_directory 2>> log.log cp -u -p -R $hls_bank_file_name $client_directory/$bitmap_install_directory 2>> log.log
fi fi

@ -1,59 +1,59 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export pacs_prim files (.pacs_prim) from Max # *** Export pacs_prim files (.pacs_prim) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "pacs_prim_export_timeout" | sed -e 's/pacs_prim_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "pacs_prim_export_timeout" | sed -e 's/pacs_prim_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the collision directories # Get the collision directories
pacs_prim_source_directories=`cat ../../cfg/directories.cfg | grep "pacs_prim_source_directories" | sed -e 's/pacs_prim_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` pacs_prim_source_directories=`cat ../../cfg/directories.cfg | grep "pacs_prim_source_directories" | sed -e 's/pacs_prim_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export pacs_prim for pacs_prim >> log.log echo --- Export pacs_prim for pacs_prim >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export pacs_prim for pacs_prim echo --- Export pacs_prim for pacs_prim
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $pacs_prim_source_directories ; do for i in $pacs_prim_source_directories ; do
# Copy the script # Copy the script
cat maxscript/pacs_prim_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/pacs_prim/log.log&g" | sed -e "s&pacs_prim_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/pacs_prim/pacs_prim&g" > $max_directory/scripts/pacs_prim_export.ms cat maxscript/pacs_prim_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/pacs_prim/log.log&g" | sed -e "s&pacs_prim_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/pacs_prim/pacs_prim&g" > $max_directory/scripts/pacs_prim_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript pacs_prim_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript pacs_prim_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript pacs_prim_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript pacs_prim_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript pacs_prim_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript pacs_prim_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done
rm landscape_col_prim_pacs_list.txt rm landscape_col_prim_pacs_list.txt

@ -1,30 +1,30 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the zonels in the client data # Install the zonels in the client data
# Get the zone install directory # Get the zone install directory
pacs_primitive_install_directory=`cat ../../cfg/directories.cfg | grep "pacs_primitive_install_directory" | sed -e 's/pacs_primitive_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` pacs_primitive_install_directory=`cat ../../cfg/directories.cfg | grep "pacs_primitive_install_directory" | sed -e 's/pacs_primitive_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Test if there is a need for the prim pacs directory # Test if there is a need for the prim pacs directory
want_landscape_col_prim_pacs_list=`cat ../../cfg/config.cfg | grep "want_landscape_col_prim_pacs_list"` want_landscape_col_prim_pacs_list=`cat ../../cfg/config.cfg | grep "want_landscape_col_prim_pacs_list"`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install zone >> log.log echo --- Install zone >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install zone echo --- Install zone
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R pacs_prim/. $client_directory/$pacs_primitive_install_directory 2>> log.log cp -u -p -R pacs_prim/. $client_directory/$pacs_primitive_install_directory 2>> log.log
if test "$want_landscape_col_prim_pacs_list" ; then if test "$want_landscape_col_prim_pacs_list" ; then
ls pacs_prim | grep ".pacs_prim" >> $client_directory/landscape_col_prim_pacs_list.txt ls pacs_prim | grep ".pacs_prim" >> $client_directory/landscape_col_prim_pacs_list.txt
fi fi

@ -1,31 +1,31 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export particle system file (.ps) # *** Export particle system file (.ps)
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the ps directories # Get the ps directories
ps_source_directories=`cat ../../cfg/directories.cfg | grep "ps_source_directory" | sed -e 's/ps_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ps_source_directories=`cat ../../cfg/directories.cfg | grep "ps_source_directory" | sed -e 's/ps_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export ps >> log.log echo --- Export ps >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export ps echo --- Export ps
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each ps directory # For each ps directory
for i in $ps_source_directories ; do for i in $ps_source_directories ; do
# Copy # Copy
cp -u -p $database_directory/$i/*.[pP][sS] ps 2>> log.log cp -u -p $database_directory/$i/*.[pP][sS] ps 2>> log.log
cp -u -p $database_directory/$i/*.[sS][hH][aA][pP][eE] ps 2>> log.log cp -u -p $database_directory/$i/*.[sS][hH][aA][pP][eE] ps 2>> log.log
cp -u -p $database_directory/$i/*.[pP][rR][iI][mM][iI][tT][iI][vV][eE] ps 2>> log.log cp -u -p $database_directory/$i/*.[pP][rR][iI][mM][iI][tT][iI][vV][eE] ps 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the particule system in the client data # Install the particule system in the client data
# Get the ps install directory # Get the ps install directory
ps_install_directory=`cat ../../cfg/directories.cfg | grep "ps_install_directory" | sed -e 's/ps_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ps_install_directory=`cat ../../cfg/directories.cfg | grep "ps_install_directory" | sed -e 's/ps_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install ps >> log.log echo --- Install ps >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install ps echo --- Install ps
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R ps/. $client_directory/$ps_install_directory 2>> log.log cp -u -p -R ps/. $client_directory/$ps_install_directory 2>> log.log

@ -1,358 +1,358 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Build zone # Build zone
build_rbank='build_rbank.exe' build_rbank='build_rbank.exe'
build_indoor_rbank='build_indoor_rbank.exe' build_indoor_rbank='build_indoor_rbank.exe'
build_ig_boxes='build_ig_boxes.exe' build_ig_boxes='build_ig_boxes.exe'
ai_build_wmap='ai_build_wmap_r.exe' ai_build_wmap='ai_build_wmap_r.exe'
get_neighbors='get_neighbors.exe' get_neighbors='get_neighbors.exe'
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
tessel_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_tessel_timeout" | sed -e 's/rbank_build_tessel_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` tessel_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_tessel_timeout" | sed -e 's/rbank_build_tessel_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
smooth_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_smooth_timeout" | sed -e 's/rbank_build_smooth_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` smooth_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_smooth_timeout" | sed -e 's/rbank_build_smooth_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
proclocal_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_proclocal_timeout" | sed -e 's/rbank_build_proclocal_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` proclocal_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_proclocal_timeout" | sed -e 's/rbank_build_proclocal_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
procglobal_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_procglobal_timeout" | sed -e 's/rbank_build_procglobal_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` procglobal_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_procglobal_timeout" | sed -e 's/rbank_build_procglobal_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
indoor_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_indoor_timeout" | sed -e 's/rbank_build_indoor_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` indoor_timeout=`cat ../../cfg/config.cfg | grep "rbank_build_indoor_timeout" | sed -e 's/rbank_build_indoor_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
build_wmap_timeout=`cat ../../cfg/config.cfg | grep "build_wmap_timeout" | sed -e 's/build_wmap_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` build_wmap_timeout=`cat ../../cfg/config.cfg | grep "build_wmap_timeout" | sed -e 's/build_wmap_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the quality option to choose the goor properties.cfg file # Get the quality option to choose the goor properties.cfg file
quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"` quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"`
# **** Copy ig and shapes # **** Copy ig and shapes
# Log error # Log error
echo >> log.log echo >> log.log
echo ------- > log.log echo ------- > log.log
echo --- Generate config script >> log.log echo --- Generate config script >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Generate config script echo --- Generate config script
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
# Get arguments # Get arguments
rbank_bank_name=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'` rbank_bank_name=`cat ../../cfg/properties.cfg | grep "bank_name" | sed -e 's/bank_name//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/"//g' | sed -e 's/;//g'`
rbank_reduce_surfaces=`cat ../../cfg/config.cfg | grep "rbank_reduce_surfaces" | sed -e 's/rbank_reduce_surfaces//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_reduce_surfaces=`cat ../../cfg/config.cfg | grep "rbank_reduce_surfaces" | sed -e 's/rbank_reduce_surfaces//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_smooth_borders=`cat ../../cfg/config.cfg | grep "rbank_smooth_borders" | sed -e 's/rbank_smooth_borders//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_smooth_borders=`cat ../../cfg/config.cfg | grep "rbank_smooth_borders" | sed -e 's/rbank_smooth_borders//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_compute_elevation=`cat ../../cfg/config.cfg | grep "rbank_compute_elevation" | sed -e 's/rbank_compute_elevation//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_compute_elevation=`cat ../../cfg/config.cfg | grep "rbank_compute_elevation" | sed -e 's/rbank_compute_elevation//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_compute_levels=`cat ../../cfg/config.cfg | grep "rbank_compute_levels" | sed -e 's/rbank_compute_levels//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_compute_levels=`cat ../../cfg/config.cfg | grep "rbank_compute_levels" | sed -e 's/rbank_compute_levels//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_link_elements=`cat ../../cfg/config.cfg | grep "rbank_link_elements" | sed -e 's/rbank_link_elements//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_link_elements=`cat ../../cfg/config.cfg | grep "rbank_link_elements" | sed -e 's/rbank_link_elements//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_cut_edges=`cat ../../cfg/config.cfg | grep "rbank_cut_edges" | sed -e 's/rbank_cut_edges//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_cut_edges=`cat ../../cfg/config.cfg | grep "rbank_cut_edges" | sed -e 's/rbank_cut_edges//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_use_zone_square=`cat ../../cfg/config.cfg | grep "rbank_use_zone_square" | sed -e 's/rbank_use_zone_square//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_use_zone_square=`cat ../../cfg/config.cfg | grep "rbank_use_zone_square" | sed -e 's/rbank_use_zone_square//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_zone_ul=`cat ../../cfg/config.cfg | grep "rbank_zone_ul" | sed -e 's/rbank_zone_ul//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_zone_ul=`cat ../../cfg/config.cfg | grep "rbank_zone_ul" | sed -e 's/rbank_zone_ul//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_zone_dr=`cat ../../cfg/config.cfg | grep "rbank_zone_dr" | sed -e 's/rbank_zone_dr//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_zone_dr=`cat ../../cfg/config.cfg | grep "rbank_zone_dr" | sed -e 's/rbank_zone_dr//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_rbank_name=`cat ../../cfg/config.cfg | grep "rbank_rbank_name" | sed -e 's/rbank_rbank_name//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_rbank_name=`cat ../../cfg/config.cfg | grep "rbank_rbank_name" | sed -e 's/rbank_rbank_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_ig_pathes=`cat ../../cfg/config.cfg | grep "rbank_ig_path" | sed -e 's/rbank_ig_path//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_ig_pathes=`cat ../../cfg/config.cfg | grep "rbank_ig_path" | sed -e 's/rbank_ig_path//' | sed -e 's/ //g' | sed -e 's/=//g'`
rbank_shape_pathes=`cat ../../cfg/config.cfg | grep "rbank_shape_path" | sed -e 's/rbank_shape_path//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_shape_pathes=`cat ../../cfg/config.cfg | grep "rbank_shape_path" | sed -e 's/rbank_shape_path//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Global options # Global options
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo >> log.log echo >> log.log
echo ------- >> log.log echo ------- >> log.log
echo --- Build RBank : Build the bbox file >> log.log echo --- Build RBank : Build the bbox file >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Build RBank : Build the bbox file echo --- Build RBank : Build the bbox file
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
# ***** Build the bbox file # ***** Build the bbox file
# Remove the config file # Remove the config file
rm build_ig_boxes.cfg rm build_ig_boxes.cfg
# List ig pathes # List ig pathes
echo Pathes = \{ >> build_ig_boxes.cfg echo Pathes = \{ >> build_ig_boxes.cfg
for i in $rbank_ig_pathes ; do for i in $rbank_ig_pathes ; do
echo \"$i\"\, >> build_ig_boxes.cfg echo \"$i\"\, >> build_ig_boxes.cfg
done done
for i in $rbank_shape_pathes ; do for i in $rbank_shape_pathes ; do
echo \"$i\"\, >> build_ig_boxes.cfg echo \"$i\"\, >> build_ig_boxes.cfg
done done
echo \}\; >> build_ig_boxes.cfg echo \}\; >> build_ig_boxes.cfg
# List igs # List igs
echo IGs = \{ >> build_ig_boxes.cfg echo IGs = \{ >> build_ig_boxes.cfg
for i in $rbank_ig_pathes ; do for i in $rbank_ig_pathes ; do
cd $i cd $i
list_ig=`ls -1 *.[iI][gG]` list_ig=`ls -1 *.[iI][gG]`
cd $build_gamedata_directory"/processes/rbank" cd $build_gamedata_directory"/processes/rbank"
for j in $list_ig ; do for j in $list_ig ; do
n=`echo $j | sed -e 's/.ig//'` n=`echo $j | sed -e 's/.ig//'`
echo \"$n\"\, >> build_ig_boxes.cfg echo \"$n\"\, >> build_ig_boxes.cfg
done done
# Idle # Idle
../../idle.bat ../../idle.bat
done done
echo \}\; >> build_ig_boxes.cfg echo \}\; >> build_ig_boxes.cfg
echo Output = \"bbox/temp.bbox\"\; >> build_ig_boxes.cfg echo Output = \"bbox/temp.bbox\"\; >> build_ig_boxes.cfg
# -- NOT NEEDED ANYMORE # -- NOT NEEDED ANYMORE
$build_ig_boxes $build_ig_boxes
# ***** Build the rbank, gr files # ***** Build the rbank, gr files
# Copy the good template file # Copy the good template file
if ( test "$quality_flag" ) if ( test "$quality_flag" )
then then
# We are in BEST mode # We are in BEST mode
`cat cfg/template_final.cfg | sed -e "s&rbank_bank_name&$rbank_bank_name&g" | sed -e "s&rbank_reduce_surfaces&$rbank_reduce_surfaces&g" | sed -e "s&rbank_smooth_borders&$rbank_smooth_borders&g" | sed -e "s&rbank_compute_elevation&$rbank_compute_elevation&g" | sed -e "s&rbank_compute_levels&$rbank_compute_levels&g" | sed -e "s&rbank_link_elements&$rbank_link_elements&g" | sed -e "s&rbank_cut_edges&$rbank_cut_edges&g" | sed -e "s&rbank_use_zone_square&$rbank_use_zone_square&g" | sed -e "s&rbank_zone_ul&$rbank_zone_ul&g" | sed -e "s&rbank_zone_dr&$rbank_zone_dr&g" > build_rbank.cfg` `cat cfg/template_final.cfg | sed -e "s&rbank_bank_name&$rbank_bank_name&g" | sed -e "s&rbank_reduce_surfaces&$rbank_reduce_surfaces&g" | sed -e "s&rbank_smooth_borders&$rbank_smooth_borders&g" | sed -e "s&rbank_compute_elevation&$rbank_compute_elevation&g" | sed -e "s&rbank_compute_levels&$rbank_compute_levels&g" | sed -e "s&rbank_link_elements&$rbank_link_elements&g" | sed -e "s&rbank_cut_edges&$rbank_cut_edges&g" | sed -e "s&rbank_use_zone_square&$rbank_use_zone_square&g" | sed -e "s&rbank_zone_ul&$rbank_zone_ul&g" | sed -e "s&rbank_zone_dr&$rbank_zone_dr&g" > build_rbank.cfg`
else else
# We are in DRAFT mode # We are in DRAFT mode
`cat cfg/template_draft.cfg | sed -e "s&rbank_bank_name&$rbank_bank_name&g" | sed -e "s&rbank_reduce_surfaces&$rbank_reduce_surfaces&g" | sed -e "s&rbank_smooth_borders&$rbank_smooth_borders&g" | sed -e "s&rbank_compute_elevation&$rbank_compute_elevation&g" | sed -e "s&rbank_compute_levels&$rbank_compute_levels&g" | sed -e "s&rbank_link_elements&$rbank_link_elements&g" | sed -e "s&rbank_cut_edges&$rbank_cut_edges&g" | sed -e "s&rbank_use_zone_square&$rbank_use_zone_square&g" | sed -e "s&rbank_zone_ul&$rbank_zone_ul&g" | sed -e "s&rbank_zone_dr&$rbank_zone_dr&g" > build_rbank.cfg` `cat cfg/template_draft.cfg | sed -e "s&rbank_bank_name&$rbank_bank_name&g" | sed -e "s&rbank_reduce_surfaces&$rbank_reduce_surfaces&g" | sed -e "s&rbank_smooth_borders&$rbank_smooth_borders&g" | sed -e "s&rbank_compute_elevation&$rbank_compute_elevation&g" | sed -e "s&rbank_compute_levels&$rbank_compute_levels&g" | sed -e "s&rbank_link_elements&$rbank_link_elements&g" | sed -e "s&rbank_cut_edges&$rbank_cut_edges&g" | sed -e "s&rbank_use_zone_square&$rbank_use_zone_square&g" | sed -e "s&rbank_zone_ul&$rbank_zone_ul&g" | sed -e "s&rbank_zone_dr&$rbank_zone_dr&g" > build_rbank.cfg`
fi fi
# List the zones to add # List the zones to add
cd ../zone/zone_welded cd ../zone/zone_welded
list_zone=`ls -1 *.[zZ][oO][nN][eE][wW]` list_zone=`ls -1 *.[zZ][oO][nN][eE][wW]`
cd ../../rbank cd ../../rbank
# Make a zone list # Make a zone list
for i in $list_zone ; do for i in $list_zone ; do
echo \"$i\", >> build_rbank.cfg echo \"$i\", >> build_rbank.cfg
done done
# Close the file # Close the file
echo "};" >> build_rbank.cfg echo "};" >> build_rbank.cfg
echo " " >> build_rbank.cfg echo " " >> build_rbank.cfg
# List ig pathes # List ig pathes
echo Pathes = \{ >> build_rbank.cfg echo Pathes = \{ >> build_rbank.cfg
for i in $rbank_ig_pathes ; do for i in $rbank_ig_pathes ; do
echo \"$i\"\, >> build_rbank.cfg echo \"$i\"\, >> build_rbank.cfg
done done
for i in $rbank_shape_pathes ; do for i in $rbank_shape_pathes ; do
echo \"$i\"\, >> build_rbank.cfg echo \"$i\"\, >> build_rbank.cfg
done done
echo \}\; >> build_rbank.cfg echo \}\; >> build_rbank.cfg
echo " " >> build_rbank.cfg echo " " >> build_rbank.cfg
# Log error # Log error
echo >> log.log echo >> log.log
echo ------- >> log.log echo ------- >> log.log
echo --- Build RBank : Check pacs primitives consistency >> log.log echo --- Build RBank : Check pacs primitives consistency >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Build RBank : Check pacs primitives consistency echo --- Build RBank : Check pacs primitives consistency
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
# ******* PASS 1 Generate smooth lr # ******* PASS 1 Generate smooth lr
# For each ../zone/zone_welded/*.[zZ][oO][nN][eE][wW] files, checks if the associated scratch/tesselation/*.[tT][eE][sS][sS][eE][lL] file # For each ../zone/zone_welded/*.[zZ][oO][nN][eE][wW] files, checks if the associated scratch/tesselation/*.[tT][eE][sS][sS][eE][lL] file
# are up to date with the .zonew and the 8 neighbor .zonew file. If note, tesselate it. # are up to date with the .zonew and the 8 neighbor .zonew file. If note, tesselate it.
$exec_timeout $tessel_timeout $build_rbank -C -p -g $exec_timeout $tessel_timeout $build_rbank -C -p -g
# Log error # Log error
echo >> log.log echo >> log.log
echo ------- >> log.log echo ------- >> log.log
echo --- Build RBank : Generate lr >> log.log echo --- Build RBank : Generate lr >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Build RBank : Generate lr echo --- Build RBank : Generate lr
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
for i in $list_zone ; do for i in $list_zone ; do
# Get destination file # Get destination file
zone=`echo $i | sed -e 's/.zonew//'` zone=`echo $i | sed -e 's/.zonew//'`
# Lr final # Lr final
lr1=`echo "smooth/"$zone".lr"` lr1=`echo "smooth/"$zone".lr"`
# Get the 9 zones list # Get the 9 zones list
near_zone=`$get_neighbors $zone` near_zone=`$get_neighbors $zone`
# Zone to build # Zone to build
zone_to_build=`echo ""` zone_to_build=`echo ""`
# For each zone near # For each zone near
if ( ! test -e $lr1 ) if ( ! test -e $lr1 )
then then
zone_to_build=`echo "../zone/zone_welded/"$i` zone_to_build=`echo "../zone/zone_welded/"$i`
else else
for j in $near_zone ; do for j in $near_zone ; do
if ( test "../zone/zone_welded/"$j.zonew -nt $lr1 ) if ( test "../zone/zone_welded/"$j.zonew -nt $lr1 )
then then
zone_to_build=`echo "../zone/zone_welded/"$i` zone_to_build=`echo "../zone/zone_welded/"$i`
fi fi
done done
fi fi
# Build it only if the file exist # Build it only if the file exist
if ( test "$zone_to_build" ) if ( test "$zone_to_build" )
then then
# Build lr # Build lr
$exec_timeout $tessel_timeout $build_rbank -c -P -g $i $exec_timeout $tessel_timeout $build_rbank -c -P -g $i
echo echo
echo >> log.log echo >> log.log
else else
echo SKIPPED $dest echo SKIPPED $dest
echo echo
echo SKIPPED $lr1 >> log.log echo SKIPPED $lr1 >> log.log
echo >> log.log echo >> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Log error # Log error
echo >> log.log echo >> log.log
echo ------- >> log.log echo ------- >> log.log
echo --- Build RBank : Procglobal >> log.log echo --- Build RBank : Procglobal >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Build RBank : Procglobal echo --- Build RBank : Procglobal
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
# Procglobal # Procglobal
$exec_timeout $procglobal_timeout $build_rbank -c -p -G $exec_timeout $procglobal_timeout $build_rbank -c -p -G
# ***** Build the cfg for interiors # ***** Build the cfg for interiors
rm build_indoor_rbank.cfg rm build_indoor_rbank.cfg
echo MeshPath = \"cmb/\"\; >> build_indoor_rbank.cfg echo MeshPath = \"cmb/\"\; >> build_indoor_rbank.cfg
echo Meshes = { >> build_indoor_rbank.cfg echo Meshes = { >> build_indoor_rbank.cfg
# List the cmb to merge # List the cmb to merge
cd cmb cd cmb
list_cmb=`ls -1 *.[cC][mM][bB]` list_cmb=`ls -1 *.[cC][mM][bB]`
cd .. cd ..
for i in $list_cmb ; do for i in $list_cmb ; do
n=`echo $i | sed -e 's/.cmb//'` n=`echo $i | sed -e 's/.cmb//'`
echo \"$n\", >> build_indoor_rbank.cfg echo \"$n\", >> build_indoor_rbank.cfg
# Idle # Idle
../../idle.bat ../../idle.bat
done done
echo "};" >> build_indoor_rbank.cfg echo "};" >> build_indoor_rbank.cfg
echo OutputPath = \""retrievers/"\"\; >> build_indoor_rbank.cfg echo OutputPath = \""retrievers/"\"\; >> build_indoor_rbank.cfg
echo OutputPrefix = "unused"\; >> build_indoor_rbank.cfg echo OutputPrefix = "unused"\; >> build_indoor_rbank.cfg
echo Merge = 1\; >> build_indoor_rbank.cfg echo Merge = 1\; >> build_indoor_rbank.cfg
echo MergePath = \""smooth/"\"\; >> build_indoor_rbank.cfg echo MergePath = \""smooth/"\"\; >> build_indoor_rbank.cfg
echo MergeInputPrefix = \"temp\"\; >> build_indoor_rbank.cfg echo MergeInputPrefix = \"temp\"\; >> build_indoor_rbank.cfg
echo MergeOutputPrefix = \"tempMerged\"\; >> build_indoor_rbank.cfg echo MergeOutputPrefix = \"tempMerged\"\; >> build_indoor_rbank.cfg
echo AddToRetriever = \"1\"\; >> build_indoor_rbank.cfg echo AddToRetriever = \"1\"\; >> build_indoor_rbank.cfg
# Log error # Log error
echo >> log.log echo >> log.log
echo ------- >> log.log echo ------- >> log.log
echo --- Build RBank : Merge cmb in rbank >> log.log echo --- Build RBank : Merge cmb in rbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Build RBank : Merge cmb in rbank echo --- Build RBank : Merge cmb in rbank
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
$exec_timeout $indoor_timeout $build_indoor_rbank $exec_timeout $indoor_timeout $build_indoor_rbank
echo >> log.log echo >> log.log
echo ------- >> log.log echo ------- >> log.log
echo --- Build RBank : Copy gr, rbank and lr >> log.log echo --- Build RBank : Copy gr, rbank and lr >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Build RBank : Copy gr, rbank and lr echo --- Build RBank : Copy gr, rbank and lr
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
# Copy the files # Copy the files
mv "retrievers"/tempMerged.rbank output/$rbank_rbank_name".rbank" 2>> log.log mv "retrievers"/tempMerged.rbank output/$rbank_rbank_name".rbank" 2>> log.log
mv "retrievers"/tempMerged.gr output/$rbank_rbank_name".gr" 2>> log.log mv "retrievers"/tempMerged.gr output/$rbank_rbank_name".gr" 2>> log.log
for i in "retrievers"/tempMerged_*.lr ; do for i in "retrievers"/tempMerged_*.lr ; do
finalname=`echo $i | sed -e "s/tempMerged/$rbank_rbank_name/" | sed -e 's/retrievers/output/'` finalname=`echo $i | sed -e "s/tempMerged/$rbank_rbank_name/" | sed -e 's/retrievers/output/'`
mv $i $finalname mv $i $finalname
done done
# #
# removed from pacs process, ai_build_wmap is built later, independently # removed from pacs process, ai_build_wmap is built later, independently
# #
# Check ai_build_wmap exist # Check ai_build_wmap exist
#if ( test -f $ai_build_wmap ) #if ( test -f $ai_build_wmap )
#then #then
# # setup config file for ai_build_wmap # # setup config file for ai_build_wmap
# rm ./ai_build_wmap.cfg # rm ./ai_build_wmap.cfg
# cp cfg/ai_build_wmap.cfg ./ai_build_wmap.cfg # cp cfg/ai_build_wmap.cfg ./ai_build_wmap.cfg
# #
# # generate wmap # # generate wmap
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsCrunch $rbank_rbank_name" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsCrunch $rbank_rbank_name"
# #
# # generate sizes # # generate sizes
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildGabarit $rbank_rbank_name" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildGabarit $rbank_rbank_name"
# #
# # generate cwmaps for each size # # generate cwmaps for each size
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildWmap ${rbank_rbank_name}_0" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildWmap ${rbank_rbank_name}_0"
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildWmap ${rbank_rbank_name}_1" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildWmap ${rbank_rbank_name}_1"
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildWmap ${rbank_rbank_name}_2" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildWmap ${rbank_rbank_name}_2"
# #
# # generate bitmap for each size # # generate bitmap for each size
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildBitmap ${rbank_rbank_name}_0" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildBitmap ${rbank_rbank_name}_0"
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildBitmap ${rbank_rbank_name}_1" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildBitmap ${rbank_rbank_name}_1"
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildBitmap ${rbank_rbank_name}_2" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsBuildBitmap ${rbank_rbank_name}_2"
# #
# # clear height maps for size 1 and 2 # # clear height maps for size 1 and 2
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsClearHeightmap ${rbank_rbank_name}_1" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsClearHeightmap ${rbank_rbank_name}_1"
# $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsClearHeightmap ${rbank_rbank_name}_2" # $exec_timeout $build_wmap_timeout $ai_build_wmap "pacsClearHeightmap ${rbank_rbank_name}_2"
# #
# rm output/$rbank_rbank_name.wmap # rm output/$rbank_rbank_name.wmap
# rm output/${rbank_rbank_name}_0.wmap # rm output/${rbank_rbank_name}_0.wmap
# rm output/${rbank_rbank_name}_1.wmap # rm output/${rbank_rbank_name}_1.wmap
# rm output/${rbank_rbank_name}_2.wmap # rm output/${rbank_rbank_name}_2.wmap
#fi #fi

@ -1,31 +1,31 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Log error # Log error
echo >> log.log echo >> log.log
echo ------- > log.log echo ------- > log.log
echo --- Clean rbank >> log.log echo --- Clean rbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo >> log.log echo >> log.log
echo echo
echo ------- echo -------
echo --- Clean rbank echo --- Clean rbank
echo ------- echo -------
echo echo
date >> log.log date >> log.log
date date
# Get arguments # Get arguments
rbank_rbank_name=`cat ../../cfg/config.cfg | grep "rbank_rbank_name" | sed -e 's/rbank_rbank_name//' | sed -e 's/ //g' | sed -e 's/=//g'` rbank_rbank_name=`cat ../../cfg/config.cfg | grep "rbank_rbank_name" | sed -e 's/rbank_rbank_name//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Delete temp files # Delete temp files
rm tesselation/*.[tT][eE][sS][sS][eE][lL] rm tesselation/*.[tT][eE][sS][sS][eE][lL]
rm smooth/*.[lL][rR] rm smooth/*.[lL][rR]
rm smooth/*.[oO][cC][hH][aA][iI][nN] rm smooth/*.[oO][cC][hH][aA][iI][nN]
rm smooth/*.[gG][rR] rm smooth/*.[gG][rR]
rm smooth/*.[rR][bB][aA][nN][kK] rm smooth/*.[rR][bB][aA][nN][kK]
rm smooth/preproc/*.[lL][rR] rm smooth/preproc/*.[lL][rR]
rm retrievers/*.[gG][rR] rm retrievers/*.[gG][rR]
rm retrievers/*.[rR][bB][aA][nN][kK] rm retrievers/*.[rR][bB][aA][nN][kK]

@ -1,57 +1,57 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export cmb files (.cmb) from Max # *** Export cmb files (.cmb) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "cmb_export_timeout" | sed -e 's/cmb_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "cmb_export_timeout" | sed -e 's/cmb_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the collision directories # Get the collision directories
collision_source_directories=`cat ../../cfg/directories.cfg | grep "cmb_source_directory" | sed -e 's/cmb_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` collision_source_directories=`cat ../../cfg/directories.cfg | grep "cmb_source_directory" | sed -e 's/cmb_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export cmb for rbank >> log.log echo --- Export cmb for rbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export cmb for rbank echo --- Export cmb for rbank
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $collision_source_directories ; do for i in $collision_source_directories ; do
# Copy the script # Copy the script
cat maxscript/rbank_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/rbank/log.log&g" | sed -e "s&collision_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_rbank&$build_gamedata_directory/processes/rbank/cmb&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/rbank/tag&g" > $max_directory/scripts/rbank_export.ms cat maxscript/rbank_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/rbank/log.log&g" | sed -e "s&collision_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_rbank&$build_gamedata_directory/processes/rbank/cmb&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/rbank/tag&g" > $max_directory/scripts/rbank_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript rbank_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript rbank_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript rbank_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript rbank_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript rbank_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript rbank_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the zonels in the client data # Install the zonels in the client data
# Get the zone install directory # Get the zone install directory
pacs_install_directory=`cat ../../cfg/directories.cfg | grep "pacs_install_directory" | sed -e 's/pacs_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` pacs_install_directory=`cat ../../cfg/directories.cfg | grep "pacs_install_directory" | sed -e 's/pacs_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install zone >> log.log echo --- Install zone >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install zone echo --- Install zone
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R output/. $client_directory/$pacs_install_directory 2>> log.log cp -u -p -R output/. $client_directory/$pacs_install_directory 2>> log.log

@ -1,236 +1,236 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Build shape files (.shape) # *** Build shape files (.shape)
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Bin # Bin
tga_2_dds='tga2dds.exe' tga_2_dds='tga2dds.exe'
build_coarse_mesh='build_coarse_mesh.exe' build_coarse_mesh='build_coarse_mesh.exe'
lightmap_optimizer='lightmap_optimizer.exe' lightmap_optimizer='lightmap_optimizer.exe'
build_clodtex='build_clodtex.exe' build_clodtex='build_clodtex.exe'
build_shadow_skin='build_shadow_skin.exe' build_shadow_skin='build_shadow_skin.exe'
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build ShadowSkin shape >> log.log echo --- Build ShadowSkin shape >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build ShadowSkin shape echo --- Build ShadowSkin shape
echo ------- echo -------
date >> log.log date >> log.log
date date
# build shadow skin? # build shadow skin?
do_build_shadow_skin=`cat ../../cfg/config.cfg | grep -w "build_shadow_skin" | sed -e 's/build_shadow_skin//' | sed -e 's/ //g' | sed -e 's/=//g'` do_build_shadow_skin=`cat ../../cfg/config.cfg | grep -w "build_shadow_skin" | sed -e 's/build_shadow_skin//' | sed -e 's/ //g' | sed -e 's/=//g'`
build_shadow_skin_ratio=`cat ../../cfg/config.cfg | grep "build_shadow_skin_ratio" | sed -e 's/build_shadow_skin_ratio//' | sed -e 's/ //g' | sed -e 's/=//g'` build_shadow_skin_ratio=`cat ../../cfg/config.cfg | grep "build_shadow_skin_ratio" | sed -e 's/build_shadow_skin_ratio//' | sed -e 's/ //g' | sed -e 's/=//g'`
build_shadow_skin_maxface=`cat ../../cfg/config.cfg | grep "build_shadow_skin_maxface" | sed -e 's/build_shadow_skin_maxface//' | sed -e 's/ //g' | sed -e 's/=//g'` build_shadow_skin_maxface=`cat ../../cfg/config.cfg | grep "build_shadow_skin_maxface" | sed -e 's/build_shadow_skin_maxface//' | sed -e 's/ //g' | sed -e 's/=//g'`
# if config wanted then must compute shadowSkin # if config wanted then must compute shadowSkin
if ( test "$do_build_shadow_skin" = "1" ) if ( test "$do_build_shadow_skin" = "1" )
then then
for i in shape_not_optimized/*.[sS][hH][aA][pP][eE] ; do for i in shape_not_optimized/*.[sS][hH][aA][pP][eE] ; do
if ( test -f $i ) if ( test -f $i )
then then
dest=`echo $i | sed -e 's/shape_not_optimized/shape/g'` dest=`echo $i | sed -e 's/shape_not_optimized/shape/g'`
# if date is newer in shape_not_optimized than in shape, compute # if date is newer in shape_not_optimized than in shape, compute
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
# NB: overwrite shape_not_optimized, because will be cloded/copied below to shapes/ # NB: overwrite shape_not_optimized, because will be cloded/copied below to shapes/
$build_shadow_skin $i $i $build_shadow_skin_ratio $build_shadow_skin_maxface $build_shadow_skin $i $i $build_shadow_skin_ratio $build_shadow_skin_maxface
fi fi
fi fi
done done
fi fi
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build shape : Copy Shape / build CLodTex >> log.log echo --- Build shape : Copy Shape / build CLodTex >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build shape : Copy Shape / build CLodTex echo --- Build shape : Copy Shape / build CLodTex
echo ------- echo -------
date >> log.log date >> log.log
date date
# Get the lod config file in the database # Get the lod config file in the database
clod_config_file=`cat ../../cfg/config.cfg | grep "clod_config_file" | sed -e 's/clod_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'` clod_config_file=`cat ../../cfg/config.cfg | grep "clod_config_file" | sed -e 's/clod_config_file//' | sed -e 's/ //g' | sed -e 's/=//g'`
# if clod cfg is setup, build clod # if clod cfg is setup, build clod
if (test -f $database_directory/$clod_config_file) if (test -f $database_directory/$clod_config_file)
then then
# build the shape with clod texture. convert from 'shape_not_optimized' to 'shape' # build the shape with clod texture. convert from 'shape_not_optimized' to 'shape'
$build_clodtex -d $database_directory/$clod_config_file clod shape_not_optimized shape $build_clodtex -d $database_directory/$clod_config_file clod shape_not_optimized shape
else else
# just copy shape_not_optimized to shape # just copy shape_not_optimized to shape
./sh/transfert_shape_optimize.bat ./sh/transfert_shape_optimize.bat
fi fi
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build shape : optimize lightmaps >> log.log echo --- Build shape : optimize lightmaps >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build shape : optimize lightmaps echo --- Build shape : optimize lightmaps
echo ------- echo -------
date >> log.log date >> log.log
date date
# copy lightmap_not_optimized to lightmap # copy lightmap_not_optimized to lightmap
./sh/transfert_lightmap_optimize.bat ./sh/transfert_lightmap_optimize.bat
quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"` quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"`
# Optimize lightmaps if any. Additionnaly, output a file indicating which lightmaps are 8 bits # Optimize lightmaps if any. Additionnaly, output a file indicating which lightmaps are 8 bits
$lightmap_optimizer ./lightmap ./shape ./tag ./list_lm_8bit.txt $lightmap_optimizer ./lightmap ./shape ./tag ./list_lm_8bit.txt
# Convert lightmap in 16 bits mode if they are not 8 bits lightmap # Convert lightmap in 16 bits mode if they are not 8 bits lightmap
echo ------- >> log.log echo ------- >> log.log
echo --- Build shape : convert lightmaps in 16 or 8 bits >> log.log echo --- Build shape : convert lightmaps in 16 or 8 bits >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build shape : convert lightmaps in 16 or 8 bits echo --- Build shape : convert lightmaps in 16 or 8 bits
echo ------- echo -------
date >> log.log date >> log.log
date date
for i in lightmap/*.[tT][gG][aA] ; do for i in lightmap/*.[tT][gG][aA] ; do
if ( test -f $i ) if ( test -f $i )
then then
# Destination file # Destination file
dest=`echo $i | sed -e 's/lightmap/lightmap_16_bits/g'` dest=`echo $i | sed -e 's/lightmap/lightmap_16_bits/g'`
# Convert the lightmap in 16 bits mode # Convert the lightmap in 16 bits mode
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
fileTest=`echo $i | sed -e 's&lightmap/&&g'` fileTest=`echo $i | sed -e 's&lightmap/&&g'`
file8Bit=`cat ./list_lm_8bit.txt | grep "$fileTest"` file8Bit=`cat ./list_lm_8bit.txt | grep "$fileTest"`
if ( test "$file8Bit" = "$fileTest" ) if ( test "$file8Bit" = "$fileTest" )
then then
echo "export $fileTest in 8bit format" echo "export $fileTest in 8bit format"
$tga_2_dds $i -o $dest -a tga8 2>> log.log $tga_2_dds $i -o $dest -a tga8 2>> log.log
else else
echo "export $fileTest in 16bit format" echo "export $fileTest in 16bit format"
$tga_2_dds $i -o $dest -a tga16 2>> log.log $tga_2_dds $i -o $dest -a tga16 2>> log.log
fi fi
fi fi
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build shape : build coarse meshes >> log.log echo --- Build shape : build coarse meshes >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build shape : build coarse meshes echo --- Build shape : build coarse meshes
echo ------- echo -------
date >> log.log date >> log.log
date date
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get texture pathes # Get texture pathes
map_source_directories=`cat ../../cfg/directories.cfg | grep "map_source_directory" | sed -e 's/map_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` map_source_directories=`cat ../../cfg/directories.cfg | grep "map_source_directory" | sed -e 's/map_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the texture mul size # Get the texture mul size
texture_mul_size_value=`cat ../../cfg/config.cfg | grep "texture_mul_size_value" | sed -e 's/texture_mul_size_value//' | sed -e 's/ //g' | sed -e 's/=//g'` texture_mul_size_value=`cat ../../cfg/config.cfg | grep "texture_mul_size_value" | sed -e 's/texture_mul_size_value//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the coarse mesh texture name # Get the coarse mesh texture name
coarse_mesh_texture_names=`cat ../../cfg/config.cfg | grep "coarse_mesh_texture_names" | sed -e 's/coarse_mesh_texture_names//' | sed -e 's/ //g' | sed -e 's/=//g'` coarse_mesh_texture_names=`cat ../../cfg/config.cfg | grep "coarse_mesh_texture_names" | sed -e 's/coarse_mesh_texture_names//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Copy the config file header # Copy the config file header
cat cfg/config_header.cfg | sed -e "s/texture_mul_size_value/$texture_mul_size_value/g" > cfg/config_generated.cfg cat cfg/config_header.cfg | sed -e "s/texture_mul_size_value/$texture_mul_size_value/g" > cfg/config_generated.cfg
# Corse meshes for this process ? # Corse meshes for this process ?
if ( test "$coarse_mesh_texture_names" ) then if ( test "$coarse_mesh_texture_names" ) then
# Add the shape directory # Add the shape directory
echo ' "'shape_with_coarse_mesh'"', >> cfg/config_generated.cfg echo ' "'shape_with_coarse_mesh'"', >> cfg/config_generated.cfg
# For each texture path # For each texture path
for i in $map_source_directories ; do for i in $map_source_directories ; do
# Add the path # Add the path
echo ' "'$database_directory/$i'"', >> cfg/config_generated.cfg echo ' "'$database_directory/$i'"', >> cfg/config_generated.cfg
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Add the shape list header # Add the shape list header
echo '};' >> cfg/config_generated.cfg echo '};' >> cfg/config_generated.cfg
echo ' ' >> cfg/config_generated.cfg echo ' ' >> cfg/config_generated.cfg
echo 'list_mesh =' >> cfg/config_generated.cfg echo 'list_mesh =' >> cfg/config_generated.cfg
echo '{' >> cfg/config_generated.cfg echo '{' >> cfg/config_generated.cfg
# For each shape with coarse mesh # For each shape with coarse mesh
for i in shape_with_coarse_mesh/*.[sS][hH][aA][pP][eE]; do for i in shape_with_coarse_mesh/*.[sS][hH][aA][pP][eE]; do
if ( test -f $i ) if ( test -f $i )
then then
# Destination file # Destination file
src=`echo $i | sed -e 's&shape_with_coarse_mesh/&&g'` src=`echo $i | sed -e 's&shape_with_coarse_mesh/&&g'`
dest=`echo $i | sed -e 's&shape_with_coarse_mesh&shape_with_coarse_mesh_builded&g'` dest=`echo $i | sed -e 's&shape_with_coarse_mesh&shape_with_coarse_mesh_builded&g'`
# Add the shape # Add the shape
echo ' "'$src'", "'$dest'",' >> cfg/config_generated.cfg echo ' "'$src'", "'$dest'",' >> cfg/config_generated.cfg
# Destination file # Destination file
dest=`echo $i | sed -e 's/lightmap/lightmap_16_bits/g'` dest=`echo $i | sed -e 's/lightmap/lightmap_16_bits/g'`
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
echo '};' >> cfg/config_generated.cfg echo '};' >> cfg/config_generated.cfg
# Add output bitmap list # Add output bitmap list
echo ' ' >> cfg/config_generated.cfg echo ' ' >> cfg/config_generated.cfg
echo 'output_textures = {' >> cfg/config_generated.cfg echo 'output_textures = {' >> cfg/config_generated.cfg
# For each shape with coarse mesh # For each shape with coarse mesh
for i in $coarse_mesh_texture_names ; do for i in $coarse_mesh_texture_names ; do
# Add the path # Add the path
echo ' "shape_with_coarse_mesh/'$i'.tga"', >> cfg/config_generated.cfg echo ' "shape_with_coarse_mesh/'$i'.tga"', >> cfg/config_generated.cfg
done done
# Close the config file # Close the config file
echo '};' >> cfg/config_generated.cfg echo '};' >> cfg/config_generated.cfg
# Execute the build # Execute the build
$build_coarse_mesh cfg/config_generated.cfg $build_coarse_mesh cfg/config_generated.cfg
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build shape : convert coarse texture to dds without mipmaps >> log.log echo --- Build shape : convert coarse texture to dds without mipmaps >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build shape : convert coarse texture to dds without mipmaps echo --- Build shape : convert coarse texture to dds without mipmaps
echo ------- echo -------
date >> log.log date >> log.log
date date
# Convert the coarse texture to dds # Convert the coarse texture to dds
for i in $coarse_mesh_texture_names ; do for i in $coarse_mesh_texture_names ; do
if ( test -f shape_with_coarse_mesh/$i.tga ) if ( test -f shape_with_coarse_mesh/$i.tga )
then then
$tga_2_dds shape_with_coarse_mesh/$i.tga -o shape_with_coarse_mesh_builded/$i.dds -a 5 2>> log.log $tga_2_dds shape_with_coarse_mesh/$i.tga -o shape_with_coarse_mesh_builded/$i.dds -a 5 2>> log.log
fi fi
done done
else else
echo --- No coarse meshes texture defined >> log.log echo --- No coarse meshes texture defined >> log.log
echo --- No coarse meshes texture defined echo --- No coarse meshes texture defined
fi fi

@ -1,140 +1,140 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# ********************************************* # *********************************************
# ********************************************* # *********************************************
# *** Export shape files (.shape) from Max # *** Export shape files (.shape) from Max
# ********************************************* # *********************************************
# ********************************************* # *********************************************
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "shape_export_timeout" | sed -e 's/shape_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "shape_export_timeout" | sed -e 's/shape_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the shape directories # Get the shape directories
shape_source_directories=`cat ../../cfg/directories.cfg | grep "shape_source_directory" | sed -e 's/shape_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` shape_source_directories=`cat ../../cfg/directories.cfg | grep "shape_source_directory" | sed -e 's/shape_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the quality option to choose the goor properties.cfg file # Get the quality option to choose the goor properties.cfg file
quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"` quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Get the options # Get the options
if ( test "$quality_flag" ) if ( test "$quality_flag" )
then then
# We are in BEST mode # We are in BEST mode
seoel=`cat ../../cfg/config.cfg | grep "shape_export_opt_export_lighting" | sed -e 's/shape_export_opt_export_lighting//' | sed -e 's/ //g' | sed -e 's/=//g'` seoel=`cat ../../cfg/config.cfg | grep "shape_export_opt_export_lighting" | sed -e 's/shape_export_opt_export_lighting//' | sed -e 's/ //g' | sed -e 's/=//g'`
seos=`cat ../../cfg/config.cfg | grep "shape_export_opt_shadow" | sed -e 's/shape_export_opt_shadow//' | sed -e 's/ //g' | sed -e 's/=//g'` seos=`cat ../../cfg/config.cfg | grep "shape_export_opt_shadow" | sed -e 's/shape_export_opt_shadow//' | sed -e 's/ //g' | sed -e 's/=//g'`
seoll=`cat ../../cfg/config.cfg | grep "shape_export_opt_lighting_limit" | sed -e 's/shape_export_opt_lighting_limit//' | sed -e 's/ //g' | sed -e 's/=//g'` seoll=`cat ../../cfg/config.cfg | grep "shape_export_opt_lighting_limit" | sed -e 's/shape_export_opt_lighting_limit//' | sed -e 's/ //g' | sed -e 's/=//g'`
seols=`cat ../../cfg/config.cfg | grep "shape_export_opt_lumel_size" | sed -e 's/shape_export_opt_lumel_size//' | sed -e 's/ //g' | sed -e 's/=//g'` seols=`cat ../../cfg/config.cfg | grep "shape_export_opt_lumel_size" | sed -e 's/shape_export_opt_lumel_size//' | sed -e 's/ //g' | sed -e 's/=//g'`
seoo=`cat ../../cfg/config.cfg | grep "shape_export_opt_oversampling" | sed -e 's/shape_export_opt_oversampling//' | sed -e 's/ //g' | sed -e 's/=//g'` seoo=`cat ../../cfg/config.cfg | grep "shape_export_opt_oversampling" | sed -e 's/shape_export_opt_oversampling//' | sed -e 's/ //g' | sed -e 's/=//g'`
else else
# We are in DRAFT mode # We are in DRAFT mode
seoel='false' seoel='false'
seos='false' seos='false'
seoll='0' seoll='0'
seols='0.25' seols='0.25'
seoo='1' seoo='1'
fi fi
seolog=`cat ../../cfg/config.cfg | grep "shape_export_opt_lightmap_log" | sed -e 's/shape_export_opt_lightmap_log//' | sed -e 's/ //g' | sed -e 's/=//g'` seolog=`cat ../../cfg/config.cfg | grep "shape_export_opt_lightmap_log" | sed -e 's/shape_export_opt_lightmap_log//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export shape >> log.log echo --- Export shape >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export shape echo --- Export shape
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $shape_source_directories ; do for i in $shape_source_directories ; do
# Copy the script # Copy the script
cat maxscript/shape_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/shape/log.log&g" | sed -e "s&shape_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/shape/tag&g" | sed -e "s&output_directory_without_coarse_mesh&$build_gamedata_directory/processes/shape/shape_not_optimized&g" | sed -e "s&output_directory_with_coarse_mesh&$build_gamedata_directory/processes/shape/shape_with_coarse_mesh&g" | sed -e "s&shape_export_opt_export_lighting&$seoel&g" | sed -e "s&shape_export_opt_shadow&$seos&g" | sed -e "s&shape_export_opt_lighting_limit&$seoll&g" | sed -e "s&shape_export_opt_lumel_size&$seols&g" | sed -e "s&shape_export_opt_oversampling&$seoo&g"| sed -e "s&shape_export_opt_lightmap_log&$seolog&g" | sed -e "s&shape_lightmap_path&$build_gamedata_directory/processes/shape/lightmap_not_optimized&g" | sed -e "s&output_directory_anim&$build_gamedata_directory/processes/shape/anim&g" > $max_directory/scripts/shape_export.ms cat maxscript/shape_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/shape/log.log&g" | sed -e "s&shape_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/shape/tag&g" | sed -e "s&output_directory_without_coarse_mesh&$build_gamedata_directory/processes/shape/shape_not_optimized&g" | sed -e "s&output_directory_with_coarse_mesh&$build_gamedata_directory/processes/shape/shape_with_coarse_mesh&g" | sed -e "s&shape_export_opt_export_lighting&$seoel&g" | sed -e "s&shape_export_opt_shadow&$seos&g" | sed -e "s&shape_export_opt_lighting_limit&$seoll&g" | sed -e "s&shape_export_opt_lumel_size&$seols&g" | sed -e "s&shape_export_opt_oversampling&$seoo&g"| sed -e "s&shape_export_opt_lightmap_log&$seolog&g" | sed -e "s&shape_lightmap_path&$build_gamedata_directory/processes/shape/lightmap_not_optimized&g" | sed -e "s&output_directory_anim&$build_gamedata_directory/processes/shape/anim&g" > $max_directory/scripts/shape_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript shape_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript shape_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript shape_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript shape_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript shape_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript shape_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# ********************************************* # *********************************************
# ********************************************* # *********************************************
# *** Export character lod shape files (.clod) from Max # *** Export character lod shape files (.clod) from Max
# ********************************************* # *********************************************
# ********************************************* # *********************************************
# Get the clod directories # Get the clod directories
clod_source_directories=`cat ../../cfg/directories.cfg | grep "clod_source_directory" | sed -e 's/clod_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` clod_source_directories=`cat ../../cfg/directories.cfg | grep "clod_source_directory" | sed -e 's/clod_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Export clod >> log.log echo --- Export clod >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export clod echo --- Export clod
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $clod_source_directories ; do for i in $clod_source_directories ; do
# Copy the script. TAKE IT FROM clodbank process. But write it here. # Copy the script. TAKE IT FROM clodbank process. But write it here.
cat ../clodbank/maxscript/clod_export.ms | sed -e "s&shape_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_clod&$build_gamedata_directory/processes/shape/clod&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/shape/tag&g" > $max_directory/scripts/clod_export.ms cat ../clodbank/maxscript/clod_export.ms | sed -e "s&shape_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_clod&$build_gamedata_directory/processes/shape/clod&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/shape/tag&g" > $max_directory/scripts/clod_export.ms
# Start max # Start max
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn
# Concat log.log files # Concat log.log files
echo Try 1 >> log.log echo Try 1 >> log.log
cat $max_directory/log.log >> log.log cat $max_directory/log.log >> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn
# Concat log.log files # Concat log.log files
echo Try 2 >> log.log echo Try 2 >> log.log
cat $max_directory/log.log >> log.log cat $max_directory/log.log >> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript clod_export.ms -q -mi -vn
# Concat log.log files # Concat log.log files
echo Try 3 >> log.log echo Try 3 >> log.log
cat $max_directory/log.log >> log.log cat $max_directory/log.log >> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,36 +1,36 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install shapes in the client data # Install shapes in the client data
# Get the shape install directory # Get the shape install directory
shape_install_directory=`cat ../../cfg/directories.cfg | grep "shape_install_directory" | sed -e 's/shape_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` shape_install_directory=`cat ../../cfg/directories.cfg | grep "shape_install_directory" | sed -e 's/shape_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the lightmaps install directory # Get the lightmaps install directory
lightmap_install_directory=`cat ../../cfg/directories.cfg | grep "lightmap_install_directory" | sed -e 's/lightmap_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` lightmap_install_directory=`cat ../../cfg/directories.cfg | grep "lightmap_install_directory" | sed -e 's/lightmap_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install Shape >> log.log echo --- Install Shape >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install Shape echo --- Install Shape
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R shape/. $client_directory/$shape_install_directory 2>> log.log cp -u -p -R shape/. $client_directory/$shape_install_directory 2>> log.log
cp -u -p -R shape_with_coarse_mesh_builded/. $client_directory/$shape_install_directory 2>> log.log cp -u -p -R shape_with_coarse_mesh_builded/. $client_directory/$shape_install_directory 2>> log.log
if test "$lightmap_install_directory"; then if test "$lightmap_install_directory"; then
mkdir $client_directory/$lightmap_install_directory 2>> log.log 2> /dev/null mkdir $client_directory/$lightmap_install_directory 2>> log.log 2> /dev/null
cp -u -p -R lightmap_16_bits/. $client_directory/$lightmap_install_directory 2>> log.log cp -u -p -R lightmap_16_bits/. $client_directory/$lightmap_install_directory 2>> log.log
fi fi
cp -u -p -R anim/. $client_directory/$shape_install_directory 2>> log.log cp -u -p -R anim/. $client_directory/$shape_install_directory 2>> log.log
ls anim | grep ".anim" >> $client_directory/auto_animations_list.txt ls anim | grep ".anim" >> $client_directory/auto_animations_list.txt

@ -1,80 +1,80 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export skeleton files (.skel) from Max # *** Export skeleton files (.skel) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "skel_export_timeout" | sed -e 's/skel_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "skel_export_timeout" | sed -e 's/skel_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the skel directories # Get the skel directories
skel_source_directories=`cat ../../cfg/directories.cfg | grep "skel_source_directory" | sed -e 's/skel_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` skel_source_directories=`cat ../../cfg/directories.cfg | grep "skel_source_directory" | sed -e 's/skel_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export skeleton from MAX>> log.log echo --- Export skeleton from MAX>> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export skeleton from MAX echo --- Export skeleton from MAX
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $skel_source_directories ; do for i in $skel_source_directories ; do
# Copy the script # Copy the script
cat maxscript/skel_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/skel/log.log&g" | sed -e "s&skel_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/skel/skel&g" > $max_directory/scripts/skel_export.ms cat maxscript/skel_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/skel/log.log&g" | sed -e "s&skel_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/skel/skel&g" > $max_directory/scripts/skel_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript skel_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript skel_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript skel_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript skel_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript skel_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript skel_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# *** Export skeleton files (.skel) directly from .skel version # *** Export skeleton files (.skel) directly from .skel version
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Copy skeleton from .skel>> log.log echo --- Copy skeleton from .skel>> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Copy skeleton from .skel echo --- Copy skeleton from .skel
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $skel_source_directories ; do for i in $skel_source_directories ; do
# copy # copy
cp -u -p $database_directory/$i/*.[sS][kK][eE][lL] skel 2>> log.log cp -u -p $database_directory/$i/*.[sS][kK][eE][lL] skel 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install skel in the client data # Install skel in the client data
# Get the skel install directory # Get the skel install directory
skel_install_directory=`cat ../../cfg/directories.cfg | grep "skel_install_directory" | sed -e 's/skel_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` skel_install_directory=`cat ../../cfg/directories.cfg | grep "skel_install_directory" | sed -e 's/skel_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install skeleton >> log.log echo --- Install skeleton >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install skeleton echo --- Install skeleton
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R skel/. $client_directory/$skel_install_directory 2>> log.log cp -u -p -R skel/. $client_directory/$skel_install_directory 2>> log.log

@ -1,72 +1,72 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export bank file (.bank) from Max # *** Export bank file (.bank) from Max
# Some exe # Some exe
build_smallbank='build_smallbank.exe' build_smallbank='build_smallbank.exe'
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the swt directories # Get the swt directories
bank_source_directory=`cat ../../cfg/directories.cfg | grep "bank_source_directory" | sed -e 's/bank_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` bank_source_directory=`cat ../../cfg/directories.cfg | grep "bank_source_directory" | sed -e 's/bank_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "smallbank_build_timeout" | sed -e 's/smallbank_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "smallbank_build_timeout" | sed -e 's/smallbank_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the tiles root directories # Get the tiles root directories
tile_root_source_directory=`cat ../../cfg/directories.cfg | grep "tile_root_source_directory" | sed -e 's/tile_root_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` tile_root_source_directory=`cat ../../cfg/directories.cfg | grep "tile_root_source_directory" | sed -e 's/tile_root_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export bank >> log.log echo --- Export bank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export bank echo --- Export bank
echo ------- echo -------
date >> log.log date >> log.log
date date
# Copy the bank # Copy the bank
cp -u -p $database_directory/$bank_source_directory/*.[bB][aA][nN][kK] bank 2>> log.log cp -u -p $database_directory/$bank_source_directory/*.[bB][aA][nN][kK] bank 2>> log.log
# Build the small bank # Build the small bank
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build bank >> log.log echo --- Build bank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build bank echo --- Build bank
echo ------- echo -------
date >> log.log date >> log.log
date date
# list all the bank # list all the bank
bank_list=`ls -1 bank/*.[bB][aA][nN][kK]` bank_list=`ls -1 bank/*.[bB][aA][nN][kK]`
# For each bank # For each bank
for i in $bank_list ; do for i in $bank_list ; do
# Destination the name # Destination the name
dest=`echo $i | sed -e 's&bank&smallbank&g'` dest=`echo $i | sed -e 's&bank&smallbank&g'`
# Make the dependencies # Make the dependencies
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
$exec_timeout $timeout $build_smallbank $i $dest $database_directory/$tile_root_source_directory/ $exec_timeout $timeout $build_smallbank $i $dest $database_directory/$tile_root_source_directory/
if ( test -e $dest ) if ( test -e $dest )
then then
echo OK $dest >> log.log echo OK $dest >> log.log
else else
echo ERROR building $dest >> log.log echo ERROR building $dest >> log.log
fi fi
else else
echo SKIPPED $dest >> log.log echo SKIPPED $dest >> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the bank in the client data # Install the bank in the client data
# Get the bank install directory # Get the bank install directory
bank_install_directory=`cat ../../cfg/directories.cfg | grep "bank_install_directory" | sed -e 's/bank_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` bank_install_directory=`cat ../../cfg/directories.cfg | grep "bank_install_directory" | sed -e 's/bank_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install smallbank >> log.log echo --- Install smallbank >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install smallbank echo --- Install smallbank
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R smallbank/. $client_directory/$bank_install_directory 2>> log.log cp -u -p -R smallbank/. $client_directory/$bank_install_directory 2>> log.log

@ -1,57 +1,57 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export skeleton weight files (.swt) from Max # *** Export skeleton weight files (.swt) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "swt_export_timeout" | sed -e 's/swt_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "swt_export_timeout" | sed -e 's/swt_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the swt directories # Get the swt directories
swt_source_directories=`cat ../../cfg/directories.cfg | grep "swt_source_directory" | sed -e 's/swt_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` swt_source_directories=`cat ../../cfg/directories.cfg | grep "swt_source_directory" | sed -e 's/swt_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export skeleton weight >> log.log echo --- Export skeleton weight >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export skeleton weight echo --- Export skeleton weight
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $swt_source_directories ; do for i in $swt_source_directories ; do
# Copy the script # Copy the script
cat maxscript/swt_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/swt/log.log&g" | sed -e "s&swt_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/swt/swt&g" > $max_directory/scripts/swt_export.ms cat maxscript/swt_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/swt/log.log&g" | sed -e "s&swt_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/swt/swt&g" > $max_directory/scripts/swt_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript swt_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript swt_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript swt_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript swt_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript swt_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript swt_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install swt in the client data # Install swt in the client data
# Get the swt install directory # Get the swt install directory
swt_install_directory=`cat ../../cfg/directories.cfg | grep "swt_install_directory" | sed -e 's/swt_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` swt_install_directory=`cat ../../cfg/directories.cfg | grep "swt_install_directory" | sed -e 's/swt_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install skeleton weight >> log.log echo --- Install skeleton weight >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install skeleton weight echo --- Install skeleton weight
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R swt/. $client_directory/$swt_install_directory 2>> log.log cp -u -p -R swt/. $client_directory/$swt_install_directory 2>> log.log

@ -1,43 +1,43 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
tga_2_dds='tga2dds.exe' tga_2_dds='tga2dds.exe'
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "maps_build_timeout" | sed -e 's/maps_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "maps_build_timeout" | sed -e 's/maps_build_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Build the tile textures # Build the tile textures
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Build tiles >> log.log echo --- Build tiles >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build tiles echo --- Build tiles
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each texture # For each texture
for i in maps_tga/*.[tT][gG][aA] ; do for i in maps_tga/*.[tT][gG][aA] ; do
if ( test -e $i ) if ( test -e $i )
then then
dest=`echo $i | sed -e 's/maps_tga/maps_final/g' | sed -e 's/.tga/.dds/g'` dest=`echo $i | sed -e 's/maps_tga/maps_final/g' | sed -e 's/.tga/.dds/g'`
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
$exec_timeout $timeout $tga_2_dds $i -o $dest -a 5 -m $exec_timeout $timeout $tga_2_dds $i -o $dest -a 5 -m
if ( test -e $dest ) if ( test -e $dest )
then then
echo OK $dest >> log.log echo OK $dest >> log.log
else else
echo ERROR building $dest >> log.log echo ERROR building $dest >> log.log
fi fi
else else
echo SKIPPED $dest >> log.log echo SKIPPED $dest >> log.log
fi fi
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,33 +1,33 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Export the tile textures # Export the tile textures
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the tile directories # Get the tile directories
tile_source_directories=`cat ../../cfg/directories.cfg | grep "tile_source_directories" | sed -e 's/tile_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'` tile_source_directories=`cat ../../cfg/directories.cfg | grep "tile_source_directories" | sed -e 's/tile_source_directories//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export tiles >> log.log echo --- Export tiles >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export tiles echo --- Export tiles
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $tile_source_directories ; do for i in $tile_source_directories ; do
list_textures=`find $database_directory/$i -type f -name '*.[tT][gG][aA]'` list_textures=`find $database_directory/$i -type f -name '*.[tT][gG][aA]'`
# For each textures # For each textures
for j in $list_textures ; do for j in $list_textures ; do
cp -u -p $j maps_tga/ 2>> log.log cp -u -p $j maps_tga/ 2>> log.log
done done
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install tiles in the client data # Install tiles in the client data
# Get the tile install directory # Get the tile install directory
tile_install_directory=`cat ../../cfg/directories.cfg | grep "tile_install_directory" | sed -e 's/tile_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` tile_install_directory=`cat ../../cfg/directories.cfg | grep "tile_install_directory" | sed -e 's/tile_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install Tiles >> log.log echo --- Install Tiles >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install Tiles echo --- Install Tiles
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R maps_final/. $client_directory/$tile_install_directory 2>> log.log cp -u -p -R maps_final/. $client_directory/$tile_install_directory 2>> log.log

@ -1,52 +1,52 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export veget files (.veget) from Max # *** Export veget files (.veget) from Max
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the veget directories # Get the veget directories
veget_source_directories=`cat ../../cfg/directories.cfg | grep "veget_source_directory" | sed -e 's/veget_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` veget_source_directories=`cat ../../cfg/directories.cfg | grep "veget_source_directory" | sed -e 's/veget_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export veget >> log.log echo --- Export veget >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export veget echo --- Export veget
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each directoy # For each directoy
for i in $veget_source_directories ; do for i in $veget_source_directories ; do
# Copy the script # Copy the script
cat maxscript/veget_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/veget/log.log&g" | sed -e "s&veget_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_veget&$build_gamedata_directory/processes/veget/veget&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/veget/tag&g" > $max_directory/scripts/veget_export.ms cat maxscript/veget_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/veget/log.log&g" | sed -e "s&veget_source_directory&$database_directory/$i&g" | sed -e "s&output_directory_veget&$build_gamedata_directory/processes/veget/veget&g" | sed -e "s&output_directory_tag&$build_gamedata_directory/processes/veget/tag&g" > $max_directory/scripts/veget_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$max_directory/3dsmax.exe -U MAXScript veget_export.ms -q -mi -vn $max_directory/3dsmax.exe -U MAXScript veget_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 2 >> log.log echo Try 2 >> log.log
$max_directory/3dsmax.exe -U MAXScript veget_export.ms -q -mi -vn $max_directory/3dsmax.exe -U MAXScript veget_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
echo Try 3 >> log.log echo Try 3 >> log.log
$max_directory/3dsmax.exe -U MAXScript veget_export.ms -q -mi -vn $max_directory/3dsmax.exe -U MAXScript veget_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install vegets in the client data # Install vegets in the client data
# Get the veget install directory # Get the veget install directory
veget_install_directory=`cat ../../cfg/directories.cfg | grep "veget_install_directory" | sed -e 's/veget_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` veget_install_directory=`cat ../../cfg/directories.cfg | grep "veget_install_directory" | sed -e 's/veget_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install veget >> log.log echo --- Install veget >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install veget echo --- Install veget
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R veget/. $client_directory/$veget_install_directory 2>> log.log cp -u -p -R veget/. $client_directory/$veget_install_directory 2>> log.log

@ -1,29 +1,29 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export vegetset file (.vegetset) # *** Export vegetset file (.vegetset)
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the vegetset directories # Get the vegetset directories
vegetset_source_directories=`cat ../../cfg/directories.cfg | grep "vegetset_source_directory" | sed -e 's/vegetset_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` vegetset_source_directories=`cat ../../cfg/directories.cfg | grep "vegetset_source_directory" | sed -e 's/vegetset_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export vegetset >> log.log echo --- Export vegetset >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export vegetset echo --- Export vegetset
echo ------- echo -------
date >> log.log date >> log.log
date date
# For each vegetset directory # For each vegetset directory
for i in $vegetset_source_directories ; do for i in $vegetset_source_directories ; do
# Copy # Copy
cp -u -p $database_directory/$i/*.[vV][eE][gG][eE][tT][sS][eE][tT] vegetset 2>> log.log cp -u -p $database_directory/$i/*.[vV][eE][gG][eE][tT][sS][eE][tT] vegetset 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,22 +1,22 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the vegetable set in the client data # Install the vegetable set in the client data
# Get the vegetset install directory # Get the vegetset install directory
vegetset_install_directory=`cat ../../cfg/directories.cfg | grep "vegetset_install_directory" | sed -e 's/vegetset_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` vegetset_install_directory=`cat ../../cfg/directories.cfg | grep "vegetset_install_directory" | sed -e 's/vegetset_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install vegetset >> log.log echo --- Install vegetset >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install vegetset echo --- Install vegetset
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R vegetset/. $client_directory/$vegetset_install_directory 2>> log.log cp -u -p -R vegetset/. $client_directory/$vegetset_install_directory 2>> log.log

@ -1,149 +1,149 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Build zone # Build zone
zone_dependencies='zone_dependencies.exe' zone_dependencies='zone_dependencies.exe'
zone_welder='zone_welder.exe' zone_welder='zone_welder.exe'
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
depend_timeout=`cat ../../cfg/config.cfg | grep "zone_build_depend_timeout" | sed -e 's/zone_build_depend_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` depend_timeout=`cat ../../cfg/config.cfg | grep "zone_build_depend_timeout" | sed -e 's/zone_build_depend_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
weld_timeout=`cat ../../cfg/config.cfg | grep "zone_build_weld_timeout" | sed -e 's/zone_build_weld_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` weld_timeout=`cat ../../cfg/config.cfg | grep "zone_build_weld_timeout" | sed -e 's/zone_build_weld_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the quality option to choose the goor properties.cfg file # Get the quality option to choose the goor properties.cfg file
quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"` quality_flag=`cat ../../cfg/site.cfg | grep "build_quality" | grep "1"`
# **** Build dependencies # **** Build dependencies
if ( test "$quality_flag" ) if ( test "$quality_flag" )
then then
# We are in BEST mode # We are in BEST mode
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build zone : dependencies >> log.log echo --- Build zone : dependencies >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build zone : dependencies echo --- Build zone : dependencies
echo ------- echo -------
date >> log.log date >> log.log
date date
cp ../../cfg/properties.cfg zone_depencies_properties.cfg cp ../../cfg/properties.cfg zone_depencies_properties.cfg
#append the level design directory at the end of the config file #append the level design directory at the end of the config file
ld_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
ld_world_dir=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_world_dir=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
ld_dfn_dir=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_dfn_dir=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
continent_file_name=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//g' | sed -e 's/ //g' | sed -e 's/=//g'` continent_file_name=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//g' | sed -e 's/ //g' | sed -e 's/=//g'`
echo "level_design_directory = \"$ld_dir\";" >> zone_depencies_properties.cfg echo "level_design_directory = \"$ld_dir\";" >> zone_depencies_properties.cfg
echo "level_design_world_directory = \"$ld_world_dir\";" >> zone_depencies_properties.cfg echo "level_design_world_directory = \"$ld_world_dir\";" >> zone_depencies_properties.cfg
echo "level_design_dfn_directory = \"$ld_dfn_dir\";" >> zone_depencies_properties.cfg echo "level_design_dfn_directory = \"$ld_dfn_dir\";" >> zone_depencies_properties.cfg
echo "continent_name = \"$continent_file_name\";" >> zone_depencies_properties.cfg echo "continent_name = \"$continent_file_name\";" >> zone_depencies_properties.cfg
# list all the dependencies regions # list all the dependencies regions
zone_regions=`cat ../../cfg/config.cfg | grep "zone_region" | sed -e 's/zone_region//' | sed -e 's/ //g' | sed -e 's/=//g'` zone_regions=`cat ../../cfg/config.cfg | grep "zone_region" | sed -e 's/zone_region//' | sed -e 's/ //g' | sed -e 's/=//g'`
# For each dependencies region # For each dependencies region
for i in $zone_regions ; do for i in $zone_regions ; do
# Extract the name # Extract the name
arg=`echo zone_exported/$zone_regions | sed -e 's&,&.zone zone_exported/&g'` arg=`echo zone_exported/$zone_regions | sed -e 's&,&.zone zone_exported/&g'`
# Make the dependencies # Make the dependencies
$exec_timeout $depend_timeout $zone_dependencies zone_depencies_properties.cfg $arg.zone zone_depend/doomy.depend $exec_timeout $depend_timeout $zone_dependencies zone_depencies_properties.cfg $arg.zone zone_depend/doomy.depend
# Idle # Idle
../../idle.bat ../../idle.bat
done done
fi fi
# **** Weld # **** Weld
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build zone : weld >> log.log echo --- Build zone : weld >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build zone : weld echo --- Build zone : weld
echo ------- echo -------
date >> log.log date >> log.log
date date
# List the zones to weld # List the zones to weld
list_zone=`ls -1 zone_exported/*.[zZ][oO][nN][eE]` list_zone=`ls -1 zone_exported/*.[zZ][oO][nN][eE]`
# Build a zones list to weld # Build a zones list to weld
echo -- Build a list of file to weld echo -- Build a list of file to weld
rm zone_to_weld.txt 2> /dev/null rm zone_to_weld.txt 2> /dev/null
for i in $list_zone ; do for i in $list_zone ; do
dest=`echo $i | sed -e 's/zone_exported/zone_welded/g' | sed -e 's/.zone/.zonew/g'` dest=`echo $i | sed -e 's/zone_exported/zone_welded/g' | sed -e 's/.zone/.zonew/g'`
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
echo $i >> zone_to_weld.txt echo $i >> zone_to_weld.txt
rm $dest rm $dest
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Weld the zone # Weld the zone
if (test -f zone_to_weld.txt) if (test -f zone_to_weld.txt)
then then
list_zone=`cat zone_to_weld.txt` list_zone=`cat zone_to_weld.txt`
for i in $list_zone ; do for i in $list_zone ; do
echo -- Weld $i echo -- Weld $i
echo -- Weld $i >> log.log echo -- Weld $i >> log.log
$exec_timeout $weld_timeout $zone_welder $i $dest $exec_timeout $weld_timeout $zone_welder $i $dest
echo echo
# Idle # Idle
../../idle.bat ../../idle.bat
done done
fi fi
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build zone : weld zones without heightmap >> log.log echo --- Build zone : weld zones without heightmap >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build zone : weld zones without heightmap echo --- Build zone : weld zones without heightmap
echo ------- echo -------
date >> log.log date >> log.log
date date
# List the zones to weld # List the zones to weld
list_zone=`ls -1 zone_exported/*.[zZ][oO][nN][eE][nN][hH]` list_zone=`ls -1 zone_exported/*.[zZ][oO][nN][eE][nN][hH]`
# Build a zones list to weld # Build a zones list to weld
echo -- Build a list of file to weld echo -- Build a list of file to weld
rm zone_to_weld.txt 2> /dev/null rm zone_to_weld.txt 2> /dev/null
for i in $list_zone ; do for i in $list_zone ; do
dest=`echo $i | sed -e 's/zone_exported/zone_welded/g' | sed -e 's/.zonenh/.zonenhw/g'` dest=`echo $i | sed -e 's/zone_exported/zone_welded/g' | sed -e 's/.zonenh/.zonenhw/g'`
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
echo $i >> zone_to_weld.txt echo $i >> zone_to_weld.txt
rm $dest rm $dest
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# Weld the zone # Weld the zone
if (test -f zone_to_weld.txt) if (test -f zone_to_weld.txt)
then then
list_zone=`cat zone_to_weld.txt` list_zone=`cat zone_to_weld.txt`
for i in $list_zone ; do for i in $list_zone ; do
echo -- Weld $i echo -- Weld $i
echo -- Weld $i >> log.log echo -- Weld $i >> log.log
$exec_timeout $weld_timeout $zone_welder $i $dest $exec_timeout $weld_timeout $zone_welder $i $dest
echo echo
# Idle # Idle
../../idle.bat ../../idle.bat
done done
fi fi
# Build a zones list to weld # Build a zones list to weld
rm zone_to_weld.txt 2> /dev/null rm zone_to_weld.txt 2> /dev/null

@ -1,109 +1,109 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export zone files (.zone) from Max # *** Export zone files (.zone) from Max
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
timeout=`cat ../../cfg/config.cfg | grep "zone_export_timeout" | sed -e 's/zone_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` timeout=`cat ../../cfg/config.cfg | grep "zone_export_timeout" | sed -e 's/zone_export_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the build gamedata directory # Get the build gamedata directory
build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` build_gamedata_directory=`cat ../../cfg/site.cfg | grep "build_gamedata_directory" | sed -e 's/build_gamedata_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the zone directories # Get the zone directories
zone_source_directories=`cat ../../cfg/directories.cfg | grep "zone_source_directory" | sed -e 's/zone_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` zone_source_directories=`cat ../../cfg/directories.cfg | grep "zone_source_directory" | sed -e 's/zone_source_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the ligo value # Get the ligo value
ligo_flag=`cat ../../cfg/config.cfg | grep "process_to_complete" | grep "ligo"` ligo_flag=`cat ../../cfg/config.cfg | grep "process_to_complete" | grep "ligo"`
# Maxdir # Maxdir
max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'` max_directory=`echo $MAX_DIR | sed -e 's&\\\&/&g'`
if ( test "$ligo_flag" ) if ( test "$ligo_flag" )
then then
echo [Ligo] ON echo [Ligo] ON
echo [Ligo] ON >> log.log echo [Ligo] ON >> log.log
else else
echo [Ligo] OFF echo [Ligo] OFF
echo [Ligo] OFF >> log.log echo [Ligo] OFF >> log.log
fi fi
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export zone >> log.log echo --- Export zone >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export zone echo --- Export zone
echo ------- echo -------
date >> log.log date >> log.log
date date
# Try to export from Max zone if any # Try to export from Max zone if any
for i in $zone_source_directories ; do for i in $zone_source_directories ; do
# Copy the script # Copy the script
cat maxscript/zone_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/zone/log.log&g" | sed -e "s&zone_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/zone/zone_exported&g" > $max_directory/scripts/zone_export.ms cat maxscript/zone_export.ms | sed -e "s&output_logfile&$build_gamedata_directory/processes/zone/log.log&g" | sed -e "s&zone_source_directory&$database_directory/$i&g" | sed -e "s&output_directory&$build_gamedata_directory/processes/zone/zone_exported&g" > $max_directory/scripts/zone_export.ms
# Start max # Start max
echo Try 1 >> log.log echo Try 1 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript zone_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript zone_export.ms -q -mi -vn
echo Try 2 >> log.log echo Try 2 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript zone_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript zone_export.ms -q -mi -vn
echo Try 3 >> log.log echo Try 3 >> log.log
$exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript zone_export.ms -q -mi -vn $exec_timeout $timeout $max_directory/3dsmax.exe -U MAXScript zone_export.ms -q -mi -vn
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# **************************** # ****************************
# Try to copy ligo zone if any # Try to copy ligo zone if any
# **************************** # ****************************
dir_current=`pwd` dir_current=`pwd`
cd ../ligo/output cd ../ligo/output
list_zone=`ls -1 *.[zZ][oO][nN][eE]` list_zone=`ls -1 *.[zZ][oO][nN][eE]`
for filename in $list_zone ; do for filename in $list_zone ; do
echo "Checking $filename for update" echo "Checking $filename for update"
if test -e ../../zone/zone_exported/$filename ; then if test -e ../../zone/zone_exported/$filename ; then
must_update=`diff --binary -q $filename ../../zone/zone_exported/$filename` ; must_update=`diff --binary -q $filename ../../zone/zone_exported/$filename` ;
else else
must_update=YES ; must_update=YES ;
fi fi
if test -n "$must_update" ; then if test -n "$must_update" ; then
echo " Updating" echo " Updating"
cp -u -p $filename ../../zone/zone_exported/$filename ; cp -u -p $filename ../../zone/zone_exported/$filename ;
fi fi
# Idle # Idle
../../../idle.bat ../../../idle.bat
done done
cd $dir_current cd $dir_current
# delete files only present in the zone_exported directory # delete files only present in the zone_exported directory
if ( test "$ligo_flag" ) if ( test "$ligo_flag" )
then then
cd ./zone_exported cd ./zone_exported
list_zone=`ls -1 *.[zZ][oO][nN][eE]` list_zone=`ls -1 *.[zZ][oO][nN][eE]`
for filename in $list_zone ; do for filename in $list_zone ; do
if test -e ../../ligo/output/$filename ; then if test -e ../../ligo/output/$filename ; then
must_update=NO ; must_update=NO ;
else else
echo "Removing $filename" echo "Removing $filename"
rm $filename ; rm $filename ;
fi fi
# Idle # Idle
../../../idle.bat ../../../idle.bat
done done
cd .. cd ..
fi fi

@ -1,119 +1,119 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Build zone # Build zone
zone_lighter='zone_lighter.exe' zone_lighter='zone_lighter.exe'
zone_ig_lighter='zone_ig_lighter.exe' zone_ig_lighter='zone_ig_lighter.exe'
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_light_timeout" | sed -e 's/zone_build_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_light_timeout" | sed -e 's/zone_build_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
ig_light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_ig_light_timeout" | sed -e 's/zone_build_ig_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` ig_light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_ig_light_timeout" | sed -e 's/zone_build_ig_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# **** Light # **** Light
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Zone lighting >> log.log echo --- Zone lighting >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Zone lighting echo --- Zone lighting
echo ------- echo -------
date >> log.log date >> log.log
date date
#append the level design directory at the end of the config file #append the level design directory at the end of the config file
ld_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
ld_world_dir=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_world_dir=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
ld_dfn_dir=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_dfn_dir=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
continent_file_name=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//g' | sed -e 's/ //g' | sed -e 's/=//g'` continent_file_name=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//g' | sed -e 's/ //g' | sed -e 's/=//g'`
cp ../../cfg/properties.cfg zone_lighter_properties.cfg cp ../../cfg/properties.cfg zone_lighter_properties.cfg
echo "level_design_directory = \"$ld_dir\";" >> zone_lighter_properties.cfg echo "level_design_directory = \"$ld_dir\";" >> zone_lighter_properties.cfg
echo "level_design_world_directory = \"$ld_world_dir\";" >> zone_lighter_properties.cfg echo "level_design_world_directory = \"$ld_world_dir\";" >> zone_lighter_properties.cfg
echo "level_design_dfn_directory = \"$ld_dfn_dir\";" >> zone_lighter_properties.cfg echo "level_design_dfn_directory = \"$ld_dfn_dir\";" >> zone_lighter_properties.cfg
echo "continent_name = \"$continent_file_name\";" >> zone_lighter_properties.cfg echo "continent_name = \"$continent_file_name\";" >> zone_lighter_properties.cfg
# List the zones to light # List the zones to light
list_zone_welded=`ls -1 ../zone/zone_welded/*.[zZ][oO][nN][eE][wW]` list_zone_welded=`ls -1 ../zone/zone_welded/*.[zZ][oO][nN][eE][wW]`
# Light zones # Light zones
for i in $list_zone_welded ; do for i in $list_zone_welded ; do
dest=`echo $i | sed -e 's&../zone/zone_welded&zone_lighted&g' | sed -e 's/.zonew/.zonel/g'` dest=`echo $i | sed -e 's&../zone/zone_welded&zone_lighted&g' | sed -e 's/.zonew/.zonel/g'`
depend=`echo $i | sed -e 's&../zone/zone_welded&../zone/zone_depend&g' | sed -e 's/.zonew/.depend/g'` depend=`echo $i | sed -e 's&../zone/zone_welded&../zone/zone_depend&g' | sed -e 's/.zonew/.depend/g'`
if ( ! test -e $dest ) || ( test $i -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest )
then then
echo LIGHT $i echo LIGHT $i
echo LIGHT $i >> log.log echo LIGHT $i >> log.log
$exec_timeout $light_timeout $zone_lighter $i $dest zone_lighter_properties.cfg $depend $exec_timeout $light_timeout $zone_lighter $i $dest zone_lighter_properties.cfg $depend
echo echo
echo echo
else else
echo SKIP $dest echo SKIP $dest
echo SKIP $dest >> log.log echo SKIP $dest >> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# List the zones lighted # List the zones lighted
list_zone_lighted_remove=`ls -1 zone_lighted/*.[zZ][oO][nN][eE][lL]` list_zone_lighted_remove=`ls -1 zone_lighted/*.[zZ][oO][nN][eE][lL]`
# Remove old lighted zones # Remove old lighted zones
for i in $list_zone_lighted_remove ; do for i in $list_zone_lighted_remove ; do
source=`echo $i | sed -e 's&zone_lighted&../zone/zone_welded&g' | sed -e 's/.zonel/.zonew/g'` source=`echo $i | sed -e 's&zone_lighted&../zone/zone_welded&g' | sed -e 's/.zonel/.zonew/g'`
if ( ! test -e $source ) if ( ! test -e $source )
then then
echo REMOVE $i echo REMOVE $i
echo REMOVE $i >> log.log echo REMOVE $i >> log.log
rm $i rm $i
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done
# **** IgLight # **** IgLight
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Build zone : IgLight >> log.log echo --- Build zone : IgLight >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Build zone : IgLight echo --- Build zone : IgLight
echo ------- echo -------
date >> log.log date >> log.log
date date
# List the zones lighted # List the zones lighted
list_zone_lighted=`ls -1 zone_lighted/*.[zZ][oO][nN][eE][lL]` list_zone_lighted=`ls -1 zone_lighted/*.[zZ][oO][nN][eE][lL]`
# Light zones # Light zones
for i in $list_zone_lighted ; do for i in $list_zone_lighted ; do
dest=`echo $i | sed -e 's/zone_lighted/ig_land_lighted/g' | sed -e 's/.zonel/.ig/g'` dest=`echo $i | sed -e 's/zone_lighted/ig_land_lighted/g' | sed -e 's/.zonel/.ig/g'`
depend=`echo $i | sed -e 's&zone_lighted&../zone/zone_depend&g' | sed -e 's/.zonel/.depend/g'` depend=`echo $i | sed -e 's&zone_lighted&../zone/zone_depend&g' | sed -e 's/.zonel/.depend/g'`
igsrc=`echo $i | sed -e 's&zone_lighted&../ig/ig_land&g' | sed -e 's/.zonel/.ig/g'` igsrc=`echo $i | sed -e 's&zone_lighted&../ig/ig_land&g' | sed -e 's/.zonel/.ig/g'`
if ( test -f $igsrc ) if ( test -f $igsrc )
then then
if ( ! test -e $dest ) || ( test $i -nt $dest ) || ( test $igsrc -nt $dest ) if ( ! test -e $dest ) || ( test $i -nt $dest ) || ( test $igsrc -nt $dest )
then then
echo -- IgLight $i echo -- IgLight $i
echo -- IgLight $i >> log.log echo -- IgLight $i >> log.log
$exec_timeout $ig_light_timeout $zone_ig_lighter $i $dest ../../cfg/properties.cfg $depend $exec_timeout $ig_light_timeout $zone_ig_lighter $i $dest ../../cfg/properties.cfg $depend
echo echo
echo echo
fi fi
else else
if ( test -f $dest ) if ( test -f $dest )
then then
echo "-- Remove" $dest echo "-- Remove" $dest
rm $dest rm $dest
fi fi
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,28 +1,28 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# *** Export zone files (.zone) from Max # *** Export zone files (.zone) from Max
# Get the database directory # Get the database directory
database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat ../../cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the water maps directories # Get the water maps directories
water_map_directories=`cat ../../cfg/directories.cfg | grep "water_map_directory" | sed -e 's/water_map_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` water_map_directories=`cat ../../cfg/directories.cfg | grep "water_map_directory" | sed -e 's/water_map_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Export water shape >> log.log echo --- Export water shape >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Export water shape echo --- Export water shape
echo ------- echo -------
date >> log.log date >> log.log
date date
#copy each water map before lightmapping #copy each water map before lightmapping
for i in $water_map_directories ; do for i in $water_map_directories ; do
cp -u -p $database_directory/$i/*.[tT][gG][aA] water_shapes_lighted 2>> log.log cp -u -p $database_directory/$i/*.[tT][gG][aA] water_shapes_lighted 2>> log.log
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,44 +1,44 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the zonels in the client data # Install the zonels in the client data
# Get the zone install directory # Get the zone install directory
zone_install_directory=`cat ../../cfg/directories.cfg | grep "zone_install_directory" | sed -e 's/zone_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` zone_install_directory=`cat ../../cfg/directories.cfg | grep "zone_install_directory" | sed -e 's/zone_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client directory # Get the client directory
client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat ../../cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install zone >> log.log echo --- Install zone >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install zone echo --- Install zone
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R zone_lighted/. $client_directory/$zone_install_directory 2>> log.log cp -u -p -R zone_lighted/. $client_directory/$zone_install_directory 2>> log.log
# copy the water maps once they have been lighted # copy the water maps once they have been lighted
cp -u -p -R water_shapes_lighted/. $client_directory/$water_maps_directories cp -u -p -R water_shapes_lighted/. $client_directory/$water_maps_directories
# Install zone ig lighted in the client data # Install zone ig lighted in the client data
# Get the ig install directory # Get the ig install directory
ig_install_directory=`cat ../../cfg/directories.cfg | grep "ig_install_directory" | sed -e 's/ig_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` ig_install_directory=`cat ../../cfg/directories.cfg | grep "ig_install_directory" | sed -e 's/ig_install_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo ------- > log.log echo ------- > log.log
echo --- Install Zone Ig >> log.log echo --- Install Zone Ig >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Install Zone Ig echo --- Install Zone Ig
echo ------- echo -------
date >> log.log date >> log.log
date date
cp -u -p -R ig_land_lighted/. $client_directory/$ig_install_directory 2>> log.log cp -u -p -R ig_land_lighted/. $client_directory/$ig_install_directory 2>> log.log

@ -1,63 +1,63 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Build zone # Build zone
zone_lighter='zone_lighter.exe' zone_lighter='zone_lighter.exe'
zone_ig_lighter='zone_ig_lighter.exe' zone_ig_lighter='zone_ig_lighter.exe'
exec_timeout='exec_timeout.exe' exec_timeout='exec_timeout.exe'
# Get the timeout # Get the timeout
light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_light_timeout" | sed -e 's/zone_build_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_light_timeout" | sed -e 's/zone_build_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
ig_light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_ig_light_timeout" | sed -e 's/zone_build_ig_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'` ig_light_timeout=`cat ../../cfg/config.cfg | grep "zone_build_ig_light_timeout" | sed -e 's/zone_build_ig_light_timeout//' | sed -e 's/ //g' | sed -e 's/=//g'`
# **** Light # **** Light
# Log error # Log error
echo ------- >> log.log echo ------- >> log.log
echo --- Zone lighting >> log.log echo --- Zone lighting >> log.log
echo ------- >> log.log echo ------- >> log.log
echo ------- echo -------
echo --- Zone lighting echo --- Zone lighting
echo ------- echo -------
date >> log.log date >> log.log
date date
#append the level design directory at the end of the config file #append the level design directory at the end of the config file
ld_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_dir=`cat ../../cfg/site.cfg | grep "level_design_directory" | sed -e 's/level_design_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
ld_world_dir=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_world_dir=`cat ../../cfg/site.cfg | grep "level_design_world_directory" | sed -e 's/level_design_world_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
ld_dfn_dir=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` ld_dfn_dir=`cat ../../cfg/site.cfg | grep "level_design_dfn_directory" | sed -e 's/level_design_dfn_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
continent_file_name=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//g' | sed -e 's/ //g' | sed -e 's/=//g'` continent_file_name=`cat ../../cfg/config.cfg | grep "continent_file" | sed -e 's/continent_file//g' | sed -e 's/ //g' | sed -e 's/=//g'`
cp ../../cfg/properties.cfg zone_lighter_properties.cfg cp ../../cfg/properties.cfg zone_lighter_properties.cfg
echo "level_design_directory = \"$ld_dir\";" >> zone_lighter_properties.cfg echo "level_design_directory = \"$ld_dir\";" >> zone_lighter_properties.cfg
echo "level_design_world_directory = \"$ld_world_dir\";" >> zone_lighter_properties.cfg echo "level_design_world_directory = \"$ld_world_dir\";" >> zone_lighter_properties.cfg
echo "level_design_dfn_directory = \"$ld_dfn_dir\";" >> zone_lighter_properties.cfg echo "level_design_dfn_directory = \"$ld_dfn_dir\";" >> zone_lighter_properties.cfg
echo "continent_name = \"$continent_file_name\";" >> zone_lighter_properties.cfg echo "continent_name = \"$continent_file_name\";" >> zone_lighter_properties.cfg
# List the zones to light # List the zones to light
list_zone_welded=`ls -1 ../zone/zone_welded/*.[zZ][oO][nN][eE][wW]` list_zone_welded=`ls -1 ../zone/zone_welded/*.[zZ][oO][nN][eE][wW]`
# create a bkup directory # create a bkup directory
mkdir bkup_tile_water mkdir bkup_tile_water
# Light zones # Light zones
for i in $list_zone_welded ; do for i in $list_zone_welded ; do
dest=`echo $i | sed -e 's&../zone/zone_welded&zone_lighted&g' | sed -e 's/.zonew/.zonel/g'` dest=`echo $i | sed -e 's&../zone/zone_welded&zone_lighted&g' | sed -e 's/.zonew/.zonel/g'`
depend=`echo $i | sed -e 's&../zone/zone_welded&../zone/zone_depend&g' | sed -e 's/.zonew/.depend/g'` depend=`echo $i | sed -e 's&../zone/zone_welded&../zone/zone_depend&g' | sed -e 's/.zonew/.depend/g'`
if ( test -e $dest ) if ( test -e $dest )
then then
echo PATCH $dest echo PATCH $dest
echo PATCH $dest >> log.log echo PATCH $dest >> log.log
# patch, and bkup if necessary # patch, and bkup if necessary
$exec_timeout $light_timeout $zone_lighter $i $dest zone_lighter_properties.cfg $depend -waterpatch bkup_tile_water $exec_timeout $light_timeout $zone_lighter $i $dest zone_lighter_properties.cfg $depend -waterpatch bkup_tile_water
echo echo
echo echo
else else
echo SKIP $dest cause not found echo SKIP $dest cause not found
echo SKIP $dest cause not found >> log.log echo SKIP $dest cause not found >> log.log
fi fi
# Idle # Idle
../../idle.bat ../../idle.bat
done done

@ -1,33 +1,33 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Build the processes # Build the processes
# Get the process list # Get the process list
process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'` process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'`
# Log error # Log error
echo > log.log echo > log.log
date >> log.log date >> log.log
date date
# For each process # For each process
for i in $process_to_complete ; do for i in $process_to_complete ; do
# Open the directory # Open the directory
cd processes/$i cd processes/$i
# Excecute the command # Excecute the command
./3_build.bat ./3_build.bat
# Get back # Get back
cd ../.. cd ../..
# Concat log.log files # Concat log.log files
cat processes/$i/log.log >> log.log cat processes/$i/log.log >> log.log
# Idle # Idle
./idle.bat ./idle.bat
done done
# Copy the log file # Copy the log file
cp log.log build.log cp log.log build.log

@ -1,29 +1,29 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Clean the processes # Clean the processes
# Get the process list # Get the process list
process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'` process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'`
# Log error # Log error
echo > log.log echo > log.log
# For each process # For each process
for i in $process_to_complete ; do for i in $process_to_complete ; do
# Open the directory # Open the directory
cd processes/$i cd processes/$i
# Excecute the command # Excecute the command
./1_clean.bat ./1_clean.bat
# Get back # Get back
cd ../.. cd ../..
# Concat log.log files # Concat log.log files
# cat processes/$i/log.log >> log.log # cat processes/$i/log.log >> log.log
# Idle # Idle
./idle.bat ./idle.bat
done done

@ -1,27 +1,27 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Clean the client # Clean the client
# Get the client directory # Get the client directory
client_directory=`cat cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client setup directories # Get the client setup directories
client_setup_directories=`cat cfg/directories.cfg | grep "client_setup_directory" | sed -e 's/client_setup_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_setup_directories=`cat cfg/directories.cfg | grep "client_setup_directory" | sed -e 's/client_setup_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* > log.log echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* > log.log
echo \*\*\*\*\*\*\* CLIENT CLEAN>> log.log echo \*\*\*\*\*\*\* CLIENT CLEAN>> log.log
echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* >> log.log echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* >> log.log
echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*
echo \*\*\*\*\*\*\* CLIENT CLEAN echo \*\*\*\*\*\*\* CLIENT CLEAN
echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* echo \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*
# For each directory # For each directory
for i in $client_setup_directories ; do for i in $client_setup_directories ; do
# Create the directory # Create the directory
rm $client_directory/$i/* rm $client_directory/$i/*
# Idle # Idle
./idle.bat ./idle.bat
done done

@ -1,24 +1,24 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Setup the client # Setup the client
# Get the client directory # Get the client directory
client_directory=`cat cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_directory=`cat cfg/site.cfg | grep "client_directory" | sed -e 's/client_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the client setup directories # Get the client setup directories
client_setup_directories=`cat cfg/directories.cfg | grep "client_setup_directory" | sed -e 's/client_setup_directory//' | sed -e 's/ //g' | sed -e 's/=//g'` client_setup_directories=`cat cfg/directories.cfg | grep "client_setup_directory" | sed -e 's/client_setup_directory//' | sed -e 's/ //g' | sed -e 's/=//g'`
# Log error # Log error
echo > log.log echo > log.log
# Create the file # Create the file
# For each directory # For each directory
for i in $client_setup_directories ; do for i in $client_setup_directories ; do
# Create the directory # Create the directory
mkdir $client_directory/$i 2> /dev/null mkdir $client_directory/$i 2> /dev/null
# Idle # Idle
./idle.bat ./idle.bat
done done

@ -1,33 +1,33 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Export the processes # Export the processes
# Get the process list # Get the process list
process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'` process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'`
# Log error # Log error
echo > log.log echo > log.log
date >> log.log date >> log.log
date date
# For each process # For each process
for i in $process_to_complete ; do for i in $process_to_complete ; do
# Open the directory # Open the directory
cd processes/$i cd processes/$i
# Excecute the command # Excecute the command
./2_export.bat ./2_export.bat
# Get back # Get back
cd ../.. cd ../..
# Concat log.log files # Concat log.log files
cat processes/$i/log.log >> log.log cat processes/$i/log.log >> log.log
# Idle # Idle
./idle.bat ./idle.bat
done done
# Copy the log file # Copy the log file
cp log.log export.log cp log.log export.log

@ -1,33 +1,33 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Install the processes # Install the processes
# Get the process list # Get the process list
process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'` process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'`
# Log error # Log error
echo > log.log echo > log.log
date >> log.log date >> log.log
date date
# For each process # For each process
for i in $process_to_complete ; do for i in $process_to_complete ; do
# Open the directory # Open the directory
cd processes/$i cd processes/$i
# Excecute the command # Excecute the command
./4_install.bat ./4_install.bat
# Get back # Get back
cd ../.. cd ../..
# Concat log.log files # Concat log.log files
cat processes/$i/log.log >> log.log cat processes/$i/log.log >> log.log
# Idle # Idle
./idle.bat ./idle.bat
done done
# Copy the log file # Copy the log file
cp log.log install.log cp log.log install.log

@ -1,62 +1,62 @@
#!/bin/bash #!/bin/bash
rm log.log 2> /dev/null rm log.log 2> /dev/null
# Setup the processes # Setup the processes
# Get the process list # Get the process list
process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'` process_to_complete=`cat cfg/config.cfg | grep "process_to_complete" | sed -e 's/process_to_complete//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'`
# Get the update directory # Get the update directory
update_directory=`cat cfg/config.cfg | grep "update_directory" | sed -e 's/update_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'` update_directory=`cat cfg/config.cfg | grep "update_directory" | sed -e 's/update_directory//' | sed -e 's/ //g' | sed -e 's/=//g' | sed -e 's/,/ /g'`
# Get the database directory # Get the database directory
database_directory=`cat cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_directory=`cat cfg/site.cfg | grep "database_directory" | sed -e 's/database_directory//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database letter # Get the database letter
database_letter=`cat cfg/site.cfg | grep "database_letter" | sed -e 's/database_letter//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_letter=`cat cfg/site.cfg | grep "database_letter" | sed -e 's/database_letter//g' | sed -e 's/ //g' | sed -e 's/=//g'`
# Get the database server # Get the database server
database_server=`cat cfg/site.cfg | grep "database_server" | sed -e 's/database_server//g' | sed -e 's/ //g' | sed -e 's/=//g'` database_server=`cat cfg/site.cfg | grep "database_server" | sed -e 's/database_server//g' | sed -e 's/ //g' | sed -e 's/=//g'`
`cat _idle.bat | sed -e "s&database_directory&$database_directory&g" | sed -e "s&database_letter&$database_letter&g" | sed -e "s&database_server&$database_server&g" > idle.bat` `cat _idle.bat | sed -e "s&database_directory&$database_directory&g" | sed -e "s&database_letter&$database_letter&g" | sed -e "s&database_server&$database_server&g" > idle.bat`
# Log error # Log error
echo > log.log echo > log.log
date >> log.log date >> log.log
date date
# Create a bin dir # Create a bin dir
mkdir bin 2> /dev/null mkdir bin 2> /dev/null
# For each process # For each process
for i in $process_to_complete ; do for i in $process_to_complete ; do
# Open the directory # Open the directory
cd processes/$i cd processes/$i
# Excecute the command # Excecute the command
./0_setup.bat ./0_setup.bat
# Get back # Get back
cd ../.. cd ../..
# Concat log.log files # Concat log.log files
# cat processes/$i/log.log >> log.log # cat processes/$i/log.log >> log.log
# Idle # Idle
./idle.bat ./idle.bat
done done
# Get the quality option to choose the goor properties.cfg file # Get the quality option to choose the goor properties.cfg file
quality_flag=`cat cfg/site.cfg | grep "build_quality" | grep "1"` quality_flag=`cat cfg/site.cfg | grep "build_quality" | grep "1"`
# Copy the good properties.cfg file # Copy the good properties.cfg file
if ( test "$quality_flag" ) if ( test "$quality_flag" )
then then
# We are in BEST mode # We are in BEST mode
echo [Quality] BEST echo [Quality] BEST
cp cfg/properties_final.cfg cfg/properties.cfg cp cfg/properties_final.cfg cfg/properties.cfg
else else
# We are not DRAFT mode # We are not DRAFT mode
echo [Quality] DRAFT echo [Quality] DRAFT
cp cfg/properties_draft.cfg cfg/properties.cfg cp cfg/properties_draft.cfg cfg/properties.cfg
fi fi

@ -65,220 +65,158 @@ if not args.noconf:
except NameError: except NameError:
BuildQuality = 1 BuildQuality = 1
try: try:
if args.preset: if not args.preset:
DummyUnknownName ToolDirectories
RemapLocalFrom
except NameError: except NameError:
RemapLocalFrom = 'R:' ToolDirectories = [ 'R:/distribution/nel_tools_win_x64-distribution', 'R:/distribution/ryzom_tools_win_x64-distribution' ]
try:
if args.preset:
DummyUnknownName
RemapLocalTo
except NameError:
RemapLocalTo = os.getenv('RC_ROOT').replace('\\', '/')
if (not RemapLocalTo) or (not ':' in RemapLocalTo):
RemapLocalTo = 'R:'
try:
if args.preset:
DummyUnknownName
ToolDirectories
except NameError:
ToolDirectories = [ 'R:/distribution/nel_tools_win_x64', 'R:/distribution/ryzom_tools_win_x64' ]
try: try:
ToolSuffix ToolSuffix
except NameError: except NameError:
ToolSuffix = ".exe" ToolSuffix = ".exe"
try: try:
if args.preset: if not args.preset:
DummyUnknownName ScriptDirectory
ScriptDirectory
except NameError: except NameError:
ScriptDirectory = "R:/code/nel/tools/build_gamedata" ScriptDirectory = "R:/code/nel/tools/build_gamedata"
try: try:
if args.preset: if not args.preset:
DummyUnknownName WorkspaceDirectory
WorkspaceDirectory
except NameError: except NameError:
WorkspaceDirectory = "R:/leveldesign/workspace" WorkspaceDirectory = "R:/leveldesign/workspace"
try: try:
if args.preset: if not args.preset:
DummyUnknownName DatabaseDirectory
DatabaseDirectory
except NameError: except NameError:
DatabaseDirectory = "R:/graphics" DatabaseDirectory = "R:/graphics"
try: try:
if args.preset: if not args.preset:
DummyUnknownName SoundDirectory
SoundDirectory
except NameError: except NameError:
SoundDirectory = "R:/sound" SoundDirectory = "R:/sound"
try: try:
if args.preset: if not args.preset:
DummyUnknownName SoundDfnDirectory
SoundDfnDirectory
except NameError: except NameError:
SoundDfnDirectory = "R:/sound/DFN" SoundDfnDirectory = "R:/sound/DFN"
try: try:
if args.preset: if not args.preset:
DummyUnknownName ExportBuildDirectory
ExportBuildDirectory
except NameError: except NameError:
ExportBuildDirectory = "R:/pipeline/export" ExportBuildDirectory = "R:/pipeline/export"
try: try:
if args.preset: if not args.preset:
DummyUnknownName InstallDirectory
InstallDirectory
except NameError: except NameError:
InstallDirectory = "R:/pipeline/install" InstallDirectory = "R:/pipeline/install"
try: try:
if args.preset: if not args.preset:
DummyUnknownName ClientDevDirectory
ClientDevDirectory
except NameError: except NameError:
ClientDevDirectory = "R:/pipeline/client_dev" ClientDevDirectory = "R:/pipeline/client_dev"
try: try:
if args.preset: if not args.preset:
DummyUnknownName ClientPatchDirectory
ClientDevLiveDirectory
except NameError:
ClientDevLiveDirectory = "R:/pipeline/client_dev_live"
try:
if args.preset:
DummyUnknownName
ClientPatchDirectory
except NameError: except NameError:
ClientPatchDirectory = "R:/pipeline/client_patch" ClientPatchDirectory = "R:/pipeline/client_patch"
try: try:
if args.preset: if not args.preset:
DummyUnknownName ClientInstallDirectory
ClientInstallDirectory
except NameError: except NameError:
ClientInstallDirectory = "R:/pipeline/client_install" ClientInstallDirectory = "R:/pipeline/client_install"
try: try:
if args.preset: if not args.preset:
DummyUnknownName ShardInstallDirectory
ShardInstallDirectory
except NameError: except NameError:
ShardInstallDirectory = "R:/pipeline/shard" ShardInstallDirectory = "R:/pipeline/shard"
try: try:
if args.preset: if not args.preset:
DummyUnknownName WorldEditInstallDirectory
ShardDevDirectory
except NameError:
ShardDevDirectory = "R:/pipeline/shard_dev"
try:
if args.preset:
DummyUnknownName
WorldEditInstallDirectory
except NameError: except NameError:
WorldEditInstallDirectory = "R:/pipeline/worldedit" WorldEditInstallDirectory = "R:/pipeline/worldedit"
try: try:
if args.preset: if not args.preset:
DummyUnknownName WorldEditorFilesDirectory
WorldEditorFilesDirectory
except NameError: except NameError:
WorldEditorFilesDirectory = "R:/code/ryzom/common/data_leveldesign/leveldesign/world_editor_files" WorldEditorFilesDirectory = "R:/code/ryzom/common/data_leveldesign/leveldesign/world_editor_files"
try: try:
if args.preset: if not args.preset:
DummyUnknownName LeveldesignDirectory
LeveldesignDirectory
except NameError: except NameError:
LeveldesignDirectory = "R:/leveldesign" LeveldesignDirectory = "R:/leveldesign"
try: try:
if args.preset: if not args.preset:
DummyUnknownName LeveldesignDfnDirectory
LeveldesignDfnDirectory
except NameError: except NameError:
LeveldesignDfnDirectory = "R:/leveldesign/DFN" LeveldesignDfnDirectory = "R:/leveldesign/DFN"
try: try:
if args.preset: if not args.preset:
DummyUnknownName LeveldesignWorldDirectory
LeveldesignWorldDirectory
except NameError: except NameError:
LeveldesignWorldDirectory = "R:/leveldesign/world" LeveldesignWorldDirectory = "R:/leveldesign/world"
try: try:
if args.preset: if not args.preset:
DummyUnknownName PrimitivesDirectory
PrimitivesDirectory
except NameError: except NameError:
PrimitivesDirectory = "R:/leveldesign/primitives" PrimitivesDirectory = "R:/leveldesign/primitives"
try: try:
if args.preset: if not args.preset:
DummyUnknownName LeveldesignDataCommonDirectory
LeveldesignDataCommonDirectory
except NameError: except NameError:
LeveldesignDataCommonDirectory = "R:/leveldesign/common" LeveldesignDataCommonDirectory = "R:/leveldesign/common"
try: try:
if args.preset: if not args.preset:
DummyUnknownName LeveldesignDataShardDirectory
LeveldesignDataShardDirectory
except NameError: except NameError:
LeveldesignDataShardDirectory = "R:/leveldesign/shard" LeveldesignDataShardDirectory = "R:/leveldesign/shard"
try: try:
if args.preset: if not args.preset:
DummyUnknownName TranslationDirectory
TranslationDirectory
except NameError: except NameError:
TranslationDirectory = "R:/leveldesign/translation" TranslationDirectory = "R:/leveldesign/translation"
try: try:
if args.preset: if not args.preset:
DummyUnknownName GamedevDirectory
GamedevDirectory
except NameError: except NameError:
GamedevDirectory = "R:/code/ryzom/client/data/gamedev" GamedevDirectory = "R:/code/ryzom/client/data/gamedev"
try: try:
if args.preset: if not args.preset:
DummyUnknownName DataCommonDirectory
DataCommonDirectory
except NameError: except NameError:
DataCommonDirectory = "R:/code/ryzom/common/data_common" DataCommonDirectory = "R:/code/ryzom/common/data_common"
try: try:
if args.preset: if not args.preset:
DummyUnknownName DataShardDirectory
DataShardDirectory
except NameError: except NameError:
DataShardDirectory = "R:/code/ryzom/server/data_shard" DataShardDirectory = "R:/code/ryzom/server/data_shard"
try: try:
if args.preset: if not args.preset:
DummyUnknownName WindowsExeDllCfgDirectories
WindowsExeDllCfgDirectories
except NameError: except NameError:
# TODO: Separate 64bit and 32bit # TODO: Separate 64bit and 32bit
WindowsExeDllCfgDirectories = [ '', 'R:/build/fv_x64/bin/Release', 'R:/distribution/external_x64', 'R:/code/ryzom/client', '', '', '' ] WindowsExeDllCfgDirectories = [ '', 'R:/build/fv_x64/bin/Release', 'R:/distribution/external_x64', 'R:/code/ryzom/client', '', '', '' ]
try: try:
if args.preset: if not args.preset:
DummyUnknownName LinuxServiceExecutableDirectory
LinuxServiceExecutableDirectory
except NameError:
LinuxServiceExecutableDirectory = "R:/build/server_gcc/bin"
try:
if args.preset:
DummyUnknownName
LinuxClientExecutableDirectory
except NameError: except NameError:
LinuxClientExecutableDirectory = "R:/build/client_gcc/bin" LinuxServiceExecutableDirectory = "R:/build/gcc_server/bin"
try: try:
if args.preset: if not args.preset:
DummyUnknownName LinuxClientExecutableDirectory
PatchmanDevDirectory
except NameError: except NameError:
PatchmanDevDirectory = "R:/patchman/terminal_dev" LinuxClientExecutableDirectory = "R:/build/gcc_client/bin"
try: try:
if args.preset: if not args.preset:
DummyUnknownName PatchmanCfgAdminDirectory
PatchmanCfgAdminDirectory
except NameError: except NameError:
PatchmanCfgAdminDirectory = "R:/patchman/admin_install" PatchmanCfgAdminDirectory = "R:/patchman/admin_install"
try: try:
if args.preset: if not args.preset:
DummyUnknownName PatchmanCfgDefaultDirectory
PatchmanCfgDefaultDirectory
except NameError: except NameError:
PatchmanCfgDefaultDirectory = "R:/patchman/default" PatchmanCfgDefaultDirectory = "R:/patchman/default"
try: try:
if args.preset: if not args.preset:
DummyUnknownName PatchmanBridgeServerDirectory
PatchmanBridgeServerDirectory
except NameError: except NameError:
PatchmanBridgeServerDirectory = "R:/pipeline/bridge_server" PatchmanBridgeServerDirectory = "R:/pipeline/bridge_server"
try: try:
@ -338,11 +276,9 @@ if not args.noconf:
ExportBuildDirectory = askVar(log, "[OUT] Export Build Directory", ExportBuildDirectory).replace("\\", "/") ExportBuildDirectory = askVar(log, "[OUT] Export Build Directory", ExportBuildDirectory).replace("\\", "/")
InstallDirectory = askVar(log, "[OUT] Install Directory", InstallDirectory).replace("\\", "/") InstallDirectory = askVar(log, "[OUT] Install Directory", InstallDirectory).replace("\\", "/")
ClientDevDirectory = askVar(log, "[OUT] Client Dev Directory", ClientDevDirectory).replace("\\", "/") ClientDevDirectory = askVar(log, "[OUT] Client Dev Directory", ClientDevDirectory).replace("\\", "/")
ClientDevLiveDirectory = askVar(log, "[OUT] Client Dev Live Directory", ClientDevLiveDirectory).replace("\\", "/")
ClientPatchDirectory = askVar(log, "[OUT] Client Patch Directory", ClientPatchDirectory).replace("\\", "/") ClientPatchDirectory = askVar(log, "[OUT] Client Patch Directory", ClientPatchDirectory).replace("\\", "/")
ClientInstallDirectory = askVar(log, "[OUT] Client Install Directory", ClientInstallDirectory).replace("\\", "/") ClientInstallDirectory = askVar(log, "[OUT] Client Install Directory", ClientInstallDirectory).replace("\\", "/")
ShardInstallDirectory = askVar(log, "[OUT] Shard Data Install Directory", ShardInstallDirectory).replace("\\", "/") ShardInstallDirectory = askVar(log, "[OUT] Shard Data Install Directory", ShardInstallDirectory).replace("\\", "/")
ShardDevDirectory = askVar(log, "[OUT] Shard Dev Directory", ShardDevDirectory).replace("\\", "/")
WorldEditInstallDirectory = askVar(log, "[OUT] World Edit Data Install Directory", WorldEditInstallDirectory).replace("\\", "/") WorldEditInstallDirectory = askVar(log, "[OUT] World Edit Data Install Directory", WorldEditInstallDirectory).replace("\\", "/")
LeveldesignDirectory = askVar(log, "[IN] Leveldesign Directory", LeveldesignDirectory).replace("\\", "/") LeveldesignDirectory = askVar(log, "[IN] Leveldesign Directory", LeveldesignDirectory).replace("\\", "/")
LeveldesignDfnDirectory = askVar(log, "[IN] Leveldesign DFN Directory", LeveldesignDfnDirectory).replace("\\", "/") LeveldesignDfnDirectory = askVar(log, "[IN] Leveldesign DFN Directory", LeveldesignDfnDirectory).replace("\\", "/")
@ -364,7 +300,6 @@ if not args.noconf:
WindowsExeDllCfgDirectories[6] = askVar(log, "[IN] Septenary Windows exe/dll/cfg Directory", WindowsExeDllCfgDirectories[6]).replace("\\", "/") WindowsExeDllCfgDirectories[6] = askVar(log, "[IN] Septenary Windows exe/dll/cfg Directory", WindowsExeDllCfgDirectories[6]).replace("\\", "/")
LinuxServiceExecutableDirectory = askVar(log, "[IN] Linux Service Executable Directory", LinuxServiceExecutableDirectory).replace("\\", "/") LinuxServiceExecutableDirectory = askVar(log, "[IN] Linux Service Executable Directory", LinuxServiceExecutableDirectory).replace("\\", "/")
LinuxClientExecutableDirectory = askVar(log, "[IN] Linux Client Executable Directory", LinuxClientExecutableDirectory).replace("\\", "/") LinuxClientExecutableDirectory = askVar(log, "[IN] Linux Client Executable Directory", LinuxClientExecutableDirectory).replace("\\", "/")
PatchmanDevDirectory = askVar(log, "[IN] Patchman Directory", PatchmanDevDirectory).replace("\\", "/")
PatchmanCfgAdminDirectory = askVar(log, "[IN] Patchman Cfg Admin Directory", PatchmanCfgAdminDirectory).replace("\\", "/") PatchmanCfgAdminDirectory = askVar(log, "[IN] Patchman Cfg Admin Directory", PatchmanCfgAdminDirectory).replace("\\", "/")
PatchmanCfgDefaultDirectory = askVar(log, "[IN] Patchman Cfg Default Directory", PatchmanCfgDefaultDirectory).replace("\\", "/") PatchmanCfgDefaultDirectory = askVar(log, "[IN] Patchman Cfg Default Directory", PatchmanCfgDefaultDirectory).replace("\\", "/")
PatchmanBridgeServerDirectory = askVar(log, "[OUT] Patchman Bridge Server Patch Directory", PatchmanBridgeServerDirectory).replace("\\", "/") PatchmanBridgeServerDirectory = askVar(log, "[OUT] Patchman Bridge Server Patch Directory", PatchmanBridgeServerDirectory).replace("\\", "/")
@ -415,9 +350,6 @@ if not args.noconf:
sf.write("# Quality option for this site (1 for BEST, 0 for DRAFT)\n") sf.write("# Quality option for this site (1 for BEST, 0 for DRAFT)\n")
sf.write("BuildQuality = " + str(BuildQuality) + "\n") sf.write("BuildQuality = " + str(BuildQuality) + "\n")
sf.write("\n") sf.write("\n")
sf.write("RemapLocalFrom = \"" + str(RemapLocalFrom) + "\"\n")
sf.write("RemapLocalTo = \"" + str(RemapLocalTo) + "\"\n")
sf.write("\n")
sf.write("ToolDirectories = " + str(ToolDirectories) + "\n") sf.write("ToolDirectories = " + str(ToolDirectories) + "\n")
sf.write("ToolSuffix = \"" + str(ToolSuffix) + "\"\n") sf.write("ToolSuffix = \"" + str(ToolSuffix) + "\"\n")
sf.write("\n") sf.write("\n")
@ -434,11 +366,9 @@ if not args.noconf:
sf.write("# Install directories\n") sf.write("# Install directories\n")
sf.write("InstallDirectory = \"" + str(InstallDirectory) + "\"\n") sf.write("InstallDirectory = \"" + str(InstallDirectory) + "\"\n")
sf.write("ClientDevDirectory = \"" + str(ClientDevDirectory) + "\"\n") sf.write("ClientDevDirectory = \"" + str(ClientDevDirectory) + "\"\n")
sf.write("ClientDevLiveDirectory = \"" + str(ClientDevLiveDirectory) + "\"\n")
sf.write("ClientPatchDirectory = \"" + str(ClientPatchDirectory) + "\"\n") sf.write("ClientPatchDirectory = \"" + str(ClientPatchDirectory) + "\"\n")
sf.write("ClientInstallDirectory = \"" + str(ClientInstallDirectory) + "\"\n") sf.write("ClientInstallDirectory = \"" + str(ClientInstallDirectory) + "\"\n")
sf.write("ShardInstallDirectory = \"" + str(ShardInstallDirectory) + "\"\n") sf.write("ShardInstallDirectory = \"" + str(ShardInstallDirectory) + "\"\n")
sf.write("ShardDevDirectory = \"" + str(ShardDevDirectory) + "\"\n")
sf.write("WorldEditInstallDirectory = \"" + str(WorldEditInstallDirectory) + "\"\n") sf.write("WorldEditInstallDirectory = \"" + str(WorldEditInstallDirectory) + "\"\n")
sf.write("\n") sf.write("\n")
sf.write("# Utility directories\n") sf.write("# Utility directories\n")
@ -460,7 +390,6 @@ if not args.noconf:
sf.write("WindowsExeDllCfgDirectories = " + str(WindowsExeDllCfgDirectories) + "\n") sf.write("WindowsExeDllCfgDirectories = " + str(WindowsExeDllCfgDirectories) + "\n")
sf.write("LinuxServiceExecutableDirectory = \"" + str(LinuxServiceExecutableDirectory) + "\"\n") sf.write("LinuxServiceExecutableDirectory = \"" + str(LinuxServiceExecutableDirectory) + "\"\n")
sf.write("LinuxClientExecutableDirectory = \"" + str(LinuxClientExecutableDirectory) + "\"\n") sf.write("LinuxClientExecutableDirectory = \"" + str(LinuxClientExecutableDirectory) + "\"\n")
sf.write("PatchmanDevDirectory = \"" + str(PatchmanDevDirectory) + "\"\n")
sf.write("PatchmanCfgAdminDirectory = \"" + str(PatchmanCfgAdminDirectory) + "\"\n") sf.write("PatchmanCfgAdminDirectory = \"" + str(PatchmanCfgAdminDirectory) + "\"\n")
sf.write("PatchmanCfgDefaultDirectory = \"" + str(PatchmanCfgDefaultDirectory) + "\"\n") sf.write("PatchmanCfgDefaultDirectory = \"" + str(PatchmanCfgDefaultDirectory) + "\"\n")
sf.write("PatchmanBridgeServerDirectory = \"" + str(PatchmanBridgeServerDirectory) + "\"\n") sf.write("PatchmanBridgeServerDirectory = \"" + str(PatchmanBridgeServerDirectory) + "\"\n")
@ -478,18 +407,8 @@ if not args.noconf:
sf.write("\n") sf.write("\n")
sf.write("\n") sf.write("\n")
sf.write("# end of file\n") sf.write("# end of file\n")
sf.flush()
sf.close()
sf = open("configuration/buildsite_local.py", "w")
sfr = open("configuration/buildsite.py", "r")
for l in sfr:
sf.write(l.replace(RemapLocalFrom + '/', RemapLocalTo + '/'))
sf.flush()
sfr.close()
sf.close() sf.close()
from buildsite_local import *
sys.path.append(WorkspaceDirectory) sys.path.append(WorkspaceDirectory)
from projects import * from projects import *
@ -529,7 +448,6 @@ printLog(log, "")
# Additional directories # Additional directories
printLog(log, ">>> Setup additional directories <<<") printLog(log, ">>> Setup additional directories <<<")
mkPath(log, ClientDevDirectory) mkPath(log, ClientDevDirectory)
mkPath(log, ClientDevLiveDirectory)
mkPath(log, ClientPatchDirectory) mkPath(log, ClientPatchDirectory)
mkPath(log, ClientInstallDirectory) mkPath(log, ClientInstallDirectory)
@ -585,7 +503,6 @@ if not args.noverify:
findTool(log, ToolDirectories, TranslationToolsTool, ToolSuffix) findTool(log, ToolDirectories, TranslationToolsTool, ToolSuffix)
findTool(log, ToolDirectories, BuildWorldPackedColTool, ToolSuffix) findTool(log, ToolDirectories, BuildWorldPackedColTool, ToolSuffix)
findTool(log, ToolDirectories, R2IslandsTexturesTool, ToolSuffix) findTool(log, ToolDirectories, R2IslandsTexturesTool, ToolSuffix)
findTool(log, ToolDirectories, PatchmanServiceTool, ToolSuffix)
log.close() log.close()
if os.path.isfile("0_setup.log"): if os.path.isfile("0_setup.log"):

@ -1,94 +1,94 @@
#!/usr/bin/python #!/usr/bin/python
# #
# \file 1_export.py # \file 1_export.py
# \brief Run all export processes # \brief Run all export processes
# \date 2009-02-18 09:22GMT # \date 2009-02-18 09:22GMT
# \author Jan Boon (Kaetemi) # \author Jan Boon (Kaetemi)
# Python port of game data build pipeline. # Python port of game data build pipeline.
# Run all export processes # Run all export processes
# #
# NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/> # NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
# Copyright (C) 2009-2014 by authors # Copyright (C) 2009-2014 by authors
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version. # License, or (at your option) any later version.
# #
# This program is distributed in the hope that it will be useful, # This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of # but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details. # GNU Affero General Public License for more details.
# #
# You should have received a copy of the GNU Affero General Public License # You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>. # along with this program. If not, see <http://www.gnu.org/licenses/>.
# #
import time, sys, os, shutil, subprocess, distutils.dir_util, argparse import time, sys, os, shutil, subprocess, distutils.dir_util, argparse
sys.path.append("configuration") sys.path.append("configuration")
parser = argparse.ArgumentParser(description='Ryzom Core - Build Gamedata - Export') parser = argparse.ArgumentParser(description='Ryzom Core - Build Gamedata - Export')
# parser.add_argument('--haltonerror', '-eh', action='store_true') # parser.add_argument('--haltonerror', '-eh', action='store_true')
parser.add_argument('--includeproject', '-ipj', nargs='+') parser.add_argument('--includeproject', '-ipj', nargs='+')
parser.add_argument('--excludeproject', '-epj', nargs='+') parser.add_argument('--excludeproject', '-epj', nargs='+')
parser.add_argument('--includeprocess', '-ipc', nargs='+') parser.add_argument('--includeprocess', '-ipc', nargs='+')
parser.add_argument('--excludeprocess', '-epc', nargs='+') parser.add_argument('--excludeprocess', '-epc', nargs='+')
args = parser.parse_args() args = parser.parse_args()
if not args.includeproject == None and not args.excludeproject == None: if not args.includeproject == None and not args.excludeproject == None:
print "ERROR --includeproject cannot be combined with --excludeproject, exit." print "ERROR --includeproject cannot be combined with --excludeproject, exit."
exit() exit()
if not args.includeprocess == None and not args.excludeprocess == None: if not args.includeprocess == None and not args.excludeprocess == None:
print "ERROR --includeprocess cannot be combined with --excludeprocess, exit." print "ERROR --includeprocess cannot be combined with --excludeprocess, exit."
exit() exit()
if os.path.isfile("log.log"): if os.path.isfile("log.log"):
os.remove("log.log") os.remove("log.log")
log = open("log.log", "w") log = open("log.log", "w")
from scripts import * from scripts import *
from buildsite_local import * from buildsite_local import *
from tools import * from tools import *
sys.path.append(WorkspaceDirectory) sys.path.append(WorkspaceDirectory)
from projects import * from projects import *
# Log error # Log error
printLog(log, "") printLog(log, "")
printLog(log, "-------") printLog(log, "-------")
printLog(log, "--- Run the export processes") printLog(log, "--- Run the export processes")
printLog(log, "-------") printLog(log, "-------")
printLog(log, time.strftime("%Y-%m-%d %H:%MGMT", time.gmtime(time.time()))) printLog(log, time.strftime("%Y-%m-%d %H:%MGMT", time.gmtime(time.time())))
printLog(log, "") printLog(log, "")
# For each project # For each project
for projectName in ProjectsToProcess: for projectName in ProjectsToProcess:
if ((args.includeproject == None or projectName in args.includeproject) and (args.excludeproject == None or not projectName in args.excludeproject)): if ((args.includeproject == None or projectName in args.includeproject) and (args.excludeproject == None or not projectName in args.excludeproject)):
printLog(log, "PROJECT " + projectName) printLog(log, "PROJECT " + projectName)
os.putenv("NELBUILDACTIVEPROJECT", os.path.abspath(WorkspaceDirectory + "/" + projectName)) os.putenv("NELBUILDACTIVEPROJECT", os.path.abspath(WorkspaceDirectory + "/" + projectName))
os.chdir("processes") os.chdir("processes")
try: try:
if not args.includeprocess == None: if not args.includeprocess == None:
subprocess.call([ "python", "1_export.py", "--includeprocess" ] + args.includeprocess) subprocess.call([ "python", "1_export.py", "--includeprocess" ] + args.includeprocess)
elif not args.excludeprocess == None: elif not args.excludeprocess == None:
subprocess.call([ "python", "1_export.py", "--excludeprocess" ] + args.excludeprocess) subprocess.call([ "python", "1_export.py", "--excludeprocess" ] + args.excludeprocess)
else: else:
subprocess.call([ "python", "1_export.py" ]) subprocess.call([ "python", "1_export.py" ])
except Exception, e: except Exception, e:
printLog(log, "<" + projectName + "> " + str(e)) printLog(log, "<" + projectName + "> " + str(e))
os.chdir("..") os.chdir("..")
try: try:
projectLog = open("processes/log.log", "r") projectLog = open("processes/log.log", "r")
projectLogData = projectLog.read() projectLogData = projectLog.read()
projectLog.close() projectLog.close()
log.write(projectLogData) log.write(projectLogData)
except Exception, e: except Exception, e:
printLog(log, "<" + projectName + "> " + str(e)) printLog(log, "<" + projectName + "> " + str(e))
else: else:
printLog(log, "IGNORE PROJECT " + projectName) printLog(log, "IGNORE PROJECT " + projectName)
printLog(log, "") printLog(log, "")
log.close() log.close()
if os.path.isfile("1_export.log"): if os.path.isfile("1_export.log"):
os.remove("1_export.log") os.remove("1_export.log")
shutil.copy("log.log", time.strftime("%Y-%m-%d-%H-%M-GMT", time.gmtime(time.time())) + "_export.log") shutil.copy("log.log", time.strftime("%Y-%m-%d-%H-%M-GMT", time.gmtime(time.time())) + "_export.log")
shutil.move("log.log", "1_export.log") shutil.move("log.log", "1_export.log")

@ -1,94 +1,94 @@
#!/usr/bin/python #!/usr/bin/python
# #
# \file 2_build.py # \file 2_build.py
# \brief Run all build processes # \brief Run all build processes
# \date 2009-02-18 09:22GMT # \date 2009-02-18 09:22GMT
# \author Jan Boon (Kaetemi) # \author Jan Boon (Kaetemi)
# Python port of game data build pipeline. # Python port of game data build pipeline.
# Run all build processes # Run all build processes
# #
# NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/> # NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
# Copyright (C) 2009-2014 by authors # Copyright (C) 2009-2014 by authors
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version. # License, or (at your option) any later version.
# #
# This program is distributed in the hope that it will be useful, # This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of # but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details. # GNU Affero General Public License for more details.
# #
# You should have received a copy of the GNU Affero General Public License # You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>. # along with this program. If not, see <http://www.gnu.org/licenses/>.
# #
import time, sys, os, shutil, subprocess, distutils.dir_util, argparse import time, sys, os, shutil, subprocess, distutils.dir_util, argparse
sys.path.append("configuration") sys.path.append("configuration")
parser = argparse.ArgumentParser(description='Ryzom Core - Build Gamedata - Build') parser = argparse.ArgumentParser(description='Ryzom Core - Build Gamedata - Build')
# parser.add_argument('--haltonerror', '-eh', action='store_true') # parser.add_argument('--haltonerror', '-eh', action='store_true')
parser.add_argument('--includeproject', '-ipj', nargs='+') parser.add_argument('--includeproject', '-ipj', nargs='+')
parser.add_argument('--excludeproject', '-epj', nargs='+') parser.add_argument('--excludeproject', '-epj', nargs='+')
parser.add_argument('--includeprocess', '-ipc', nargs='+') parser.add_argument('--includeprocess', '-ipc', nargs='+')
parser.add_argument('--excludeprocess', '-epc', nargs='+') parser.add_argument('--excludeprocess', '-epc', nargs='+')
args = parser.parse_args() args = parser.parse_args()
if not args.includeproject == None and not args.excludeproject == None: if not args.includeproject == None and not args.excludeproject == None:
print "ERROR --includeproject cannot be combined with --excludeproject, exit." print "ERROR --includeproject cannot be combined with --excludeproject, exit."
exit() exit()
if not args.includeprocess == None and not args.excludeprocess == None: if not args.includeprocess == None and not args.excludeprocess == None:
print "ERROR --includeprocess cannot be combined with --excludeprocess, exit." print "ERROR --includeprocess cannot be combined with --excludeprocess, exit."
exit() exit()
if os.path.isfile("log.log"): if os.path.isfile("log.log"):
os.remove("log.log") os.remove("log.log")
log = open("log.log", "w") log = open("log.log", "w")
from scripts import * from scripts import *
from buildsite_local import * from buildsite_local import *
from tools import * from tools import *
sys.path.append(WorkspaceDirectory) sys.path.append(WorkspaceDirectory)
from projects import * from projects import *
# Log error # Log error
printLog(log, "") printLog(log, "")
printLog(log, "-------") printLog(log, "-------")
printLog(log, "--- Run the build processes") printLog(log, "--- Run the build processes")
printLog(log, "-------") printLog(log, "-------")
printLog(log, time.strftime("%Y-%m-%d %H:%MGMT", time.gmtime(time.time()))) printLog(log, time.strftime("%Y-%m-%d %H:%MGMT", time.gmtime(time.time())))
printLog(log, "") printLog(log, "")
# For each project # For each project
for projectName in ProjectsToProcess: for projectName in ProjectsToProcess:
if ((args.includeproject == None or projectName in args.includeproject) and (args.excludeproject == None or not projectName in args.excludeproject)): if ((args.includeproject == None or projectName in args.includeproject) and (args.excludeproject == None or not projectName in args.excludeproject)):
printLog(log, "PROJECT " + projectName) printLog(log, "PROJECT " + projectName)
os.putenv("NELBUILDACTIVEPROJECT", os.path.abspath(WorkspaceDirectory + "/" + projectName)) os.putenv("NELBUILDACTIVEPROJECT", os.path.abspath(WorkspaceDirectory + "/" + projectName))
os.chdir("processes") os.chdir("processes")
try: try:
if not args.includeprocess == None: if not args.includeprocess == None:
subprocess.call([ "python", "2_build.py", "--includeprocess" ] + args.includeprocess) subprocess.call([ "python", "2_build.py", "--includeprocess" ] + args.includeprocess)
elif not args.excludeprocess == None: elif not args.excludeprocess == None:
subprocess.call([ "python", "2_build.py", "--excludeprocess" ] + args.excludeprocess) subprocess.call([ "python", "2_build.py", "--excludeprocess" ] + args.excludeprocess)
else: else:
subprocess.call([ "python", "2_build.py" ]) subprocess.call([ "python", "2_build.py" ])
except Exception, e: except Exception, e:
printLog(log, "<" + projectName + "> " + str(e)) printLog(log, "<" + projectName + "> " + str(e))
os.chdir("..") os.chdir("..")
try: try:
projectLog = open("processes/log.log", "r") projectLog = open("processes/log.log", "r")
projectLogData = projectLog.read() projectLogData = projectLog.read()
projectLog.close() projectLog.close()
log.write(projectLogData) log.write(projectLogData)
except Exception, e: except Exception, e:
printLog(log, "<" + projectName + "> " + str(e)) printLog(log, "<" + projectName + "> " + str(e))
else: else:
printLog(log, "IGNORE PROJECT " + projectName) printLog(log, "IGNORE PROJECT " + projectName)
printLog(log, "") printLog(log, "")
log.close() log.close()
if os.path.isfile("2_build.log"): if os.path.isfile("2_build.log"):
os.remove("2_build.log") os.remove("2_build.log")
shutil.copy("log.log", time.strftime("%Y-%m-%d-%H-%M-GMT", time.gmtime(time.time())) + "_build.log") shutil.copy("log.log", time.strftime("%Y-%m-%d-%H-%M-GMT", time.gmtime(time.time())) + "_build.log")
shutil.move("log.log", "2_build.log") shutil.move("log.log", "2_build.log")

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save