EvilEngine/SURF: Difference between revisions
Content added Content deleted
No edit summary |
m (Seil moved page SURF to EvilEngine/SURF) |
||
(2 intermediate revisions by one other user not shown) | |||
Line 4: | Line 4: | ||
{{#vardefine:type|[[Base]]}}<nowiki/> |
{{#vardefine:type|[[Base]]}}<nowiki/> |
||
{{#vardefine:basetype|0x1A}}<nowiki/> |
{{#vardefine:basetype|0x1A}}<nowiki/> |
||
{{#vardefine:games|Scooby BFBB TSSM Incredibles ROTU}}<nowiki/> |
{{#vardefine:games|Scooby BFBB TSSM Incredibles ROTU RatProto}}<nowiki/> |
||
{{#vardefine:sourcecode|[https://github.com/bfbbdecomp/bfbb/blob/master/src/Game/zSurface.h zSurface.h]}}<nowiki/> |
{{#vardefine:sourcecode|[https://github.com/bfbbdecomp/bfbb/blob/master/src/Game/zSurface.h zSurface.h]}}<nowiki/> |
||
{{#vardefine:image|}}<nowiki/> |
{{#vardefine:image|}}<nowiki/> |
||
Line 18: | Line 18: | ||
! Offset !! Type !! Variable !! Description |
! Offset !! Type !! Variable !! Description |
||
|- |
|- |
||
| 0x08 || |
| 0x08 || char || '''game_damage_type''' || |
||
* 0x00 = ? |
* 0x00 = ? |
||
* 0x01 = ? |
* 0x01 = ? |
||
Line 24: | Line 24: | ||
* 0x06 = Hazard? |
* 0x06 = Hazard? |
||
|- |
|- |
||
| 0x09 || |
| 0x09 || char || '''game_sticky''' || always 0 |
||
|- |
|- |
||
| 0x0A || |
| 0x0A || char || '''game_damage_flags''' || |
||
* 0x00 = ? |
* 0x00 = ? |
||
* 0x01 = ? |
* 0x01 = ? |
||
|- |
|- |
||
| 0x0B || |
| 0x0B || char || '''surf_type''' || always 0 |
||
|- |
|- |
||
| 0x0C || |
| 0x0C || char || '''phys_pad''' || padding (always null) |
||
|- |
|- |
||
| 0x0D || |
| 0x0D || char || '''sld_start''' || probably in degrees |
||
|- |
|- |
||
| 0x0E || |
| 0x0E || char || '''sld_stop''' || probably in degrees |
||
|- |
|- |
||
| 0x0F || |
| 0x0F || char || '''phys_flags''' || |
||
* 0x00 = Slide Off Player |
* 0x00 = Slide Off Player |
||
* 0x02 = Angle Player |
* 0x02 = Angle Player |
||
Line 54: | Line 54: | ||
| 0x2C || [[#zSurfColorFX|zSurfColorFX]] || '''colorfx''' || |
| 0x2C || [[#zSurfColorFX|zSurfColorFX]] || '''colorfx''' || |
||
|- |
|- |
||
| 0x34 || |
| 0x34 || uint || '''texture_anim_flags''' || 0 or 1? |
||
|- |
|- |
||
| 0x38 || [[#zSurfTextureAnim|zSurfTextureAnim]][2] || '''texture_anim''' || |
| 0x38 || [[#zSurfTextureAnim|zSurfTextureAnim]][2] || '''texture_anim''' || |
||
|- |
|- |
||
| 0x50 || |
| 0x50 || uint || '''uvfx_flags''' || related to UV anim? 0 or 1? |
||
|- |
|- |
||
| 0x54 || [[#zSurfUVFX|zSurfUVFX]][2] || '''uvfx''' || |
| 0x54 || [[#zSurfUVFX|zSurfUVFX]][2] || '''uvfx''' || |
||
|- |
|- |
||
| 0x114 || |
| 0x114 || char || '''on''' || 0 or 1 |
||
|- |
|- |
||
| 0x115 || |
| 0x115 || char[3] || '''pad''' || padding |
||
|- |
|- |
||
| 0x118 || float || '''oob_delay''' || |
| 0x118 || float || '''oob_delay''' || |
||
Line 85: | Line 85: | ||
! Offset !! Type !! Variable !! Description |
! Offset !! Type !! Variable !! Description |
||
|- |
|- |
||
| 0x00 || |
| 0x00 || uint || '''flags''' || |
||
* 0 = ? |
* 0 = ? |
||
* 1 = ? |
* 1 = ? |
||
* 8 = ? |
* 8 = ? |
||
|- |
|- |
||
| 0x04 || [[AssetID]] |
| 0x04 || [[AssetID]] || '''bumpmapID''' || usually null |
||
|- |
|- |
||
| 0x08 || [[AssetID]] |
| 0x08 || [[AssetID]] || '''envmapID''' || |
||
|- |
|- |
||
| 0x0C || float || '''shininess''' || |
| 0x0C || float || '''shininess''' || |
||
Line 98: | Line 98: | ||
| 0x10 || float || '''bumpiness''' || usually 0 |
| 0x10 || float || '''bumpiness''' || usually 0 |
||
|- |
|- |
||
| 0x14 || [[AssetID]] |
| 0x14 || [[AssetID]] || '''dualmapID''' || usually null |
||
|} |
|} |
||
Line 105: | Line 105: | ||
! Offset !! Type !! Variable !! Description |
! Offset !! Type !! Variable !! Description |
||
|- |
|- |
||
| 0x00 || |
| 0x00 || ushort || '''flags''' || always 0x000E |
||
|- |
|- |
||
| 0x02 || |
| 0x02 || ushort || '''mode''' || always 0 |
||
|- |
|- |
||
| 0x04 || float || '''speed''' || |
| 0x04 || float || '''speed''' || |
||
Line 116: | Line 116: | ||
! Offset !! Type !! Variable !! Description |
! Offset !! Type !! Variable !! Description |
||
|- |
|- |
||
| 0x00 || |
| 0x00 || ushort || '''pad''' || padding (always null) |
||
|- |
|- |
||
| 0x02 || |
| 0x02 || ushort || '''mode''' || |
||
* 0 = ? |
* 0 = ? |
||
* 2 = ? |
* 2 = ? |
||
|- |
|- |
||
| 0x04 || [[AssetID]] |
| 0x04 || [[AssetID]] || '''group''' || |
||
|- |
|- |
||
| 0x08 || float || '''speed''' || |
| 0x08 || float || '''speed''' || |
Latest revision as of 22:55, 15 September 2022
SURF | |
---|---|
Surface | |
Type | Base |
Base Type | 0x1A |
Games used | Night of 100 Frights Battle for Bikini Bottom |
Source code | zSurface.h |
This asset defines an entry for a surface, which can be applied to other assets such as PLAT, SIMP, BOUL or even parts of JSP through the MAPR asset. The surface can have properties such as special materials, texture animations or patterns, and properties such as hurt, wall jump, out of bounds, prevent standing on.
Format
Surfaces are base assets, so they start with their 0x54 byte header, then are followed by:
Offset | Type | Variable | Description |
---|---|---|---|
0x08 | char | game_damage_type |
|
0x09 | char | game_sticky | always 0 |
0x0A | char | game_damage_flags |
|
0x0B | char | surf_type | always 0 |
0x0C | char | phys_pad | padding (always null) |
0x0D | char | sld_start | probably in degrees |
0x0E | char | sld_stop | probably in degrees |
0x0F | char | phys_flags |
|
0x10 | float | friction | range = 0 to 1? |
0x14 | zSurfMatFX | matfx | |
0x2C | zSurfColorFX | colorfx | |
0x34 | uint | texture_anim_flags | 0 or 1? |
0x38 | zSurfTextureAnim[2] | texture_anim | |
0x50 | uint | uvfx_flags | related to UV anim? 0 or 1? |
0x54 | zSurfUVFX[2] | uvfx | |
0x114 | char | on | 0 or 1 |
0x115 | char[3] | pad | padding |
0x118 | float | oob_delay | |
0x11C | float | walljump_scale_xz | |
0x120 | float | walljump_scale_y | |
0x124 | float | damage_timer | little endian |
0x128 | float | damage_bounce | little endian |
Events | |||
0x12C | Event[numberOfEvents] | Events |
zSurfMatFX
Offset | Type | Variable | Description |
---|---|---|---|
0x00 | uint | flags |
|
0x04 | AssetID | bumpmapID | usually null |
0x08 | AssetID | envmapID | |
0x0C | float | shininess | |
0x10 | float | bumpiness | usually 0 |
0x14 | AssetID | dualmapID | usually null |
zSurfColorFX
Offset | Type | Variable | Description |
---|---|---|---|
0x00 | ushort | flags | always 0x000E |
0x02 | ushort | mode | always 0 |
0x04 | float | speed |
zSurfTextureAnim
Offset | Type | Variable | Description |
---|---|---|---|
0x00 | ushort | pad | padding (always null) |
0x02 | ushort | mode |
|
0x04 | AssetID | group | |
0x08 | float | speed |
zSurfUVFX
Offset | Type | Variable | Description |
---|---|---|---|
0x54 | int | mode | always 0 |
0x58 | float | rot | always 0 |
0x5C | float | rot_spd | |
0x60 | Vector3 | trans | Z is always 0 |
0x6C | Vector3 | trans_spd | Z is always 0 |
0x78 | Vector3 | scale | Z is always 0 |
0x84 | Vector3 | scale_spd | usually (0, 0, 0) |
0x90 | Vector3 | min | usually (0, 0, 0) |
0x9C | Vector3 | max | usually (0, 0, 0) |
0xA8 | Vector3 | minmax_spd | usually (0, 0, 0) |