public class Object {
private Coord3D origin;
private double intensity; // In range [0..1]
public Light (Coord3D origin, double intensity) {
this.origin = origin;
this.intensity =...
Type: Posts; User: goochasauras
public class Object {
private Coord3D origin;
private double intensity; // In range [0..1]
public Light (Coord3D origin, double intensity) {
this.origin = origin;
this.intensity =...
Nah it isnt called object, im just generalizing the statement...but i checked out the constructor and it seems to be in the correct order and the parenthesis idea didnt work :(
I'm have trouble an object which has three integer values in it along with another parameter which is simply a double. This is my syntax atm:
Object newObject = new Object((1,-2,35),.5);
...
I edited to code so it is a little cleaner like you mentioned...but how do i get, in the while part of the statement, the program to loop until c or r are entered but still quitting when q is entered...
So i have a do while loop and i have user input coming in to detect which character the user entered...i want it to loop until the user enters a valid character...q or Q quits the program, whereas...
so what would be a good alternative to how I'm proceeding through this?
but i did create the variables at the beginning of main() and in the if statements i called functions and assigned the returned value to the variables..but as soon as i try to use those variables...
I added another line of code as an example of how I want to use it...it's at the bottom of Main()...but i get red squigglies saying the local variable may not have been initialized
i edited the statement and threw in a big wad of text, please if read through :)
As you are about to find out, I'm just picking up programming and I have a book in which I'm trying to complete a problem. I believe I'm having scope problems which I don't understand any assistance...