Thank you so much for the video! Quick question, what If I wanted to check and store a specific pixel then check that pixel again later to see if it changed from the original color? Without having to declare colors manually?
Thank you for the video! I'm trying to do this with a sphere, but it's not working. I followed all the steps, but nothing happen. Do you know what needs to change to make it work with a sphere?
hello i got my ray cast working. however i'm wondering if i can use an image with a ray cast attached and have it hit an object with a public variable holding a image then pass that image to the image with my ray cast and assign it to its own image component. would this be a reliable and/or reusable code, and how should i go about approaching this ??
Yes this should be doable. You need do do a GetComponent on the object you hit and retrieve the image and place it as the image on the object you raycast from.
finally got that one done but can you tell me what im doing wrong here. this code im attempting to have some what of an inventory list and i want as a item is added to the list the value of that item is added displaying a total. it works when i add a second item but it doesn't record the first one. Text putvalue; string somenewaddvalue; Text thistextcomponent; public float putithere; public float blahh; void Start () { thistextcomponent = GetComponent(); } public void Addingthetotalpercart() { Imagechildfixer b = GetComponentInParent(); if (b != null) { putvalue = b.itemcost; somenewaddvalue = putvalue.text; blahh = float.Parse(somenewaddvalue); putithere += blahh; } } void Update () { thistextcomponent.text = "Cart Total " + Math.Round(putithere, 2);
Thank you so much for the video! Quick question, what If I wanted to check and store a specific pixel then check that pixel again later to see if it changed from the original color? Without having to declare colors manually?
Thank you for the video!
I'm trying to do this with a sphere, but it's not working. I followed all the steps, but nothing happen. Do you know what needs to change to make it work with a sphere?
can i use a raycast to change whatever image the ray hits to another image?
+Shawn Harvey absolutely, change the material in the renderer.
hello i got my ray cast working. however i'm wondering if i can use an image with a ray cast attached and have it hit an object with a public variable holding a image then pass that image to the image with my ray cast and assign it to its own image component. would this be a reliable and/or reusable code, and how should i go about approaching this ??
Yes this should be doable. You need do do a GetComponent on the object you hit and retrieve the image and place it as the image on the object you raycast from.
Thanks a lot
finally got that one done but can you tell me what im doing wrong here. this code im attempting to have some what of an inventory list and i want as a item is added to the list the value of that item is added displaying a total. it works when i add a second item but it doesn't record the first one.
Text putvalue;
string somenewaddvalue;
Text thistextcomponent;
public float putithere;
public float blahh;
void Start ()
{
thistextcomponent = GetComponent();
}
public void Addingthetotalpercart()
{
Imagechildfixer b = GetComponentInParent();
if (b != null)
{
putvalue = b.itemcost;
somenewaddvalue = putvalue.text;
blahh = float.Parse(somenewaddvalue);
putithere += blahh;
}
}
void Update ()
{
thistextcomponent.text = "Cart Total " + Math.Round(putithere, 2);
01:45 Too bad I'm not supposed to open it with Rider
texture not readable...:P
I got -1 index!
Check the color value you were looking for, it seems it isn't in the array of colors.
preview is really bad
TNX!