UpdateZoneSafeCoords converted to xyz_heading

This commit is contained in:
Arthur Ice 2014-12-02 16:42:19 -08:00
parent 275f2aa80f
commit cafa266c89
2 changed files with 4 additions and 3 deletions

View File

@ -2471,10 +2471,11 @@ void ZoneDatabase::DeleteMerchantTemp(uint32 npcid, uint32 slot){
}
bool ZoneDatabase::UpdateZoneSafeCoords(const char* zonename, float x=0, float y=0, float z=0) {
bool ZoneDatabase::UpdateZoneSafeCoords(const char* zonename, const xyz_location& location) {
std::string query = StringFormat("UPDATE zone SET safe_x='%f', safe_y='%f', safe_z='%f' "
"WHERE short_name='%s';", x, y, z, zonename);
"WHERE short_name='%s';",
location.m_X, location.m_Y, location.m_Z, zonename);
auto results = QueryDatabase(query);
if (!results.Success() || results.RowsAffected() == 0)
return false;

View File

@ -345,7 +345,7 @@ public:
bool GetZoneCFG(uint32 zoneid, uint16 instance_id, NewZone_Struct *data, bool &can_bind, bool &can_combat, bool &can_levitate, bool &can_castoutdoor, bool &is_city, bool &is_hotzone, bool &allow_mercs, uint8 &zone_type, int &ruleset, char **map_filename);
bool SaveZoneCFG(uint32 zoneid, uint16 instance_id, NewZone_Struct* zd);
bool LoadStaticZonePoints(LinkedList<ZonePoint*>* zone_point_list,const char* zonename, uint32 version);
bool UpdateZoneSafeCoords(const char* zonename, float x, float y, float z);
bool UpdateZoneSafeCoords(const char* zonename, const xyz_location& location);
uint8 GetUseCFGSafeCoords();
int getZoneShutDownDelay(uint32 zoneID, uint32 version);