color changeing for obects

not sure if this is a problem for some people still but ive been at this for just under a week and finnally won the war on this issue with Changeing the color of an object lol through the following code snippet

selectedTarget.GetComponent ().material.color = Color.blue;

on the object in question that you want to change the color of it has a default material called oddly enough
“default material” change this to some some other material
and the code executes as it should the objects change color

feelen pretty happy atm :smile: hope this helps someone else with similar issue

inside of the manuel at

title supposed to say color changeing for objects but appearently you cant edit titles :confused: