[Core/Components]: Fixes for logic errors

A sweeping series of fixes for logic errors, including significant issues with
the random number generators. Also some code cleanup around the constructors.

Signed-off-by: Sebastian Lenartowicz <slenarto@uoguelph.ca>
[Core]: More logic fixes

It finally works. I'm still not sure if everything works 100% as it's SUPPOSED
TO, but it works.

Signed-off-by: Sebastian Lenartowicz <slenarto@uoguelph.ca>