Whatdotcolor not working!
Author |
Message |
Impatientcow915
|
Posted: Wed May 20, 2015 7:47 am Post subject: Whatdotcolor not working! |
|
|
What is it you are trying to achieve?
i am trying to make a wall collider for my player
What is the problem you are having?
the whatdotcolor is not functioning as it should. I used a put to show the changes from true to false, but it didn't change
Describe what you have tried to solve this problem
I have seen all your posts, and it still doesn't work properly
Post any relevant code (You may choose to attach the file instead of posting the code if it is too long)
Turing: |
var x,y,col : int := 0
var chars : int := array char of boolean
setscreen ("offscreenonly, graphics : 1000'1000")
loop
View.Update
drawfillbox (1000, 1000, 950, 0, blue)
Input.KeyDown (chars )
drawfilloval (x,y, 10, 10, black)
if chars ('d') then
x += 1
end if
if whatdotcolor (x,y ) = blue then
put whatdotcolor (x,y ) = blue % if I remember correctly, this should show t/f
end if
% sorry if there are any extra upper case letters, I'm on my iPad.
|
Please specify what version of Turing you are using
4.1.1 |
|
|
|
|
|
Sponsor Sponsor
|
|
|
Dreadnought
|
Posted: Wed May 20, 2015 8:36 am Post subject: Re: Whatdotcolor not working! |
|
|
You're drawing a black circle with a radius of 10 pixels and checking a pixel next to the centre of that circle. What colour will the pixel be? |
|
|
|
|
|
DemonWasp
|
Posted: Wed May 20, 2015 4:39 pm Post subject: RE:Whatdotcolor not working! |
|
|
When will that put ever be called with a value of false? |
|
|
|
|
|
|
|