This is the weirdest bug I have gotten yet. Its late, and I can't figure out why this is not working....I thought I had the constructor set up right. I am sorry that I am asking for so much help, but I have learned a LOT in these past few days as well :) Learning all these new pieces of code that can be used to help manipulate data :D
1>AoE2Wide.cpp(323): error C2440: 'initializing' : cannot convert from 'int' to 'AoE2Wide::Item *'
1> Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
1>AoE2Wide.cpp(323): error C2078: too many initializers
class Item
{
public:
int Pos;
int ReferenceValue;
std::string Type;
int Parameter;
std::string Comments;
std::string Asm;
int OriginalPos;
Item(int p, int rf, std::string tp, std::string cm)
{
Pos = p;
ReferenceValue = rf;
Type = tp;
Comments = cm;
}
};
int rf = atoi(tokens2.at(1).c_str()); // this is supposed to convert it to an int
int Pos;
sscanf_s(tokens2.at(0).c_str(), "%x", &Pos); // supposed to convert to an int
auto item = new AoE2Wide::Item{Pos, rf, "", ""};