Deeangbandのフルスクラッチ新ソースコード。
BSD系ライセンスを採用予定。
Revision | 4af6efbadb2570e7cb21384292556602f8ea0a17 (tree) |
---|---|
Time | 2015-02-26 23:31:51 |
Author | Deskull <desull@user...> |
Commiter | Deskull |
不要な描画処理をコメントアウト / Comment out unnecessary processing for drawing.
@@ -207,7 +207,7 @@ namespace Deeangband | ||
207 | 207 | SDL_FreeSurface(symbolSurface); |
208 | 208 | |
209 | 209 | floorTextures.insert(std::map<TAG, SDL_Texture*>::value_type(floorIt->first, SDL_CreateTextureFromSurface(renderer, surface))); |
210 | - } | |
210 | + } | |
211 | 211 | |
212 | 212 | SDL_GetWindowSurface(this->window); |
213 | 213 | this->windowSurface = SDL_GetWindowSurface(this->window); |
@@ -602,7 +602,7 @@ void GameSurfaceSDL::drawField(const CREATURE_IT &subjectCreatureIt, GameWorld * | ||
602 | 602 | SDL_Rect symbolRect = {0, 0, squareGraphicWidth, squareGraphicHeight}; |
603 | 603 | CREATURE_IT creatureIt; |
604 | 604 | Creature *subJectCreaturePtr = subjectCreatureIt->second.get(); |
605 | - | |
605 | + | |
606 | 606 | MAP_LENGTH fx = this->focusPoint.GetX(); |
607 | 607 | MAP_LENGTH fy = this->focusPoint.GetY(); |
608 | 608 |
@@ -635,10 +635,12 @@ void GameSurfaceSDL::drawField(const CREATURE_IT &subjectCreatureIt, GameWorld * | ||
635 | 635 | { |
636 | 636 | SDL_Rect blitRect = {(px - x) * squareGraphicWidth - sx, (py - y) * squareGraphicHeight - sy, squareGraphicWidth, squareGraphicHeight}; |
637 | 637 | |
638 | + /* | |
638 | 639 | SDL_Rect checkRect1 = {(px - x) * squareGraphicWidth - sx - 2 + 12, 30 + (py - y) * squareGraphicHeight - 2 - sy + 12, 4, 4}; |
639 | 640 | SDL_Rect checkRect2 = {(px - x) * squareGraphicWidth - sx - 2, 30 + (py - y) * squareGraphicHeight - 2 - sy , 4, 4}; |
640 | 641 | SDL_Rect checkRect3 = {(px - x) * squareGraphicWidth - sx - 6 + 12, 30 + (py - y) * squareGraphicHeight - 1 - sy , 12, 2}; |
641 | 642 | SDL_Rect checkRect4 = {(px - x) * squareGraphicWidth - sx - 1, 30 + (py - y) * squareGraphicHeight - 6 + 12 - sy , 2, 12}; |
643 | + */ | |
642 | 644 | |
643 | 645 | if(subJectCreaturePtr->InSight(px, py)) |
644 | 646 | { |
@@ -661,7 +663,6 @@ void GameSurfaceSDL::drawField(const CREATURE_IT &subjectCreatureIt, GameWorld * | ||
661 | 663 | SDL_SetRenderDrawColor(this->renderer, 255, 255, 255, 255); |
662 | 664 | else |
663 | 665 | SDL_SetRenderDrawColor(this->renderer, 255, 0, 0, 255); |
664 | - */ | |
665 | 666 | SDL_RenderFillRect(this->renderer, &checkRect1); |
666 | 667 | |
667 | 668 | if(fieldPtr->GetSightPass(px * 2, py * 2)) |
@@ -678,6 +679,8 @@ void GameSurfaceSDL::drawField(const CREATURE_IT &subjectCreatureIt, GameWorld * | ||
678 | 679 | SDL_FillRect(windowSurface, &checkRect4, SDL_MapRGBA(windowSurface->format, 255, 255, 255, 255)); |
679 | 680 | else |
680 | 681 | SDL_FillRect(windowSurface, &checkRect4, SDL_MapRGBA(windowSurface->format, 255, 0, 0, 255)); |
682 | + */ | |
683 | + | |
681 | 684 | } |
682 | 685 | } |
683 | 686 | } |
@@ -722,8 +725,6 @@ void GameSurfaceSDL::drawField(const CREATURE_IT &subjectCreatureIt, GameWorld * | ||
722 | 725 | { |
723 | 726 | SDL_Rect messageRect = {0, 0, 200, 200}; |
724 | 727 | SDL_Rect messagePositon = {220, 180, 420, 380}; |
725 | - //SDL_Rect windowRect = {210, 170, 420, 220}; | |
726 | - //SDL_FillRect(windowSurface, &windowRect, SDL_MapRGBA(systemMessageSurface->format, 0, 0, 0, 120)); | |
727 | 728 | SDL_RenderCopy(renderer, systemMessageTexture, &messageRect, &messagePositon); |
728 | 729 | } |
729 | 730 |