Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

~1K People Reached
Favorite Forums
Favorite Tags
c++ x 9

4 Posted Topics

Member Avatar for fandango

I currently have a functor that finds the closest entity (by calculated distance) to the current entity. (Vector3 is just a 3D coordinate class) [CODE] template<typename T> class MinDistanceBGE { private: Vector3 v; // The location of the 'asking' entity. public: MinDistanceBGE(Vector3 vInput):v(vInput) {} bool operator()(T t1, T t2) const …

Member Avatar for fandango
0
377
Member Avatar for fandango

I'm looking for the best way to make a method available to a sub class (not talking inheritance, polymorphism at all, just standalone classes!) without handing down a million pointers to each sub class. [code] Class A; // contains many instances of other classes. Class Z; // one of those …

Member Avatar for Fbody
0
207
Member Avatar for fandango

I have a struct "Telegram" which contains a time offset, the Sender ID, the Receiver ID, and the Message itself: [CODE]struct Telegram { int Msg; // Message unsigned long Time; // Time offset (i.e., GetTicks() etc.) int Sender; // ID of Sender int Receiver; // ID of Receiver Telegram(int tMsg, …

Member Avatar for fandango
0
200
Member Avatar for fandango

I notice <vector> uses the constructor once and then uses the copy constructor for a class when creating all the other elements of a vector chain. So, if I have: [code] class MyClass { MyClass() { cout << "Constructor" << endl; } ~MyClass() { cout << "Deconstructor" << endl; } …

Member Avatar for Radical Edward
0
221

The End.