SASA 扩展NewOpcodes
碰撞绘制 Col / Draw / Txd
查看 MarkdownColPoint、shape 绘制、TXD、字符串
sa · 扩展 NewOpcodes · 需 CLEO + NewOpcodes
射线 ColPoint、2D shape、TXD、串操作。写法见 Lua / Redux。
两点射线检测,可滤建筑/车/人/物等。
0D3A GET_COLLISION_BETWEEN_POINTS
in: fromX..toZ, buildings, vehicles, peds, objects, dummies, seeThroughCheck, cameraIgnoreCheck, shotThroughCheck, entityToIgnore
out: colPoint, outX, outY, outZ, entity从 ColPoint 取法线。
0D3B GET_COL_DATA_NORMAL_VECTOR
in: colPoint
out: x, y, z取表面类型。
0D3C GET_COL_DATA_SURFACE
in: colpoint
out: surface取光照打包值。
0D3D GET_COL_DATA_LIGHTING
in: colPoint
out: lighting取 depth。
0D3E GET_COL_DATA_DEPTH
in: colPoint
out: depth画 2D 多边形(图元类型、贴图、顶点缓冲、混合)。
0D40 DRAW_SHAPE
in: type, texture, numVerts, pVerts, vertexAlpha, srcBlend, dstBlend, unused配置 shape 某个顶点(位置/RHW/色/UV/翻转)。
0D41 SETUP_SHAPE_VERTEX
in: shape, vertex, x, y, z, rhw, r, g, b, a, u, v, invertX, invertY绕轴点旋转 shape 顶点。
0D45 ROTATE_SHAPE_VERTICES
in: shape, numVerts, x, y, angle从文件加载 TXD 并注册名。用在 if 里。
0D42 LOAD_TXD
in: txd, path取已注册 TXD 槽 id。
0D43 GET_TXD_ID
in: txd
out: id在命名字典里按贴图名找指针。用在 if 里。
0D44 FIND_TEXTURE_IN_TXD_WITH_NAME
in: texture, dictionary
out: texture在槽 id 字典里找贴图。用在 if 里。
0D46 FIND_TEXTURE_IN_TXD_WITH_ID
in: texture, dictionary
out: texture模型使用的 TXD 槽。用在 if 里。
0D47 GET_MODEL_TXD_ID
in: model
out: txdId模型 CRC32 key。用在 if 里。
0D48 GET_MODEL_CRC
in: model
out: crc32Key比较两串;相等条件真。用在 if 里。
0D49 STRING_CMP
in: strA, strB
out: result把 append 接到 string 缓冲。
0D4A STRING_CAT
in: string, append找子串,返回指针或失败。用在 if 里。
0D4B STRING_STR
in: string, substring
out: result
评论