Ticket #2690: flashlight.diff

File flashlight.diff, 1.4 KB (added by eriktorbjorn, 18 years ago)

Possible patch against current SVN

  • engines/scumm/intern.h

     
    8888        void redefineBuiltinCursorFromChar(int index, int chr);
    8989        void redefineBuiltinCursorHotspot(int index, int x, int y);
    9090
     91        virtual void clearFlashlight();
    9192        void drawFlashlight();
    9293
    9394        /* Version 5 script opcodes */
  • engines/scumm/gfx.cpp

     
    253253        int i;
    254254        int adj = 0;
    255255
     256        clearFlashlight();
     257
    256258        for (i = 0; i < 3; i++) {
    257259                res.nukeResource(rtBuffer, i + 1);
    258260                res.nukeResource(rtBuffer, i + 5);
     
    10891091        }
    10901092}
    10911093
     1094void ScummEngine_v5::clearFlashlight() {
     1095        _flashlight.isDrawn = false;
     1096        _flashlight.buffer = NULL;
     1097}
     1098
    10921099void ScummEngine_v5::drawFlashlight() {
    10931100        int i, j, x, y;
    10941101        VirtScreen *vs = &virtscr[kMainVirtScreen];
  • engines/scumm/scumm.h

     
    496496        virtual void animateCursor() {}
    497497        virtual void updatePalette();
    498498
     499        virtual void clearFlashlight() {}
     500
    499501        /**
    500502         * Flag which signals that the SMUSH video playback should end now
    501503         * (e.g. because it was aborted by the user or it's simply finished).