Skip to content

Color parameter not working in dxDrawMaterialPrimitive3D #1148

@Shuubaru

Description

@Shuubaru

Describe the bug
dxDrawMaterialPrimitive3D uses a table to store every primitive data:

{x,y,z, u, v} or {x,y,z,color, u, v}

If color parameter (tocolor) is provided, it is ignored and the color used results in white.

To reproduce
I was even able to reproduce with test resource provided by CrosRoad95:

  1. Download test resource 3dprim.zip
  2. Start 3dprim.
  3. Go to Toreno house (or crun setElementPosition(localPlayer, -693.81708, 951.90002, 12.24125))
  4. The drawn primitive will not look like in: Add dxDrawPrimitive3D and dxDrawMaterialPrimitive3D #760

Expected behaviour
Color paremeter should paint the image. How I know it is bugged?
Well, it worked on the version it was implemented because I did a fast script based on Tron gamemode:

image
image

Screenshots
How it should look:
image

How it looks:
image

Version
I tested in two different versions and in both it's bugged:

Server: v1.5.7-release-20288
Client: v1.5.7-release-20288

Server: v1.5.7-release-20343
Client: v1.5.7-release-20343

Additional context
nada

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions