Skip to content

AmigaOS4 support #10

Description

@raziel-

Hi Eric,

not sure if you want to, since it probably means some sort of adaptation/rewriting, but...

I tried to port your engine to AmigaOS4, but ran into some problems.

First there were compilation issues (since cmake doesn´t work on my platform, so i had to write my own makefile (attached). Luckily your cmake file is very clean and easy to adapt):

src/player.h:5:14: error: 'sint16' does not name a type; did you mean 'int'?
extern const sint16 player_x_offset_tbl[];
^~~~~~
int
src/player.h:6:14: error: 'sint16' does not name a type; did you mean 'int'?
extern const sint16 player_y_offset_tbl[];
^~~~~~
int
src/player.h:29:8: error: 'uint8' does not name a type; did you mean 'int'?
extern uint8 health;
^~~~~
int
src/player.h:30:8: error: 'uint8' does not name a type; did you mean 'int'?
extern uint8 num_health_bars;
^~~~~
int
src/player.h:32:8: error: 'uint16' does not name a type; did you mean 'int'?
extern uint16 num_bombs;
^~~~~~
int
src/player.h:33:8: error: 'uint16' does not name a type; did you mean 'int'?
extern uint16 has_had_bomb_flag;
^~~~~~
int
src/player.h:39:8: error: 'uint8' does not name a type; did you mean 'int'?
extern uint8 player_in_pneumatic_tube_flag;
^~~~~
int
src/player.h:46:8: error: 'uint8' does not name a type; did you mean 'int'?
extern uint8 show_monster_attack_hint;
^~~~~
int
src/player.h:48:8: error: 'uint8' does not name a type; did you mean 'int'?
extern uint8 word_28BEA;
^~~~~
int
src/player.h:73:28: error: variable or field 'display_player_sprite' declared void
void display_player_sprite(uint8 frame_num, int x_pos, int y_pos, int tile_display_func_index);
^~~~~
src/player.h:73:28: error: 'uint8' was not declared in this scope
src/player.h:73:28: note: suggested alternative: 'int'
void display_player_sprite(uint8 frame_num, int x_pos, int y_pos, int tile_display_func_index);
^~~~~
int
src/player.h:73:45: error: expected primary-expression before 'int'
void display_player_sprite(uint8 frame_num, int x_pos, int y_pos, int tile_display_func_index);
^~~
src/player.h:73:56: error: expected primary-expression before 'int'
void display_player_sprite(uint8 frame_num, int x_pos, int y_pos, int tile_display_func_index);
^~~
src/player.h:73:67: error: expected primary-expression before 'int'
void display_player_sprite(uint8 frame_num, int x_pos, int y_pos, int tile_display_func_index);
^~~
src/player.h:84:26: error: variable or field 'player_add_to_score' declared void
void player_add_to_score(uint32 amount_to_add_low);
^~~~~~
src/player.h:84:26: error: 'uint32' was not declared in this scope
src/player.h:84:26: note: suggested alternative: 'int'
void player_add_to_score(uint32 amount_to_add_low);
^~~~~~
int
src/player.h:88:110: error: 'uint8' has not been declared
void push_player_around(int push_direction, int push_anim_duration, int push_duration, int player_frame_num, uint8 dont_push_while_jumping_flag, int check_for_blocking_flag);

Those errors were was easily fixed by adding
#ifdef amigaos4
#include "files/defines.h"
#endif
to src/player.h, line 5

After the binary built i got more errors on start of the engine.
I cannot fix them by myself, too much of a noob i´m afraid, but i´d love to test anything you throw at me :-)

Here are the errors on start:

audio_init(): opened=1 times frequency=22050Hz format=S16MSB channel=1
ERROR: AUDIO_S16LSB or AUDIO_F32LSB required. found 0x9010
Failed opening: PROGDIR:/COSMO1.VOL
Error opening COSMO1.VOL
assertion "open_vol_file(vol_filename, &vol_file)" failed: file "src/files/vol.c", line 111
***Command 'cosmo_amigaos4' returned with unfreed signals 80000000!

I have to add that i´m using SDL2 on a Big Endian PPC-based machine

Makefile.amigaos4.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions