Don`t read this...
Go down..
-------------------------------------
If player is in zone x;y to x2;y2 then
1
2
2
trigger Roof1 trigger Roof1B
then if leaves... the same...
edited 3×, last 13.02.12 02:11:31 pm
trigger Roof1 trigger Roof1B
zones = {{1,1,2,2}} -- {x start, y start, x end, y end} addhook("movetile","triggerroof") function triggerroof(id,x,y) 	for i=1,#zones do 		if (x>=zones[i][1] and x<=zones[i][3] and y>=zones[i][2] and y<=zones[i][4]) then 			parse("trigger Roof1") 			parse("trigger Roof1B") 		end 	end end
trigger Roof1 trigger Roof1B
iImgHandle = {}; iXZone = 10; --posx here![start] iYZone = 10; --posy here![start] iXZoneRange = 5; --width iYZoneRange = 3; --height cPath = "Put your image path in here!"; addhook ("startround","vSetUpImages"); addhook ("movetile","vCheck"); function vSetUpImages() for i=1,32 do iImgHandle = image(path,iXZone*32,iYZone*32,1,i); end end function vCheck(id,x,y) if ((x>=iXZone) and (x<=(iXZone+iXZoneRange)) and (y>=iYZone) and (y<=(iYZone+iYZoneRange))) imagealpha(iImgHandle[id],0.6); else imagealpha(iImgHandle[id],1.0); end end --inital call vSetUpImages (Deathmatch) vSetUpImages();