mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-06 09:09:40 +02:00
tweak
This commit is contained in:
2
Global.h
2
Global.h
@@ -244,8 +244,6 @@ typedef boost::lock_guard<boost::recursive_mutex> TLockGuardRec;
|
|||||||
|
|
||||||
#define THROW_FORMAT(message, formatting_elems) throw std::runtime_error(boost::str(boost::format(message) % formatting_elems))
|
#define THROW_FORMAT(message, formatting_elems) throw std::runtime_error(boost::str(boost::format(message) % formatting_elems))
|
||||||
|
|
||||||
#define ASSERT_IF_CALLED_WITH_PLAYER if(!player) {logGlobal->errorStream() << BOOST_CURRENT_FUNCTION; assert(0);}
|
|
||||||
|
|
||||||
// can be used for counting arrays
|
// can be used for counting arrays
|
||||||
template<typename T, size_t N> char (&_ArrayCountObj(const T (&)[N]))[N];
|
template<typename T, size_t N> char (&_ArrayCountObj(const T (&)[N]))[N];
|
||||||
#define ARRAY_COUNT(arr) (sizeof(_ArrayCountObj(arr)))
|
#define ARRAY_COUNT(arr) (sizeof(_ArrayCountObj(arr)))
|
||||||
|
|||||||
@@ -10,6 +10,8 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "CBattleInfoCallback.h"
|
#include "CBattleInfoCallback.h"
|
||||||
|
|
||||||
|
#define ASSERT_IF_CALLED_WITH_PLAYER if(!player) {logGlobal->error(BOOST_CURRENT_FUNCTION); assert(0);}
|
||||||
|
|
||||||
class CGHeroInstance;
|
class CGHeroInstance;
|
||||||
|
|
||||||
class DLL_LINKAGE CPlayerBattleCallback : public CBattleInfoCallback
|
class DLL_LINKAGE CPlayerBattleCallback : public CBattleInfoCallback
|
||||||
|
|||||||
Reference in New Issue
Block a user