]> code.bitgloo.com Git - clyne/gamedev.git/commitdiff
Merge branch 'master' of http://github.com/tcsullivan/gamedev
authordrumsetmonkey <abelleisle@roadrunner.com>
Fri, 4 Mar 2016 12:31:12 +0000 (07:31 -0500)
committerdrumsetmonkey <abelleisle@roadrunner.com>
Fri, 4 Mar 2016 12:31:12 +0000 (07:31 -0500)
1  2 
include/entities.h
src/entities.cpp
src/world.cpp

Simple merge
Simple merge
diff --cc src/world.cpp
index 32a3153a58c3adbe6e633a0ddb7df9fa25931262,bef6fc0d191932b6e1158cb70bc38e42857c1b16..e4ce1fd21f67bfeef175bdf75866d2e0619b19ce
@@@ -1467,20 -1434,13 +1435,20 @@@ loadWorldFromXMLNoSave( std::string pat
                                                           vil->QueryFloatAttribute("x", &spawnx) != XML_NO_ERROR ? 
                                                           randx : spawnx,
                                                           100,
-                                                          (char*)vil->Attribute("texture"),
-                                                          ptr);
+                                                          vil->StrAttribute("texture"),
+                                                          vil->StrAttribute("inside"));
                                tmp->addMerchant(0,100);
 -                              if(!strcmp(name,"buy")){
 -                                      std::cout << "Buying";
 -                              }else if(!strcmp(name,"sell")){
 -                                      std::cout << "Selling";
 +                              if(vil->FirstChildElement("buy")){
 +                                      std::cout << "Buy" << std::endl;
 +                                      /*bs.member = 0;
 +                                      bs.cost.type = 0;
 +                                      bs.cost.item = vil->FirstChildElement("buy")->Attribute("item");
 +                                      bs.cost.price =vil->FirstChildElement("buy")->IntAttribute("cost");*/
 +                                      tmp->merchant.back()->bsinv.push_back({0,"Dank MayMay",420});
 +                              }if(vil->FirstChildElement("sell")){
 +                                      std::cout << "Sell" << std::endl;
 +                              }if(vil->FirstChildElement("trade")){
 +                                      std::cout << "Trade" << std::endl;
                                }
                                strcpy(tmp->merchant.back()->name,"meme");