Fixed texture loading

Code written after a return doesn't execute!