Skip to content

Commit

Permalink
Fix some style issues
Browse files Browse the repository at this point in the history
  • Loading branch information
billy1arm committed Aug 21, 2024
1 parent 362b314 commit 4c31e76
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/game/Object/CreatureEventAIMgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1042,7 +1042,7 @@ void CreatureEventAIMgr::LoadCreatureEventAI_Scripts()
}
break;

case ACTION_T_SUMMON_UNIQUE: //47
case ACTION_T_SUMMON_UNIQUE: //49
if (!sCreatureStorage.LookupEntry<CreatureInfo>(action.summon_unique.creatureId))
{
sLog.outErrorEventAI("Event %u Action %u uses nonexistent creature entry %u.", i, j + 1, action.summon_unique.creatureId);
Expand Down
2 changes: 2 additions & 0 deletions src/game/Object/Object.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1755,7 +1755,9 @@ void WorldObject::SetMap(Map* map)

#ifdef ENABLE_ELUNA
if (!elunaEvents)
{
elunaEvents = new ElunaEventProcessor(&Eluna::GEluna, this);
}
#endif
}

Expand Down
2 changes: 2 additions & 0 deletions src/game/Object/Player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2913,7 +2913,9 @@ void Player::SetLevel(uint32 level)
{
uint8 oldLevel = getLevel();
if (level == oldLevel || level > DEFAULT_MAX_LEVEL)
{
return;
}

SetUInt32Value(UNIT_FIELD_LEVEL, level);
SetUInt32Value(PLAYER_XP, 0);
Expand Down
2 changes: 2 additions & 0 deletions src/game/WorldHandlers/MiscHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1484,7 +1484,9 @@ void WorldSession::SetMoneyHandler(WorldPacket &msg)

msg >> money;
if (money < 0)
{
money = 0x7FFFFFFF; /* Money limit */
}

DEBUG_LOG("Setting money on %s from %d to %d", pPlayer->GetName(), pPlayer->GetMoney(), money); /*TODO: Log this appropriately*/
GetPlayer()->SetMoney(money);
Expand Down
2 changes: 2 additions & 0 deletions src/shared/Utilities/Util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,9 @@ size_t utf8limit(std::string& utf8str, size_t bytes)

// Fix UTF8 if it was corrupted by bytes truncated
if (itr != end)
{
bytes = std::distance(utf8str.cbegin(), itr);
}

utf8str.resize(bytes);
utf8str.shrink_to_fit();
Expand Down
6 changes: 3 additions & 3 deletions src/tools/Extractor_Binaries/MoveMapGen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ MAP_LIST_A="1 37 543 595 289 572 529 562 531 269 47 649 650 599 548 559 429 230
MAP_LIST_B="571 628 560 509 723 532 607 600 668 33 585 566 389 601 369 129 550 189 542 70 109 554 632 552 555 540 598 450 558 249 35 624 557"
MAP_LIST_C="0 631 609 534 533 619 469 602 329 580 615 578 36 556 44 565 544 34 617 608 618 449 616 42 451 582 584 586 587 588 589 590 591 592"
MAP_LIST_D="530 169 575 603 309 574 30 564 568 209 724 658 489 593 594 596 597 605 606 610 612 613 614 620 621 622 623 641 642 647 672 673 712 713 718"
MAP_LIST_D1="209 724 658 489 606 610 612 613 614 620 621"
MAP_LIST_D2="169 575 603 309 574 30 564 568 622 623 641 642 647 672 673 712 713 718"
MAP_LIST_D3="530 593 594 596 597 605"
MAP_LIST_D1="209 724 658 489 606 610 612 613 614 620 621 725 726 727 728 730 731 755 757 759 760 761 762 861 930 938 939 940 951"
MAP_LIST_D2="169 575 603 309 574 30 564 568 622 623 641 642 647 672 673 712 713 718 763 764 765 766 767 859 967 968 974 977 980"
MAP_LIST_D3="530 593 594 596 597 605 732 734 736 738 739 740 741 742 743 746 747 748 749 750 751 752 753 754"

badParam()
{
Expand Down
2 changes: 1 addition & 1 deletion src/tools/Extractor_Binaries/mmap_extract.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def run(self):
cFlags = 0
binName = "./mmap-extractor"
if self.mapID == 0:
retcode = subprocess.call([binName, "%u" % (self.mapID), "--silent", "--offMeshInput", "offmesh.txt"], startupinfo=stInfo, creationflags=cFlags)
retcode = subprocess.call([binName, "%u" % (self.mapID), "--silent", "--offMeshInput", "offmesh.txt"], startupinfo=stInfo, creationflags=cFlags)
else:
retcode = subprocess.call([binName, "%u" % (self.mapID), "--silent"], startupinfo=stInfo, creationflags=cFlags)
print "-- %s" % (name)
Expand Down

0 comments on commit 4c31e76

Please sign in to comment.