snake game for beginners

The Partridge Family were neither partridges nor a family. Discuss.
Post Reply
Cthunderbolt
Posts: 1
Joined: May 27th, 2018, 11:44 am

snake game for beginners

Post by Cthunderbolt » May 27th, 2018, 12:42 pm

At 11:09 of Beginner C++ Game Programming DirectX [Snake Game] Tutorial 14a why is the value of dimension 20 and width and height 10 each? Isn't width and height of the grid and dimension of the cell? So shouldn't grids be bigger than the cell?

User avatar
Yumtard
Posts: 575
Joined: January 19th, 2017, 10:28 pm
Location: Idiot from northern Europe

Re: snake game for beginners

Post by Yumtard » May 27th, 2018, 1:51 pm

dont remember the tutorial but i assume dimension 20 means the cells are 20x20 pixels. height and width 10 means the board is 10 cells wide and 10 cells high. so 10x20 pixels wide and high

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: snake game for beginners

Post by chili » May 27th, 2018, 3:48 pm

Grid dimensions are in units of cell, cell dimensions in units of pixel. There is no constraint between cell size and grid size.
Chili

Post Reply