|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Re: detecting your own alliance(C++)
The double colon ("::") is a namespace operator. For example, one of the namespaces in C++ is the standard namespace, "std". So you could say,
"std::cout" etc since cout is in the std namespace. You could also say at the beginning of your program: "using namespace std;" This would allow you to implicitly refer to the std namespace. The dot operator is different. It allows you direct (non-pointer) access to data members of a class. For example, if you had some class Apple, you might have a call such as... "myApple.color" which could be red, yellow, greeen, etc. I don't fully understand jtdowney's code, since I am not at all familiar with the new interface, but this is the meaning of the dot operator versus double colon. |
|
#2
|
||||
|
||||
|
Re: detecting your own alliance(C++)
Okay, thanks. Also, how do you distinguish between the light of each alliance. I always thought they were identical. If that's true, make sure your camera is pointed forward at the beginning of the match and lock onto the first thing you see. It'll undoubtedly be an enemy robot. Then, never let it out of your sight. Autonomous is only 15s, so this should be fine.
|
|
#3
|
|||||
|
|||||
|
Re: detecting your own alliance(C++)
Quote:
|
|
#4
|
||||
|
||||
|
Re: detecting your own alliance(C++)
Couldn't you dect the other robot by the fact you you recieve there instructions but just ignore them since they arn't coded for IP
(that should work right, or it will let you know who is on the field with you) |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Make your own CNC | whytheheckme | Technical Discussion | 8 | 25-07-2007 02:13 |
| Your Own Team Siggies | Cujo | General Forum | 8 | 26-02-2005 16:01 |
| any of your regional "buddies" with your in your alliance? | Alex Cormier | Championship Event | 12 | 08-04-2004 04:20 |
| How do you tell whether your sensor is detecting a crate or the diamond plate? | Greg Ross | Technical Discussion | 4 | 13-01-2003 19:02 |
| Making your own gearbox? | ChaosMonkey | Motors | 15 | 25-05-2002 11:07 |