I am trying to draw several bricks for a breakout game using dx9.
here is some of the code I am using.
[font="Consolas"][font="Consolas"][/font][/font][font="Consolas"][color="#008000"][font="Consolas"][color="#008000"][font="Consolas"][color="#008000"]// create the vertices using the CUSTOMVERTEX struct
[/font][/font][/font][font="Consolas"][font="Consolas"]CUSTOMVERTEX vertices[] =
{
{ 0.0f, 0.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(255, 0, 0), },
{ 150.0f, 0.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(255, 0, 0), },
{ 150.0f, 40.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(255, 0, 0), },
{ 0.0f, 40.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(255, 0, 0), },
{ 150.0f, 0.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(0, 255, 0), },
{ 300.0f, 0.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(0, 255, 0), },
{ 300.0f, 40.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(0, 255, 0), },
{ 150.0f, 40.0f, 0.5f, 1.0f, D3DCOLOR_XRGB(0, 255, 0), },
};
[/font][/font][font="Consolas"][color="#008000"][font="Consolas"][color="#008000"][font="Consolas"][color="#008000"]// create a vertex buffer interface called v_buffer
[/font][/font][/font][font="Consolas"][font="Consolas"]d3ddev->CreateVertexBuffer(8*[/font][/font][font="Consolas"][color="#0000ff"][font="Consolas"][color="#0000ff"][font="Consolas"][color="#0000ff"]sizeof[/font][/font][/font][font="Consolas"][font="Consolas"](CUSTOMVERTEX),
0,
CUSTOMFVF,
D3DPOOL_MANAGED,
&v_buffer,
NULL);
let me know if you need more code or anything I should study more in depth.
?
[/font][/font]
breakout bricks
I don't understand.
Phil, you've been attempting breakout for years, why have you not made any, if not very little, progress? You've created many threads with only small snippets of code and a broad statement, and nothing amounting to a question. (I'd go as far to say there isn't a single question mark in any of your posts.) How are we supposed to help you? What are you having trouble with?
However, to respond your statement: You need to study more in depth.
Phil, you've been attempting breakout for years, why have you not made any, if not very little, progress? You've created many threads with only small snippets of code and a broad statement, and nothing amounting to a question. (I'd go as far to say there isn't a single question mark in any of your posts.) How are we supposed to help you? What are you having trouble with?
However, to respond your statement: You need to study more in depth.
[font="Consolas"][font="Consolas"]let me know [...] anything I should study more in depth.[/font][/font]
You should study how to ask questions.
L. Spiro
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement