Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static List<AtlasRegion> extractRegionsByNames(TextureAtlas textureAtlas, List<String> regionNames) {
- LinkedList<AtlasRegion> regions = new LinkedList<>();
- for (String regionName : regionNames) {
- AtlasRegion region = textureAtlas.findRegion(regionName);
- if(region != null) {
- regions.add(region);
- }
- }
- return regions;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement