Quick help please

BlitzPlus Forums/BlitzPlus Programming/Quick help please

Magitta(Posted 2003) [#1]
Hi!
Can someone help me translate this:
Color red#,green#,blue#
Plot spark\x#,spark\y#
Plot spark\x#,spark\y#+1
Plot spark\x#+1,spark\y#
Plot spark\x#+1,spark\y#+1

To some code which uses the writepixelfast routine. I do need the colors to be red from the variables. Thank you!!


WendellM(Posted 2003) [#2]
clr=(red Shl 16)Or(green Shl 8)Or blue
LockBuffer
WritePixelFast spark\x,spark\y,clr
WritePixelFast spark\x,spark\y+1,clr
WritePixelFast spark\x+1,spark\y,clr
WritePixelFast spark\x+1,spark\y+1,clr
UnLockBuffer

should work.