resources fix and offset fix