Search found 190 matches

by cyboryxmen
May 24th, 2017, 9:08 pm
Forum: Everything
Topic: Noob looking for suggestions
Replies: 4
Views: 1957

Re: Noob looking for suggestions

You would find that Game Development is an entire different kind of beast compared to Embedded Programming. Though I would imagine your knowledge on the hardware will help significantly on your journey. I'm not completely sure of your background experience to say which video you can start off at but...
by cyboryxmen
May 24th, 2017, 4:11 pm
Forum: Everything
Topic: Constructor
Replies: 24
Views: 80079

Re: Constructor

Yeah pretty much. Though that function won't accept actual arrays and vice versa. For the most part, the simpleness of an array is more than enough for me but it is nice to have the ability to overload your function to accept both allowing it the flexibility to work with different code.
by cyboryxmen
May 24th, 2017, 10:09 am
Forum: Everything
Topic: Constructor
Replies: 24
Views: 80079

Re: Constructor

Which is why it's more useful with metaprogramming than normal programming. You can just let the compiler deduce the size. template<class Type, std::size_t SIZE> void ProcessArray ( const Type ( &arr ) [ SIZE ] ) { for ( std::size_t i = 0; i < SIZE; ++i ) { Process ( arr [ i ] ); } } int main ( ) { ...
by cyboryxmen
May 24th, 2017, 9:44 am
Forum: Everything
Topic: Constructor
Replies: 24
Views: 80079

Re: Constructor

I guess most people who don't do metaprogramming wouldn't have much knowledge nor use for array types. When you deal with arrays, they would usually decompose into pointers. However, you need to realise that arrays are not just pointers but are their very own type. Instead of decomposing them into p...
by cyboryxmen
May 24th, 2017, 9:16 am
Forum: Everything
Topic: Constructor
Replies: 24
Views: 80079

Re: Constructor

While we're at it, you can also set the default value of the member variable at the class declaration C# style. class Set { public: Set ( ) = default; Set ( int ( &set ) [ 10 ] ) : set_ { set [ 0 ], set [ 1 ], set [ 2 ], set [ 3 ], set [ 4 ], set [ 5 ], set [ 6 ], set [ 7 ], set [ 8 ], set [ 9 ] } {...
by cyboryxmen
May 24th, 2017, 8:50 am
Forum: Everything
Topic: Constructor
Replies: 24
Views: 80079

Re: Constructor

Also, you can totally initialize an array in the initialization list: constexpr Set ( ) : set_{ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 } { } Set ( ) : set_{ RandNum ( ), RandNum ( ), RandNum ( ), RandNum ( ), RandNum ( ), RandNum ( ), RandNum ( ), RandNum ( ), RandNum ( ), RandNum ( ) } { } This is from the C...
by cyboryxmen
May 24th, 2017, 4:26 am
Forum: Everything
Topic: Constructor
Replies: 24
Views: 80079

Re: Constructor

I personally prefer putting the list next to the signature:

Code: Select all

constexpr Vector3 ( const float x, const float y, const float z ) : x_ { x }, y_ { y }, z_ { z }
{
}
by cyboryxmen
May 5th, 2017, 3:18 am
Forum: Everything
Topic: Testing out website's support for foreign scripts
Replies: 4
Views: 1939

Re: Testing out website's support for foreign scripts

They way I usually type foreign scripts is that I type them out on my own editor then copy paste it here. It proved to be more convenient to do it that way rather than typing it directly in other people's editors that may not support foreign writing systems. The alignment is annoying but duable. It'...
by cyboryxmen
May 4th, 2017, 10:48 am
Forum: Everything
Topic: Testing out website's support for foreign scripts
Replies: 4
Views: 1939

Re: Testing out website's support for foreign scripts

Basically, I'm screwed if I ever type out any script that aligns to the right.
by cyboryxmen
May 4th, 2017, 10:24 am
Forum: Everything
Topic: Testing out website's support for foreign scripts
Replies: 4
Views: 1939

Re: Testing out website's support for foreign scripts

لم تكن حكايات شهرزاد في "ألف ليلة وليلة" مقصورة على الأطفال يسمعونها من أمهاتهم قبيل النوم، ولكنها كانت للصغار والكبار معا. ولا ننسى أن كثيرا من كتاب الرواية في العالم يحلمون أن يصلوا يوما إلى حدود الهالة السحرية التي تتمتع بها هذه الحكايات وجاذبيتها الفنية. وهنا نبدأ مع رحلات السندباد.