edited destructionLayer, changed includes
This commit is contained in:
		@@ -9,7 +9,6 @@
 | 
			
		||||
#define DESTRUCTION_COUNT 1
 | 
			
		||||
 | 
			
		||||
#include "../AbstraktionLayer_Base.h"
 | 
			
		||||
#include "DestructionPower_Properties.h"
 | 
			
		||||
#include <vector>
 | 
			
		||||
#include <iostream>
 | 
			
		||||
#include <bitset>
 | 
			
		||||
 
 | 
			
		||||
@@ -5,8 +5,6 @@
 | 
			
		||||
#ifndef SOURCE_DESTRUCTIONPOWER_PROPERTIES_H
 | 
			
		||||
#define SOURCE_DESTRUCTIONPOWER_PROPERTIES_H
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#include <stdint.h>
 | 
			
		||||
#include "DestructionPower.h"
 | 
			
		||||
 | 
			
		||||
@@ -15,21 +13,35 @@ class DestructionPower_Properties
 | 
			
		||||
public:
 | 
			
		||||
    DestructionPower_Properties()
 | 
			
		||||
    {
 | 
			
		||||
        for(int i=0;i<DestructionArray.size();i++)
 | 
			
		||||
            DestructionArray[i]=(map[i]*DESTRUCTION_INIT);
 | 
			
		||||
        for(int i=0;i<sizeof(DestructionArray);i++)
 | 
			
		||||
            DestructionArray[i]=(SpeedTable[i]*DESTRUCTION_INIT);
 | 
			
		||||
 | 
			
		||||
        setSpeedTable();
 | 
			
		||||
 | 
			
		||||
    }
 | 
			
		||||
    map<int,float> getSpeedTable()
 | 
			
		||||
    {
 | 
			
		||||
        return SpeedTable;
 | 
			
		||||
    }
 | 
			
		||||
    void setSpeedTable()
 | 
			
		||||
    { SpeedTable=create_SpeedTable();}
 | 
			
		||||
 | 
			
		||||
private:
 | 
			
		||||
 | 
			
		||||
    static map<int,float> create_SpeedTable();
 | 
			
		||||
    static map<int,float> SpeedTable;
 | 
			
		||||
 | 
			
		||||
    float DestructionArray[DESTRUCTION_COUNT];
 | 
			
		||||
    static map<int,float> SpeedTable = create_SpeedTable;
 | 
			
		||||
 | 
			
		||||
    friend class DestructionPower;
 | 
			
		||||
 | 
			
		||||
    static map<int,float> create_SpeedTable(){
 | 
			
		||||
        map<int, float> m;
 | 
			
		||||
        m[1] = 0.001;
 | 
			
		||||
        return m;
 | 
			
		||||
    }
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
map<int,float> DestructionPower_Properties::create_SpeedTable()
 | 
			
		||||
{
 | 
			
		||||
    map<int, float> m;
 | 
			
		||||
    m[1] = 0.001;
 | 
			
		||||
    return m;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
#endif //SOURCE_ABSTRACTIONLAYER_1_PROPERTIES_H
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user