CLANG test 1 ==> compilation error
This commit is contained in:
parent
681f5a529d
commit
4f62af618d
@ -18,10 +18,6 @@ DESTDIR :=
|
||||
PREFIX := /usr/local
|
||||
|
||||
# Tools
|
||||
GCC := gcc
|
||||
GXX := g++
|
||||
AR := ar
|
||||
LD := ld
|
||||
WINDRES := windres
|
||||
|
||||
# Overridable settings
|
||||
@ -29,6 +25,20 @@ V := 0
|
||||
W := 0
|
||||
DEBUG := 0
|
||||
STATIC := 0
|
||||
CLANG := 0
|
||||
|
||||
|
||||
ifneq ("$(CLANG)","1")
|
||||
GCC := gcc
|
||||
GXX := g++
|
||||
AR := ar
|
||||
LD := ld
|
||||
else
|
||||
GCC := clang
|
||||
GXX := clang++
|
||||
AR := ar
|
||||
LD := ld
|
||||
endif
|
||||
|
||||
# Quiet command if V is not 1
|
||||
ifneq ("$(V)","1")
|
||||
|
@ -344,7 +344,7 @@ namespace agg
|
||||
|
||||
|
||||
//--------------------------------------------------------------------
|
||||
scanline32_u8() :
|
||||
scanline32_u8(void) :
|
||||
m_min_x(0),
|
||||
m_last_x(0x7FFFFFF0),
|
||||
m_covers()
|
||||
@ -422,17 +422,17 @@ namespace agg
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------
|
||||
void reset_spans()
|
||||
void reset_spans(void)
|
||||
{
|
||||
m_last_x = 0x7FFFFFF0;
|
||||
m_spans.remove_all();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------
|
||||
int y() const { return m_y; }
|
||||
unsigned num_spans() const { return m_spans.size(); }
|
||||
const_iterator begin() const { return const_iterator(m_spans); }
|
||||
iterator begin() { return iterator(m_spans); }
|
||||
int y(void) const { return m_y; }
|
||||
unsigned num_spans(void) const { return m_spans.size(); }
|
||||
const_iterator begin(void) const { return const_iterator(m_spans); }
|
||||
iterator begin(void) { return iterator(m_spans); }
|
||||
|
||||
private:
|
||||
scanline32_u8(const self_type&);
|
||||
@ -464,7 +464,7 @@ namespace agg
|
||||
typedef base_type::coord_type coord_type;
|
||||
|
||||
|
||||
scanline32_u8_am() : base_type(), m_alpha_mask(0) {}
|
||||
scanline32_u8_am(void) : scanline_u8(), m_alpha_mask(0) {}
|
||||
scanline32_u8_am(const AlphaMask& am) : base_type(), m_alpha_mask(&am) {}
|
||||
|
||||
//--------------------------------------------------------------------
|
||||
|
@ -33,6 +33,7 @@
|
||||
#include <math.h>
|
||||
|
||||
#define CYCLIC_CALL_PERIODE_US (10000)
|
||||
#define NB_SPECIAL_PARAM (5)
|
||||
|
||||
namespace ewol {
|
||||
|
||||
@ -55,6 +56,7 @@ namespace ewol {
|
||||
float m_size; //!< Current size of the element more specific size can be done in the under class => this is for simplify calculation ==> all is consider like sphere...
|
||||
bool m_canBeCibled; //!< This is for automatic finding on an ennemy
|
||||
bool m_canHaveImpact; //!< detection of impact is done with this ...
|
||||
float m_specialParam[NB_SPECIAL_PARAM]; //!< specific game user parameter
|
||||
public:
|
||||
/**
|
||||
* @brief Constructor : here are requested all the needed sprite and effect that can be used in the game
|
||||
@ -109,6 +111,9 @@ namespace ewol {
|
||||
uint16_t GroupGet(void) { return m_group; };
|
||||
void GroupSet(uint16_t state) { m_group = state; };
|
||||
|
||||
float SpecialParamGet(int32_t id) { if (id<0 || id>=NB_SPECIAL_PARAM) {return 0.0;} return m_specialParam[id]; };
|
||||
void SpecialParamSet(int32_t id, float state) { if (id<0 || id>=NB_SPECIAL_PARAM) {return;} m_specialParam[id]=state; };
|
||||
|
||||
/**
|
||||
* @brief Periodicly this fuction will be call tu change property of all the dynamic obbjects
|
||||
* @param[in] time Current game time (start at 0)
|
||||
|
@ -40,7 +40,7 @@ ewol::SceneElement::SceneElement(void)
|
||||
for (int32_t iii=0; iii<MAX_GROUP_NUMBER; iii++) {
|
||||
int32_t kkk = 0;
|
||||
for (int32_t jjj=0; jjj<MAX_GROUP_NUMBER-1; jjj++) {
|
||||
if (jjj == kkk) {
|
||||
if (iii == kkk) {
|
||||
kkk++;
|
||||
}
|
||||
groupEnemy[iii][jjj] = kkk;
|
||||
@ -224,14 +224,18 @@ uint32_t ewol::SceneElement::GetNearestEnemy(Vector2D<float> position, int32_t g
|
||||
return 0;
|
||||
}
|
||||
while (groupEnemy[groupId][jjj] != -1) {
|
||||
for (int32_t iii=0; iii<listAnimatedElements[groupEnemy[groupId][jjj]].Size(); iii++) {
|
||||
if (NULL != listAnimatedElements[groupEnemy[groupId][jjj]][iii]) {
|
||||
if (true == listAnimatedElements[groupEnemy[groupId][jjj]][iii]->CanBeCibledGet()) {
|
||||
Vector2D<float> tmpPos = listAnimatedElements[groupEnemy[groupId][jjj]][iii]->PositionGet();
|
||||
int32_t gId = groupEnemy[groupId][jjj];
|
||||
if (gId == groupId) {
|
||||
EWOL_ERROR("groupId=" << gId << " is ennemy of groupId:" << groupId);
|
||||
}
|
||||
for (int32_t iii=0; iii<listAnimatedElements[gId].Size(); iii++) {
|
||||
if (NULL != listAnimatedElements[gId][iii]) {
|
||||
if (true == listAnimatedElements[gId][iii]->CanBeCibledGet()) {
|
||||
Vector2D<float> tmpPos = listAnimatedElements[gId][iii]->PositionGet();
|
||||
float distance = quadDist(position, tmpPos);
|
||||
if (distance <= lastQuadDistance) {
|
||||
lastQuadDistance = distance;
|
||||
result = createUniqueId(listAnimatedElements[groupEnemy[groupId][jjj]][iii]->GetUniqueId(), iii);
|
||||
result = createUniqueId(listAnimatedElements[gId][iii]->GetUniqueId(), iii);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user