[Scummvm-devel] Dreamweb engine inclusion.
Vladimir Menshakov
whoozle at yandex.ru
Thu Jun 16 14:19:14 CEST 2011
16.06.2011, 15:24, "Max Horn" <max at quendi.de>:
> Hi again!
>
> I am glad to see that some of my suggestions were already implemented, and very quickly, too. I hope I'll also get replies to my questions then :).
The binary blob in the src is generated from the assembler source. If you insist, we could move it into .dat file, but I think that code for loading this fill will cost us the same kilos :)
Anyway I'd prefer to do it later than sooner, because it will require another step to run engine. (Copying .dat into place).
I could annotated it with printable character dump, as 'hexdump' does.
> And a fix for the implicit conversion warnings like
>
> engines/dreamweb/dreamgen.cpp: In function ‘void dreamgen::soldier1(dreamgen::Context&)’:
> engines/dreamweb/dreamgen.cpp:812: warning: negative integer implicitly converted to unsigned type
As you may see, I'm working on reducing warning's count. :)
>
> Next, he engine needs to be added to devtools/credits.pl (and then "make credits" should be run and all modifications checked in).
Done.
>
> I've been wondering whether the code wouldn't be at least a little bit more readable, if you added a "DreamContext" subclass of Context, and then made all functions that get a context, like
> void checkbasemem(Context &context)
> members of this new class
> void DreamContext::checkbasemem()
> This way, you could get rid of all 20306 occurrences of "context." in dreamgen.cpp", shrinking the file from 647k to 488k. And since we can then change calls like
> getunderzoom(context);
> to
> getunderzoom();
> we loose another 30k or so.
Yes, great idea. It's a shame I did not figure out this solution before :)
>
> There are still various code formatting issues. E.g.:
> while(context.cx--) context._stosw();
> This should be two line:
> while(context.cx--)
> context._stosw();
Ok, I've already added grouping for consequtive stos/movs commands, so I could simply pass cx into _stosb(cx); and replace all rep movs/stos instructions
> Similar for
> if (!flags.z()) goto ismorereel;
>
> Cheers,
> Max
> ------------------------------------------------------------------------------
> EditLive Enterprise is the world's most technically advanced content
> authoring tool. Experience the power of Track Changes, Inline Image
> Editing and ensure content is compliant with Accessibility Checking.
> http://p.sf.net/sfu/ephox-dev2dev
> _______________________________________________
> Scummvm-devel mailing list
> Scummvm-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/scummvm-devel
More information about the Scummvm-devel
mailing list