Skip to content

Commit

Permalink
Merge pull request #2332 from ivan-mogilko/362--gamestateiface
Browse files Browse the repository at this point in the history
Implement "Game State" interface and several implementations
  • Loading branch information
ivan-mogilko authored Mar 3, 2024
2 parents 2e5ac6d + 7e777b6 commit 25ca925
Show file tree
Hide file tree
Showing 56 changed files with 1,197 additions and 880 deletions.
15 changes: 9 additions & 6 deletions Common/ac/gamestructdefines.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,15 @@
#define PORTRAIT_XPOSITION 3

// Room transition style
#define FADE_NORMAL 0
#define FADE_INSTANT 1
#define FADE_DISSOLVE 2
#define FADE_BOXOUT 3
#define FADE_CROSSFADE 4
#define FADE_LAST 4 // this should equal the last one
enum ScreenTransitionStyle
{
kScrTran_Fade = 0,
kScrTran_Instant = 1,
kScrTran_Dissolve = 2,
kScrTran_Boxout = 3,
kScrTran_Crossfade = 4,
kNumScrTransitions
};

// Legacy font flags
//#define FFLG_LEGACY_NOSCALE 0x01 // TODO: is this from legacy format, ever used?
Expand Down
1 change: 0 additions & 1 deletion Engine/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,6 @@ target_sources(engine
ac/textbox.h
ac/timer.cpp
ac/timer.h
ac/topbarsettings.h
ac/translation.cpp
ac/translation.h
ac/viewframe.cpp
Expand Down
1 change: 0 additions & 1 deletion Engine/ac/audiochannel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
using namespace AGS::Common;

extern GameSetupStruct game;
extern GameState play;
extern RoomStruct thisroom;
extern CCAudioClip ccDynamicAudioClip;

Expand Down
2 changes: 1 addition & 1 deletion Engine/ac/character.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2886,7 +2886,7 @@ void _displayspeech(const char*texx, int aschar, int xx, int yy, int widd, int i
char_thinking = aschar;

set_our_eip(155);
display_main(tdxp, tdyp, bwidth, texx, DISPLAYTEXT_SPEECH, FONT_SPEECH, textcol, isThought, allowShrink, overlayPositionFixed);
display_main(tdxp, tdyp, bwidth, texx, nullptr, DISPLAYTEXT_SPEECH, FONT_SPEECH, textcol, isThought, allowShrink, overlayPositionFixed);
set_our_eip(156);
if ((play.in_conversation > 0) && (game.options[OPT_SPEECHTYPE] == 3))
closeupface = nullptr;
Expand Down
1 change: 0 additions & 1 deletion Engine/ac/characterinfo_engine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ using namespace AGS::Common;
extern std::vector<ViewStruct> views;
extern GameSetupStruct game;
extern int displayed_room;
extern GameState play;
extern int char_speaking;
extern RoomStruct thisroom;
extern unsigned int loopcounter;
Expand Down
Loading

0 comments on commit 25ca925

Please sign in to comment.