the code that i've used is:
mybackground:=tbackground.create(dxspriteengine.en gine);
with mybackground do
begin
image:=dximagelist.items.find('backimgs');
image.transparent:=false;
setmapsize(mapwidth,mapheight);
z:=-2;
for i:=0 to mapwidth-1 do
for j:=0 to mapheight-1 do
begin
chips[j,i]:=maparray[j,i];
collisionmap[j,i]:=collisionarray[j,i];
end;
tile:=true;
end;
the maparray is --> maparray:array[1..mapwidth,1..mapheight] of byte;
the bytes are the number of the texture block in my imagelist.
the collisionarray is --> collisionarray[1..mapwidth,1..mapheight] of boolean;
the booleans are true if i can pass the block.
i can't wrote this the other day because i wasn't in my house.
i found this functions in a tutorial that i looked in turbo.com. but
it don't works. is my code useless?
i can't read your tutorial today but i want to look it.
if you need more info post a reply :shock:
Bookmarks