This is how I usually go about doing this.
I use a image editor called GraphicsGale.
https://www.humanbalance.net/gale/us/Then I take a screenshot in whatever game I want to rip the tileset from.
You can also get already made maps from a lot of games here wich speeds up the prossess.
https://vgmaps.com/The cool thing about GraphicsGale is you can set up a grid and use the snap to grid tool wich works perfectly for tilesets. Usually they are in 16x16.

Then with the cutter and snap to grid tool, drag and drop everything that looks useful down in one compact tileset. Try to arrange the tiles in a square.

Select all the tiles with the cutter tool and select "All Frames" and "Crop".

And finally, since these are 16x16 tiles you want to double the size. Use "All Frames" and "Resample". Then increase the size by 200% and uncheck smooth.

There you go, a 32x32 tileset. Save and import it into GameMaker.
Hope this helps. Good luck.