Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into augustus-master
Browse files Browse the repository at this point in the history
  • Loading branch information
crudelios committed Mar 10, 2021
2 parents fe833c2 + 7597e7d commit a91c86a
Show file tree
Hide file tree
Showing 6 changed files with 38 additions and 31 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@ Then you can either copy the game to the Caesar 3 folder, or run the game from a
folder, in which case the game will ask you to point to the Caesar 3 folder.

Note that you must have permission to write in the game data directory as the saves will be
stored there.
stored there. Also, your game must be patched to 1.0.1.0 to use Julius. If Julius tells you that
you are missing it, you can [download the update here](https://github.com/bvschaik/julius/wiki/Patches).

See [Running Julius](https://github.com/bvschaik/julius/wiki/Running-Julius) for further instructions and startup options.

Expand Down
2 changes: 1 addition & 1 deletion src/building/house_evolution.c
Original file line number Diff line number Diff line change
Expand Up @@ -606,7 +606,7 @@ void building_house_determine_evolve_text(building *house, int worst_desirabilit
return;
}
// food types
int foodtypes_required = model->food;
int foodtypes_required = model->food_types;
int foodtypes_available = 0;
for (int i = INVENTORY_MIN_FOOD; i < INVENTORY_MAX_FOOD; i++) {
if (house->data.house.inventory[i]) {
Expand Down
2 changes: 1 addition & 1 deletion src/building/model.c
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ int model_load(void)
ptr = get_value(ptr, end_ptr, &houses[i].water);
ptr = get_value(ptr, end_ptr, &houses[i].religion);
ptr = get_value(ptr, end_ptr, &houses[i].education);
ptr = get_value(ptr, end_ptr, &houses[i].food);
ptr = get_value(ptr, end_ptr, &dummy);
ptr = get_value(ptr, end_ptr, &houses[i].barber);
ptr = get_value(ptr, end_ptr, &houses[i].bathhouse);
ptr = get_value(ptr, end_ptr, &houses[i].health);
Expand Down
1 change: 0 additions & 1 deletion src/building/model.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ typedef struct {
int religion; /**< Number of gods required */
int education; /**< Education required:
1 = school or library, 2 = school and library, 3 = school, library and academy */
int food; /**< Food required (boolean) */
int barber; /**< Barber required (boolean) */
int bathhouse; /**< Bathhouse required (boolean) */
int health; /**< Health required: 1 = doctor or hospital, 2 = doctor and hospital */
Expand Down
21 changes: 14 additions & 7 deletions src/platform/augustus.c
Original file line number Diff line number Diff line change
Expand Up @@ -479,13 +479,20 @@ static int pre_init(const char *custom_data_dir)
}
user_dir = ask_for_data_dir(1);
}
#else
SDL_ShowSimpleMessageBox(SDL_MESSAGEBOX_ERROR,
"Augustus requires the original files from Caesar 3 to run.",
"Move the Augustus executable to the directory containing an existing "
"Caesar 3 installation, or run:\naugustus path-to-c3-directory",
NULL);
#endif
#elif defined(__vita__)
SDL_ShowSimpleMessageBox(SDL_MESSAGEBOX_ERROR,
"Error",
"Augustus requires the original files from Caesar 3 to run.\n\n"
"Please add the files to:\n\n"
VITA_PATH_PREFIX,
NULL);
#else
SDL_ShowSimpleMessageBox(SDL_MESSAGEBOX_ERROR,
"Augustus requires the original files from Caesar 3 to run.",
"Move the Augustus executable to the directory containing an existing "
"Caesar 3 installation, or run:\naugustus path-to-c3-directory",
NULL);
#endif

return 0;
}
Expand Down
40 changes: 20 additions & 20 deletions test/stub/model.c
Original file line number Diff line number Diff line change
Expand Up @@ -133,26 +133,26 @@ static model_building buildings[] = {
{0, 0, 0, 0, 0, 0},
};
static model_house houses[] = {
{-99, -10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 1},
{-12, -5, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 1},
{-7, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 15, 9, 1},
{-2, 4, 0, 1, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 20, 11, 1},
{2, 8, 0, 2, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 25, 13, 2},
{6, 12, 10, 2, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 30, 15, 2},
{10, 16, 10, 2, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 35, 17, 2},
{14, 20, 10, 2, 1, 1, 1, 0, 1, 0, 1, 1, 0, 0, 0, 45, 19, 2},
{18, 25, 25, 2, 1, 1, 1, 0, 1, 0, 1, 1, 0, 0, 0, 50, 19, 3},
{22, 32, 25, 2, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 0, 58, 20, 3},
{29, 40, 25, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 0, 65, 84, 3},
{37, 48, 35, 2, 1, 2, 1, 1, 1, 1, 2, 1, 1, 1, 0, 80, 84, 4},
{45, 53, 35, 2, 2, 2, 1, 1, 1, 1, 2, 1, 1, 1, 1, 150, 40, 9},
{50, 58, 40, 2, 2, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 180, 42, 10},
{55, 63, 45, 2, 2, 3, 1, 1, 1, 2, 2, 1, 1, 1, 1, 400, 90, 11},
{60, 68, 50, 2, 3, 3, 1, 1, 1, 2, 3, 1, 1, 1, 1, 600, 100, 11},
{65, 74, 55, 2, 3, 3, 1, 1, 1, 2, 3, 1, 1, 1, 2, 700, 106, 12},
{70, 80, 60, 2, 4, 3, 1, 1, 1, 2, 3, 1, 1, 1, 2, 900, 112, 12},
{76, 90, 70, 2, 4, 3, 1, 1, 1, 2, 3, 1, 1, 1, 2, 1500, 190, 15},
{85, 100, 80, 2, 4, 3, 1, 1, 1, 2, 3, 1, 1, 1, 2, 1750, 200, 16},
{-99, -10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 1},
{-12, -5, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 1},
{-7, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 15, 9, 1},
{-2, 4, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 20, 11, 1},
{2, 8, 0, 2, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 25, 13, 2},
{6, 12, 10, 2, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 30, 15, 2},
{10, 16, 10, 2, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 35, 17, 2},
{14, 20, 10, 2, 1, 1, 0, 1, 0, 1, 1, 0, 0, 0, 45, 19, 2},
{18, 25, 25, 2, 1, 1, 0, 1, 0, 1, 1, 0, 0, 0, 50, 19, 3},
{22, 32, 25, 2, 1, 1, 0, 1, 1, 1, 1, 0, 1, 0, 58, 20, 3},
{29, 40, 25, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 0, 65, 84, 3},
{37, 48, 35, 2, 1, 2, 1, 1, 1, 2, 1, 1, 1, 0, 80, 84, 4},
{45, 53, 35, 2, 2, 2, 1, 1, 1, 2, 1, 1, 1, 1, 150, 40, 9},
{50, 58, 40, 2, 2, 2, 1, 1, 2, 2, 1, 1, 1, 1, 180, 42, 10},
{55, 63, 45, 2, 2, 3, 1, 1, 2, 2, 1, 1, 1, 1, 400, 90, 11},
{60, 68, 50, 2, 3, 3, 1, 1, 2, 3, 1, 1, 1, 1, 600, 100, 11},
{65, 74, 55, 2, 3, 3, 1, 1, 2, 3, 1, 1, 1, 2, 700, 106, 12},
{70, 80, 60, 2, 4, 3, 1, 1, 2, 3, 1, 1, 1, 2, 900, 112, 12},
{76, 90, 70, 2, 4, 3, 1, 1, 2, 3, 1, 1, 1, 2, 1500, 190, 15},
{85, 100, 80, 2, 4, 3, 1, 1, 2, 3, 1, 1, 1, 2, 1750, 200, 16},
};

int model_load(void)
Expand Down

0 comments on commit a91c86a

Please sign in to comment.