Skip to content

Commit

Permalink
HOPKINS: Implemented some more of the object/sprite methods
Browse files Browse the repository at this point in the history
  • Loading branch information
dreammaster committed Sep 23, 2012
1 parent 3fcff82 commit c9f904b
Show file tree
Hide file tree
Showing 4 changed files with 386 additions and 11 deletions.
6 changes: 3 additions & 3 deletions engines/hopkins/globals.cpp
Expand Up @@ -217,7 +217,7 @@ void Globals::clearAll() {
inventaire2 = PTRNUL;
COUCOU = PTRNUL;
SPRITE_ECRAN = PTRNUL;
SAUVEGARDE = PTRNUL;
SAUVEGARDE = (Sauvegarde *)PTRNUL;
OBJET_EN_COURS = 0;

for (int idx = 0; idx < 105; ++idx) {
Expand Down Expand Up @@ -253,8 +253,8 @@ void Globals::clearAll() {
texte_tmp = PTRNUL;
BUFFERTAPE = dos_malloc2(85000);

SAUVEGARDE = dos_malloc2(2050);
memset(SAUVEGARDE, 0, 1999);
SAUVEGARDE = (Sauvegarde *)malloc(sizeof(Sauvegarde));
memset(SAUVEGARDE, 0, sizeof(Sauvegarde));

essai0 = BUFFERTAPE;
essai1 = BUFFERTAPE + 25000;
Expand Down
29 changes: 28 additions & 1 deletion engines/hopkins/globals.h
Expand Up @@ -103,7 +103,13 @@ struct BobItem {
int field36;
int field38;
int field3A;
int field3E;
int field40;
int field42;
int field44;
int field46;
int field48;
int field4A;
};

struct Liste2Item {
Expand Down Expand Up @@ -156,6 +162,26 @@ struct TriItem {
int field6;
};

struct CacheItem {
int field0;
int field2;
int field4;
int field6;
int field8;
int fieldA;
int field10;
int field14;
};

// Note: Fields decimal based for now
struct Sauvegarde {
int field353;
int field354;
int field355;
int field356;
int field357;
};

class HopkinsEngine;

/**
Expand Down Expand Up @@ -223,12 +249,13 @@ class Globals {
ObjetWItem ObjetW[300];
BlocItem BLOC[250];
ListeItem Liste[7];
CacheItem Cache[25];
byte *Winventaire;
byte *texte_tmp;
int texte_long;
int TEXTE_FORMATE;
byte *SPRITE_ECRAN;
byte *SAUVEGARDE;
Sauvegarde *SAUVEGARDE;
byte *BUFFERTAPE;
byte *essai0;
byte *essai1;
Expand Down

0 comments on commit c9f904b

Please sign in to comment.