Difference between revisions of "SCI/TODO"

Jump to navigation Jump to search
393 bytes removed ,  01:59, 24 February 2009
no edit summary
Line 1: Line 1:
The following list is taken from Max's mails to -devel:
The following list is taken from Max's mails to -devel:
* Replace all uses of gint8, etc. by our native types, to get rid of the typedefs we use right now.
* Replace all uses of gint8, etc. by our native types, to get rid of the typedefs we use right now.
* check for places that use char or unsigned char for boolean values, and change those to use enum types whose value names express the intention (SearchOptions.RECURSIVE, GraphicsScaleOptions.2X, etc)
* check for places that use char or unsigned char for boolean values, and change those to bool. Even nicer would be to change it to use enum types whose value names express the intention (SearchOptions.RECURSIVE, GraphicsScaleOptions.2X, etc), but just going for bool will already be a big improvement.
* more formatting fixes: The SCI code puts return values on separate lines all over the place, e.g.
* more formatting fixes: The SCI code puts return values on separate lines all over the place, e.g.


Line 11: Line 11:
Take care of that and other formatting issues.
Take care of that and other formatting issues.


* change names of structs and how they are declare, e.g.
<syntax type="C++">
  typedef struct script_opcode_ {
      unsigned opcode;
      int arg1, arg2, arg3;
      int pos, size;
  } script_opcode;
</syntax>
->
<syntax type="C++">
  struct ScriptOpcode {
      unsigned opcode;
      int arg1, arg2, arg3;
      int pos, size;
  };
</syntax>
* Fixing all warnings
* change #define lists into enums
* change #define lists into enums
* Rearranging the files under engines/sci: I.e. get rid of include/ subdir (just move its contents to engines/sci, at some point at least)
* Rearranging the files under engines/sci: I.e. get rid of include/ subdir (just move its contents to engines/sci, at some point at least)
* Converting stuff from "C pseudo classes" to real classes
* Converting stuff from "C pseudo classes" to real classes
* Replacing various generic FreeSCI stuff by their ScummVM counterparts. E.g. don't bother to rewrite engines/sci/include/int_hashmap.h -- instead change code to use a HashMap<int, ...> etc.
* Replacing various generic FreeSCI stuff by their ScummVM counterparts.  
* Replace sci_gettime and sci_get_current_time by OSystem::getTimeAndDate and OSystem::getMillis
* Replace sci_gettime and sci_get_current_time by OSystem::getTimeAndDate and OSystem::getMillis
# You first need to find out which is used where: Des the code try to determine the current time? Use getTimeAndDate(). Does it try to measure something, regulate timing? Using getMillis. It is possible that some code actually really wants to get a higher resolution than milli seconds, in that case get back to us and let's discuss what to do.
# You first need to find out which is used where: Des the code try to determine the current time? Use getTimeAndDate(). Does it try to measure something, regulate timing? Using getMillis. It is possible that some code actually really wants to get a higher resolution than milli seconds, in that case get back to us and let's discuss what to do.
1,079

edits

Navigation menu