2,051
edits
Jestar jokin (talk | contribs) m (→ifClassOfIs ($1D): args is a standard arg list) |
m (behaviour -> behavior) |
||
(10 intermediate revisions by 2 users not shown) | |||
Line 8: | Line 8: | ||
|opcode||The instruction's opcode, with the appropriate bits set according to the parameters. | |opcode||The instruction's opcode, with the appropriate bits set according to the parameters. | ||
|- | |- | ||
|aux||An aux opcode that stores parameter bits and no other information. (the base aux opcode | |aux||An aux opcode that stores parameter bits and no other information. (the base aux opcode is usually $01, but can differ for each instruction) | ||
|- | |- | ||
|sub-opcode||An aux opcode that indicates a specific function to perform (e.g. the "wait" instruction has sub-opcodes to "wait for message", "wait for actor" etc), as well as storing parameter bits if necessary. | |sub-opcode||An aux opcode that indicates a specific function to perform (e.g. the "wait" instruction has sub-opcodes to "wait for message", "wait for actor" etc), as well as storing parameter bits if necessary. | ||
Line 14: | Line 14: | ||
|result||A result pointer. (A standard word pointer, always a LE word.) | |result||A result pointer. (A standard word pointer, always a LE word.) | ||
|- | |- | ||
|var||A | |var||A variable pointer. Same as above, but is not written to. Because this is always a variable, the opcode is not affected like it would be with a normal parameter (described below). | ||
|- | |- | ||
|value[8]||An 8-bit constant (a byte). | |value[8]||An 8-bit constant (a byte). | ||
Line 73: | Line 73: | ||
$0A | $0A | ||
$0B index[p8] value[p8] | $0B index[p8] value[p8] | ||
$0C | $0C color[p8] | ||
$0D name[c]... $00 | $0D name[c]... $00 | ||
$0E initframe[p8] | $0E initframe[p8] | ||
Line 81: | Line 81: | ||
$13 zplane[p8] | $13 zplane[p8] | ||
$14 | $14 | ||
$15 | $15 | ||
$16 | $16 animspeed[p8] | ||
$17 shadow[p8] | $17 shadow[p8] | ||
Line 114: | Line 114: | ||
|$0A||SO_ANIMATION_DEFAULT||Initializes the actor's animation frames.<br>Init frame = 1<br>Walk frame = 2<br>Stand frame = 3<br>Talk start frame = 4<br>Talk stop frame = 5 | |$0A||SO_ANIMATION_DEFAULT||Initializes the actor's animation frames.<br>Init frame = 1<br>Walk frame = 2<br>Stand frame = 3<br>Talk start frame = 4<br>Talk stop frame = 5 | ||
|- | |- | ||
|$0B||SO_PALETTE||Sets the | |$0B||SO_PALETTE||Sets the color at the given index to a new value (another entry in the color lookup table/CLUT). Index must be between 0 and 31 (the number of colors in a costume). | ||
|- | |- | ||
|$0C||SO_TALK_COLOR||Sets the actor's talk | |$0C||SO_TALK_COLOR||Sets the actor's talk color. | ||
|- | |- | ||
|$0D||SO_ACTOR_NAME||Sets the actor's name to the given null-terminated string. | |$0D||SO_ACTOR_NAME||Sets the actor's name to the given null-terminated string. | ||
Line 134: | Line 134: | ||
|$15||SO_FOLLOW_BOXES||Follows boxes, turns off Z-clipping, and puts actor somewhere if the actor is in the current room? | |$15||SO_FOLLOW_BOXES||Follows boxes, turns off Z-clipping, and puts actor somewhere if the actor is in the current room? | ||
|- | |- | ||
|$16||SO_ANIMATION_SPEED||Sets the | |$16||SO_ANIMATION_SPEED||Sets the animation speed. | ||
|- | |- | ||
|$17||SO_SHADOW||Sets the shadow mode. | |$17||SO_SHADOW||Sets the shadow mode. | ||
Line 140: | Line 140: | ||
===Variants=== | ===Variants=== | ||
In SCUMM V4, sub-opcode $ | In SCUMM V3 and V4, the opcode values are slightly different. | ||
{| border="1" cellpadding="2" width=50% | |||
|- style="background:whitesmoke" | |||
|Opcode||Meaning | |||
|- | |||
|$00||dummy | |||
|- | |||
|$01||SO_COSTUME | |||
|- | |||
|$04||SO_STEP_DIST | |||
|- | |||
|$05||SO_SOUND | |||
|- | |||
|$06||SO_WALK_ANIMATION | |||
|- | |||
|$07||SO_TALK_ANIMATION | |||
|- | |||
|$08||SO_STAND_ANIMATION | |||
|- | |||
|$09||SO_ANIMATION | |||
|- | |||
|$0A||SO_DEFAULT | |||
|- | |||
|$0B||SO_ELEVATION | |||
|- | |||
|$0C||SO_ANIMATION_DEFAULT | |||
|- | |||
|$0D||SO_PALETTE | |||
|- | |||
|$0E||SO_TALK_COLOR | |||
|- | |||
|$0F||SO_ACTOR_NAME | |||
|- | |||
|$10||SO_INIT_ANIMATION | |||
|- | |||
|$12||SO_ACTOR_WIDTH | |||
|- | |||
|$13||SO_ACTOR_SCALE | |||
|- | |||
|$14||SO_IGNORE_BOXES | |||
|} | |||
Also in V3 and V4, sub-opcode $13 (SO_ACTOR_SCALE) only takes one parameter, so X and Y scaling is done at a 1:1 ratio. | |||
Line 218: | Line 261: | ||
$0C cursor[p8] | $0C cursor[p8] | ||
$0D charset[p8] | $0D charset[p8] | ||
$0E | $0E colors[v16]... | ||
===Operation=== | ===Operation=== | ||
Line 251: | Line 294: | ||
|$0D||SO_CHARSET_SET||Initializes the given character set. | |$0D||SO_CHARSET_SET||Initializes the given character set. | ||
|- | |- | ||
|$0E||SO_CHARSET_COLORS||Initializes the character set data & | |$0E||SO_CHARSET_COLORS||Initializes the character set data & colors to the given arguments? Must have 16 arguments? | ||
|} | |} | ||
Line 336: | Line 379: | ||
===Encoding=== | ===Encoding=== | ||
opcode left[p16] top[p16] auxopcode[8] right[p16] bottom[p16] | opcode left[p16] top[p16] auxopcode[8] right[p16] bottom[p16] color[p8] | ||
===Operation=== | ===Operation=== | ||
Draws a solid box on the backbuffer from (left, top) | Draws a solid box on the backbuffer from (left, top) to (right, bottom) in the given color. | ||
The only part of auxopcode that is relevant are the parameter bits. The rest of the opcode is ignored. | The only part of auxopcode that is relevant are the parameter bits. The rest of the opcode is ignored. However, the aux opcode's initial value is $05. | ||
Line 352: | Line 395: | ||
$01 xpos[p16] ypos[p16] | $01 xpos[p16] ypos[p16] | ||
$02 state[p16] | $02 state[p16] | ||
$ | $FF | ||
===Operation=== | ===Operation=== | ||
Line 363: | Line 406: | ||
|$02||Set State||Sets the state of the object, adds it to the drawing queue. | |$02||Set State||Sets the state of the object, adds it to the drawing queue. | ||
|- | |- | ||
|$ | |$FF||Draw||Does not change the object's position (or state?), still adds it to the drawing queue. | ||
|} | |} | ||
===Variants=== | ===Variants=== | ||
Small header games only support the parameters used with sub-opcode $01, e.g: | Small header games (v3 and v4) only support the parameters used with sub-opcode $01, e.g: | ||
opcode object[p16] xpos[p16] ypos[p16] | opcode object[p16] xpos[p16] ypos[p16] | ||
Accordingly, they have three parameter bits, and hence more possible opcodes. | |||
Line 632: | Line 676: | ||
===Variants=== | ===Variants=== | ||
In small header games, the | In small header games, this opcode is used for the "ifState" instruction. | ||
Line 687: | Line 728: | ||
Target is a byte offset (measured from after this instruction), which will be added to the instruction pointer. | Target is a byte offset (measured from after this instruction), which will be added to the instruction pointer. | ||
==ifNotState ($2F)== | |||
==ifNotState ($2F) (V3-4)== | |||
This opcode is not present in SCUMM V5. | |||
===Encoding=== | ===Encoding=== | ||
Line 693: | Line 736: | ||
===Operation=== | ===Operation=== | ||
unless ( | unless (getState(object) != state) goto target | ||
==ifState ($ | ==ifState ($0F) (V3-4)== | ||
This opcode is not present in SCUMM V5. | |||
===Encoding=== | ===Encoding=== | ||
Line 702: | Line 746: | ||
===Operation=== | ===Operation=== | ||
unless ( | unless (getState(object) == state) goto target | ||
Line 910: | Line 954: | ||
==oldRoomEffect ($5C)== | ==oldRoomEffect ($5C) (V3-4)== | ||
This opcode/instruction not present in SCUMM V5. | |||
===Encoding=== | ===Encoding=== | ||
Line 917: | Line 962: | ||
sub-opcodes: | sub-opcodes: | ||
$03 effect[p16] | $03 effect[p16] | ||
$?? effect[p16] | |||
===Operation=== | ===Operation=== | ||
Line 950: | Line 996: | ||
===Operation=== | ===Operation=== | ||
If the sub-opcode is 0, marks the end of an override section.<br> | If the sub-opcode is 0, marks the end of an override section.<br> | ||
If the sub-opcode is not 0, marks the beginning of an override section. The instruction is immediately followed by a "jumpRelative" instruction.<br | If the sub-opcode is not 0, marks the beginning of an override section. The instruction is immediately followed by a "jumpRelative" instruction.<br> | ||
Overrides are used by cutscenes; if a cutscene is skipped (if the user presses the ESC key), the script will jump by the given target (offset from | Overrides are used by cutscenes; if a cutscene is skipped (if the user presses the ESC key), the script will jump by the given target (offset from the beginOverride instruction). | ||
Line 963: | Line 1,009: | ||
==pickupObject ($25)== | ==pickupObject ($25) (v5)== | ||
This instruction is only present in SCUMM V5. | |||
===Encoding=== | ===Encoding=== | ||
Line 975: | Line 1,022: | ||
== | ==pickupObject ($50) (V3-4)== | ||
This opcode/instruction is not present in SCUMM V5. | |||
===Encoding=== | ===Encoding=== | ||
Line 991: | Line 1,039: | ||
sub-opcodes | sub-opcodes | ||
$00 xpos[p16] ypos[p16] | $00 xpos[p16] ypos[p16] | ||
$01 | $01 color[p8] | ||
$02 right[p16] | $02 right[p16] | ||
$03 width[p16] height[p16] | $03 width[p16] height[p16] | ||
Line 1,009: | Line 1,057: | ||
|$00||SO_AT||Sets the position of the text that follows. | |$00||SO_AT||Sets the position of the text that follows. | ||
|- | |- | ||
|$01||SO_COLOR||Sets the | |$01||SO_COLOR||Sets the color of the text. | ||
|- | |- | ||
|$02||SO_CLIPPED||Clips the text's right-hand side (for wrapping?). | |$02||SO_CLIPPED||Clips the text's right-hand side (for wrapping?). | ||
Line 1,056: | Line 1,104: | ||
It looks like res values always have the high bit set, e.g. 0x01 becomes 0x81. | It looks like res values always have the high bit set, e.g. 0x01 becomes 0x81. | ||
==putActor ($01)== | ==putActor ($01)== | ||
Line 1,091: | Line 1,140: | ||
sub-opcodes: | sub-opcodes: | ||
$01 resID[p8] | $01 resID[p8] | ||
... $01 through $ | ... $01 through $10 take the same arguments ... | ||
$10 resID[p8] | |||
$11 | |||
$12 resID[p8] | |||
$13 resID[p8] | $13 resID[p8] | ||
$14 room[p8] object[p16] | $14 room[p8] object[p16] | ||
Line 1,173: | Line 1,225: | ||
$06 | $06 | ||
$07 scale1[p8] y1[p8] aux scale2[p8] y2[p8] aux slot[p8] | $07 scale1[p8] y1[p8] aux scale2[p8] y2[p8] aux slot[p8] | ||
$08 scale[p8] | $08 scale[p8] startcolor[p8] endcolor[p8] | ||
$09 loadflag[p8] loadslot[p8] | $09 loadflag[p8] loadslot[p8] | ||
$0A effect[p16] | $0A effect[p16] | ||
$0B redscale[p16] greenscale[p16] bluescale[p16] aux | $0B redscale[p16] greenscale[p16] bluescale[p16] aux startcolor[p8] endcolor[p8] | ||
$0C redscale[p16] greenscale[p16] bluescale[p16] aux | $0C redscale[p16] greenscale[p16] bluescale[p16] aux startcolor[p8] endcolor[p8] | ||
$0D resID[p8] filename[c]... $00 | $0D resID[p8] filename[c]... $00 | ||
$0E resID[p8] filename[c]... $00 | $0E resID[p8] filename[c]... $00 | ||
Line 1,192: | Line 1,244: | ||
|$03||SO_ROOM_SCREEN||Initialises a screen. | |$03||SO_ROOM_SCREEN||Initialises a screen. | ||
|- | |- | ||
|$04||SO_ROOM_PALETTE||Adjusts the room's palette. | |$04||SO_ROOM_PALETTE||Adjusts the room's palette. Aux opcode's initial value is $04. | ||
|- | |- | ||
|$05||SO_ROOM_SHAKE_ON||Starts the room shaking. | |$05||SO_ROOM_SHAKE_ON||Starts the room shaking. | ||
Line 1,206: | Line 1,258: | ||
|$0A||SO_ROOM_FADE||If effect is 0, fades in the room. Otherwise, fades out with the given effect (taken from the high byte of effect).<br>1 = iris effect<br>2 = box wipe (upper-left to bottom-right)<br>3 = box wipe (upper-right to bottem-left)<br>4 = inverse box wipe. | |$0A||SO_ROOM_FADE||If effect is 0, fades in the room. Otherwise, fades out with the given effect (taken from the high byte of effect).<br>1 = iris effect<br>2 = box wipe (upper-left to bottom-right)<br>3 = box wipe (upper-right to bottem-left)<br>4 = inverse box wipe. | ||
|- | |- | ||
|$0B||SO_RGB_ROOM_INTENSITY||Lightens/darkens the room's palette, with different scales for red, green and blue. | |$0B||SO_RGB_ROOM_INTENSITY||Lightens/darkens the room's palette, with different scales for red, green and blue. Aux opcode's initial value is $0B. | ||
|- | |- | ||
|$0C||SO_ROOM_SHADOW||Lightens/darkens the shadow palette, with different scales for red, green, and blue. | |$0C||SO_ROOM_SHADOW||Lightens/darkens the shadow palette, with different scales for red, green, and blue. | ||
Line 1,216: | Line 1,268: | ||
|$0F||SO_ROOM_TRANSFORM||Manipulates palettes, strings? | |$0F||SO_ROOM_TRANSFORM||Manipulates palettes, strings? | ||
|- | |- | ||
|$10||SO_CYCLE_SPEED||Starts | |$10||SO_CYCLE_SPEED||Starts color cycling with delay? colIndex is between 0 and 16 | ||
|} | |} | ||
Line 1,223: | Line 1,275: | ||
opcode arg1[p16] arg2[p16] sub-opcode | opcode arg1[p16] arg2[p16] sub-opcode | ||
Small header games include an extra sub-opcode, $02 (SO_ROOM_COLOR), which adjusts the room's palette: | Small header games (V3 and V4) include an extra sub-opcode, $02 (SO_ROOM_COLOR), which adjusts the room's palette: | ||
opcode $02 | opcode $02 color[p16] index[p16] | ||
... or for V3 games ... | ... or for V3 games ... | ||
opcode | opcode color[p16] index[p16] $02 | ||
In small header games, sub-opcode $04 (SO_ROOM_PALETTE) affects the shadow palette, and only accepts two arguments, a "room | In small header games, sub-opcode $04 (SO_ROOM_PALETTE) affects the shadow palette, and only accepts two arguments, a "room color slot" (palette entry? between 0 and 256) and an index: | ||
opcode $04 | opcode $04 color[p16] index[p16] | ||
... or for V3 games ... | ... or for V3 games ... | ||
opcode | opcode color[p16] index[p16] $04 | ||
In FM-Towns games, sub-opcode $0A performs a different function and has its own sub-opcodes (some unknown and all not yet implemented in ScummVM): | In FM-Towns games, sub-opcode $0A performs a different function and has its own sub-opcodes (some unknown and all not yet implemented in ScummVM): | ||
Line 1,269: | Line 1,321: | ||
|} | |} | ||
== | ==saveLoadGame ($22) (V3-4)== | ||
This instruction is not present in SCUMM V5; its opcode is used for "getAnimCounter". | |||
===Encoding=== | |||
opcode result arg1[p8] | |||
===Operation=== | ===Operation=== | ||
The slot is determined by taking the lower 5 bits of arg1. The upper 3 bits determine an aux opcode, that performs an action described in the table below. | |||
{| border="1" cellpadding="2" width=100% | {| border="1" cellpadding="2" width=100% | ||
|- style="background:whitesmoke" | |- style="background:whitesmoke" | ||
|Opcode||Meaning||Description | |Opcode||Meaning||Description | ||
|- | |- | ||
|$ | |$00||Num. Available Slots||Returns the number of save slots available. | ||
|- | |||
|$20||Drive||In V3, returns the type of drive (0 = ???, 1 = A or B [floppy], 2 = hard drive).<br>In V4, sets the current drive (returns 1). | |||
|- | |||
|$40||Load Game||Loads a game from the given slot (returns 3 if successful, 5 otherwise). | |||
|- | |- | ||
|$ | |$80||Save Game||Saves a game to the given slot (returns 0 if successful, 2 otherwise). | ||
|- | |- | ||
|$ | |$C0||Test For Game||Tests if a save exists in the given slot (returns 6 if so, 7 otherwise). | ||
|} | |} | ||
== | |||
==saveLoadVars ($A7) (V3-4)== | |||
This instruction is not present in SCUMM V5; its opcode is used as a dummy. | |||
===Encoding=== | ===Encoding=== | ||
opcode | opcode sub-opcode | ||
sub-opcodes: | |||
$01 sub-sub-opcode... $00 | |||
$02 sub-sub-opcode... $00 | |||
$01 (save) sub-sub-opcodes: | |||
$01 resultA resultB | |||
$02 arg1[p8] arg2[p8] | |||
$03 filename[c]... $00 | |||
$04 | |||
$1F | |||
$02 (load) sub-sub-opcodes: | |||
$01 resultA resultB | |||
$02 arg1[p8] arg2[p8] | |||
$03 filename[c]... $00 | |||
$04 | |||
$1F | |||
===Encoding=== | ===Operation=== | ||
opcode object[p16] name[c]... $00 | {| border="1" cellpadding="2" width=100% | ||
|- style="background:whitesmoke" | |||
===Operation=== | |Opcode||Meaning||Description | ||
Sets the given object's name. | |- | ||
|$01||SO_SAVE_VARS||Saves variables (for saving games?) | |||
|- | |||
==setOwnerOf ($29)== | |$02?||SO_RESTORE_VERBS||Loads variables (for saving games?)<br>(I have not verified that restore vars is $02, as the ScummVM code only compares to $01.) | ||
|} | |||
===Encoding=== | |||
opcode object[p16] owner[p8] | {| border="1" cellpadding="2" width=100% | ||
|- style="background:whitesmoke" | |||
===Operation=== | |Opcode||Meaning||Description | ||
Sets the owner of the object. | |- | ||
|$01||Write Vars||Writes a range of variables. | |||
|- | |||
==setState ($07)== | |$02||Write Strings||Writes a range of string variables. | ||
|- | |||
===Encoding=== | |$03||Open File||Opens a file for writing. | ||
opcode object[p16] state[p8] | |- | ||
|$04||Dummy||Does nothing. | |||
===Operation=== | |- | ||
Sets the state of the object. | |$1F||Close File||Closes the last opened file. | ||
|} | |||
==setVarRange ($26)== | {| border="1" cellpadding="2" width=100% | ||
non-standard encoding | |- style="background:whitesmoke" | ||
|Opcode||Meaning||Description | |||
===Encoding=== | |- | ||
|$01||Read Vars||Reads a range of variables. | |||
|- | |||
|$02||Read Strings||Reads a range of string variables. | |||
|- | |||
|$03||Open File||Opens a file for reading. | |||
|- | |||
|$04||Dummy||Does nothing. | |||
|- | |||
|$1F||Close File||Closes the last opened file. | |||
|} | |||
==saveRestoreVerbs ($AB)== | |||
===Encoding=== | |||
opcode sub-opcode | |||
sub-opcodes: | |||
$01 start[p8] end[p8] mode[p8] | |||
$02 start[p8] end[p8] mode[p8] | |||
$03 start[p8] end[p8] mode[p8] | |||
===Operation=== | |||
{| border="1" cellpadding="2" width=100% | |||
|- style="background:whitesmoke" | |||
|Opcode||Meaning||Description | |||
|- | |||
|$01||SO_SAVE_VERBS||For all verbs between start and end, sets the "saveid" to mode. | |||
|- | |||
|$02||SO_RESTORE_VERBS||For all verbs between start and end and matching mode, kills any existing verb, sets the saveid to 0 and generally inits the verb. | |||
|- | |||
|$03||SO_DELETE_VERBS||For all verbs between start and end and matching mode, kills any existing verb. | |||
|} | |||
==setCameraAt ($32)== | |||
===Encoding=== | |||
opcode x[p16] | |||
===Operation=== | |||
Sets the camera's x position. | |||
==setObjectName ($54)== | |||
===Encoding=== | |||
opcode object[p16] name[c]... $00 | |||
===Operation=== | |||
Sets the given object's name. | |||
==setOwnerOf ($29)== | |||
===Encoding=== | |||
opcode object[p16] owner[p8] | |||
===Operation=== | |||
Sets the owner of the object. | |||
==setState ($07)== | |||
===Encoding=== | |||
opcode object[p16] state[p8] | |||
===Operation=== | |||
Sets the state of the object. | |||
==setVarRange ($26)== | |||
non-standard encoding | |||
===Encoding=== | |||
opcode result number[8] values[8]... | opcode result number[8] values[8]... | ||
or | or | ||
Line 1,357: | Line 1,501: | ||
===Variants=== | ===Variants=== | ||
In SCUMM V3 (small header) games, this opcode is used for the WaitForSentence instruction. | In SCUMM V3 and V4 (small header) games, this opcode is used for the WaitForSentence instruction. | ||
Line 1,440: | Line 1,584: | ||
==stopObjectCode ($00)== | ==stopObjectCode ($A0 or $00)== | ||
===Encoding=== | ===Encoding=== | ||
Line 1,446: | Line 1,590: | ||
===Operation=== | ===Operation=== | ||
Marks the calling script as dead, to be later pruned from the thread pool. Cleans up residual arrays. | Marks the calling script as dead, to be later pruned from the thread pool. Cleans up residual arrays. Should always be the last instruction in a script. | ||
$A0 is used in local and global scripts (LSCR and SCRP blocks in the V5 resource files), $00 is used in room entry, room exit, and verb/object scripts (ENCD, EXCD, VERB blocks). | |||
Line 1,500: | Line 1,646: | ||
|$02||Copy String||Creates a duplicate of the string at resource slot srcID into destID. The old string at destID is lost. | |$02||Copy String||Creates a duplicate of the string at resource slot srcID into destID. The old string at destID is lost. | ||
|- | |- | ||
|$03||Write Character||Writes char at the given index (offset) of the string resource located at slot stringID. Out of bounds accesses cause undefined | |$03||Write Character||Writes char at the given index (offset) of the string resource located at slot stringID. Out of bounds accesses cause undefined behavior. | ||
|- | |- | ||
|$04||Read Character||Reads a byte (character) at the given index (offset) of the string resource located at slot stringID, and writes it to result. Out of bounds accesses cause undefined | |$04||Read Character||Reads a byte (character) at the given index (offset) of the string resource located at slot stringID, and writes it to result. Out of bounds accesses cause undefined behavior. | ||
|- | |- | ||
|$05||New String||Allocates or frees a string (Array), located at resource slot stringID. The string is initialised to size; if size is zero, the string is freed. | |$05||New String||Allocates or frees a string (Array), located at resource slot stringID. The string is initialised to size; if size is zero, the string is freed. | ||
Line 1,550: | Line 1,696: | ||
$01 object[p16] | $01 object[p16] | ||
$02 name[c]... $00 | $02 name[c]... $00 | ||
$03 | $03 color[p8] | ||
$04 | $04 hicolor[p8] | ||
$05 left[p16] top[p16] | $05 left[p16] top[p16] | ||
$06 | $06 | ||
Line 1,557: | Line 1,703: | ||
$08 | $08 | ||
$09 | $09 | ||
$10 | $10 color[p8] | ||
$11 | $11 | ||
$12 key[p8] | $12 key[p8] | ||
Line 1,563: | Line 1,709: | ||
$14 stringID[p16] | $14 stringID[p16] | ||
$16 object[p16] room[p8] | $16 object[p16] room[p8] | ||
$17 | $17 color[p8] | ||
===Operation=== | ===Operation=== | ||
Line 1,574: | Line 1,720: | ||
|$02||SO_VERB_NAME||Assigns the in-line name to the verb slot. | |$02||SO_VERB_NAME||Assigns the in-line name to the verb slot. | ||
|- | |- | ||
|$03||SO_VERB_COLOR||Sets the | |$03||SO_VERB_COLOR||Sets the color of the verb. | ||
|- | |- | ||
|$04||SO_VERB_HICOLOR||Sets the | |$04||SO_VERB_HICOLOR||Sets the highlight color of the verb. | ||
|- | |- | ||
|$05||SO_VERB_AT||Sets the verb's top-left co-ordinates. | |$05||SO_VERB_AT||Sets the verb's top-left co-ordinates. | ||
Line 1,588: | Line 1,734: | ||
|$09||SO_VERB_NEW||Creates a verb in the slot for the given verbID. If the slot is 0 (verb doesn't already exist), will add it to the next unusued slot; if this exceeds the global maximum number of verbs an error will be raised. | |$09||SO_VERB_NEW||Creates a verb in the slot for the given verbID. If the slot is 0 (verb doesn't already exist), will add it to the next unusued slot; if this exceeds the global maximum number of verbs an error will be raised. | ||
|- | |- | ||
|$10||SO_VERB_DIMCOLOR||Sets the dim | |$10||SO_VERB_DIMCOLOR||Sets the dim color of the verb. | ||
|- | |- | ||
|$11||SO_VERB_DIM||Dims this verb. | |$11||SO_VERB_DIM||Dims this verb. | ||
Line 1,600: | Line 1,746: | ||
|$16||Assign Object||Assigns an object from the given room to the verb (if the object's image index is not already assigned to the given object). | |$16||Assign Object||Assigns an object from the given room to the verb (if the object's image index is not already assigned to the given object). | ||
|- | |- | ||
|$17||Set Back | |$17||Set Back Color||Sets the background color of the verb? | ||
|} | |} | ||
Line 1,735: | Line 1,881: | ||
=Table of Parameters= | =Table of Parameters= | ||
Please see the wiki page [[SCUMM/V5_opcodes/Table]]. | Please see the wiki page [[SCUMM/V5_opcodes/Table]] for a concise rendition of the above information (with a few omissions dues to the complexity of the instructions). |
edits