changed resource related stuff a bit