There is a considerably bug in CQueue. On line 96, it says: if obj.rear >= obj.front. This should be obj.rear >= obj.beg, as front points to the front object, not to the index of the front of the queue. This bug first occurs after the 100th element is added, because that is the default capacity.
Be warned; this script does not properly respect the bounds. In certain cases, it will select a point just outside of the bounds, due to a bug in the code (bounds are only taken into account when the fitness function is being evaluated, not when adding a step to the current best point).