Fix assets loading and rendering bugs