Skip to content

Adult titles

The games this site covers are adult titles. Their data, pictures and text include sexual content.

Continue only if you are an adult where you live.

0x322 set-polygon-color

Opcode 0x322 (802), draw. Investigated by OME, with high confidence (from investigation).

(handle)(blend_mode)(alpha)(rgb) — set a polygon's colour, which multiplies each vertex's own, and its blend mode. Alpha 0x100 or more is 0xff; a negative alpha or RGB keeps the current one.

Operands

#RoleTypes seenAccess
1handleimm, l-intread
2blend mode: 0 alpha, 1 additive, 2 copy, 3 subtractiveimm, g-intread
3alpha, or negative to keepimm, g-int, l-intread
4RGB, or negative to keepimm, g-int, l-intread

In the port

OME’s port implements it. It never waits: a wait parks the engine until input, a sleep, a transition, a dialog or a movie ends. What it can do with control besides waiting:

  • falls: it returns to the next instruction

OME derives these facts from the port’s handler (its tools/opcode_flow.py), and they over-approximate: a fact some path can reach is given.

By build

Whether each build’s scripts use it, as OME’s survey of the game’s scripts saw them, and how many evidence items name the build.

BuildGameUsed by its scriptsEvidence
4.24J (SYS4422)Himegari Dungeon Meisterno—
4.33G (SYS4433)Kamidori Alchemy Meisterno—
4.38D (SYS4438)Soukoku no Arterialyes1

Evidence

  • native-re on SYS4438, high confidence; Arterial SYS4438 Ghidra /arterial/4.38D and the complete Arterial catalog (vm-map/opcodes.toml opcode 0x322): op_0x322_set_polygon_color@0x425100 builds the ARGB (gfx_polygon_get_color@0x4969a0 for a kept part) and calls gfx_polygon_set_color@0x4968a0, which stores the mode (+0x24) and the colour (+0x34) and recomputes the vertex colours: kept * colour / 255 per channel, or the kept ones when the colour is 0xffffffff (gfx_polygon_calc_diffuse@0x48b9d0). The mode is the draw's blend: 0 source alpha / inverse source alpha, 1 additive, 2 one / zero, 3 reverse subtract. LOGO@0xae sets mode 0, alpha 0xff, black.

Details

OME’s notes on it, as the registry keeps them.

The port stores the colour and the mode (GfxState.SetPolygonColor). 創刻のアテリアル has 8,633 sites.