| 1 | package g0803.bindingofshiba.bundles; | |
| 2 | ||
| 3 | import g0803.bindingofshiba.textures.ITexture; | |
| 4 | import g0803.bindingofshiba.textures.ImageTextureBuilder; | |
| 5 | import g0803.bindingofshiba.textures.StaticTexture; | |
| 6 | import java.io.IOException; | |
| 7 | ||
| 8 | public class DefaultTexturesProvider implements BundleProvider<ITexture> { | |
| 9 | ||
| 10 | private final Bundle<ITexture> bundle = new HashMapBundle<>(); | |
| 11 | ||
| 12 | public DefaultTexturesProvider() throws IOException { | |
| 13 |
1
1. <init> : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadTextures → KILLED |
this.loadTextures(); |
| 14 | } | |
| 15 | ||
| 16 | @Override | |
| 17 | public Bundle<ITexture> getBundle() { | |
| 18 |
1
1. getBundle : replaced return value with null for g0803/bindingofshiba/bundles/DefaultTexturesProvider::getBundle → KILLED |
return bundle; |
| 19 | } | |
| 20 | ||
| 21 | private void loadTextures() throws IOException { | |
| 22 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadShibaTexture → KILLED |
this.loadShibaTexture(); |
| 23 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadRockTexture → KILLED |
this.loadRockTexture(); |
| 24 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadHudTexture → KILLED |
this.loadHudTexture(); |
| 25 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadHeartTexture → KILLED |
this.loadHeartTexture(); |
| 26 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadOpenRoomHorizontalWallsTextures → KILLED |
this.loadOpenRoomHorizontalWallsTextures(); |
| 27 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadOpenRoomVerticalWallsTextures → KILLED |
this.loadOpenRoomVerticalWallsTextures(); |
| 28 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadClosedRoomHorizontalWallsTextures → KILLED |
this.loadClosedRoomHorizontalWallsTextures(); |
| 29 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadClosedRoomVerticalWallsTextures → KILLED |
this.loadClosedRoomVerticalWallsTextures(); |
| 30 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadMonsterTextures → KILLED |
this.loadMonsterTextures(); |
| 31 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadMonsterAuraTextures → KILLED |
this.loadMonsterAuraTextures(); |
| 32 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadKeyTexture → KILLED |
this.loadKeyTexture(); |
| 33 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadHealthTextures → KILLED |
this.loadHealthTextures(); |
| 34 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadOpenDoorTextures → KILLED |
this.loadOpenDoorTextures(); |
| 35 |
1
1. loadTextures : removed call to g0803/bindingofshiba/bundles/DefaultTexturesProvider::loadClosedDoorTextures → KILLED |
this.loadClosedDoorTextures(); |
| 36 | } | |
| 37 | ||
| 38 | private void loadOpenDoorTextures() throws IOException { | |
| 39 | StaticTexture bottomTexture = | |
| 40 | new ImageTextureBuilder(3, 3) | |
| 41 | .loadResourceData("/textures/door/open.png") | |
| 42 | .setAnchorPoint(10, 1) | |
| 43 | .build(); | |
| 44 | ||
| 45 | StaticTexture leftTexture = bottomTexture.rotateRight(); | |
| 46 | StaticTexture topTexture = leftTexture.rotateRight(); | |
| 47 | StaticTexture rightTexture = topTexture.rotateRight(); | |
| 48 | ||
| 49 |
1
1. loadOpenDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.open.bottom", bottomTexture); |
| 50 |
1
1. loadOpenDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.open.left", leftTexture); |
| 51 |
1
1. loadOpenDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.open.top", topTexture); |
| 52 |
1
1. loadOpenDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.open.right", rightTexture); |
| 53 | } | |
| 54 | ||
| 55 | private void loadClosedDoorTextures() throws IOException { | |
| 56 | StaticTexture horizontalTexture = | |
| 57 | new ImageTextureBuilder(21, 3) | |
| 58 | .loadResourceData("/textures/door/closed.png") | |
| 59 | .setAnchorPoint(10, 1) | |
| 60 | .build(); | |
| 61 | ||
| 62 | StaticTexture verticalTexture = horizontalTexture.rotateRight(); | |
| 63 | ||
| 64 |
1
1. loadClosedDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.closed.bottom", horizontalTexture); |
| 65 |
1
1. loadClosedDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.closed.left", verticalTexture); |
| 66 |
1
1. loadClosedDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.closed.top", horizontalTexture); |
| 67 |
1
1. loadClosedDoorTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("door.closed.right", verticalTexture); |
| 68 | } | |
| 69 | ||
| 70 | private void loadHealthTextures() throws IOException { | |
| 71 | StaticTexture idleTexture = | |
| 72 | new ImageTextureBuilder(60, 3) | |
| 73 | .loadResourceData("/textures/health/idle.png") | |
| 74 | .setAnchorPoint(-79, -3) | |
| 75 | .build(); | |
| 76 | ||
| 77 | StaticTexture changingTexture = | |
| 78 | new ImageTextureBuilder(60, 3) | |
| 79 | .loadResourceData("/textures/health/changing.png") | |
| 80 | .setAnchorPoint(-79, -3) | |
| 81 | .build(); | |
| 82 | ||
| 83 |
1
1. loadHealthTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("health.idle", idleTexture); |
| 84 |
1
1. loadHealthTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("health.changing", changingTexture); |
| 85 | } | |
| 86 | ||
| 87 | private void loadKeyTexture() throws IOException { | |
| 88 | StaticTexture keyTexture = | |
| 89 | new ImageTextureBuilder(7, 3) | |
| 90 | .loadResourceData("/textures/key/horizontal.png") | |
| 91 | .setAnchorPoint(3, 1) | |
| 92 | .build(); | |
| 93 | ||
| 94 |
1
1. loadKeyTexture : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("key", keyTexture); |
| 95 | } | |
| 96 | ||
| 97 | private void loadMonsterTextures() throws IOException { | |
| 98 | StaticTexture normalTexture = | |
| 99 | new ImageTextureBuilder(10, 7) | |
| 100 | .loadResourceData("/textures/monster/normal.png") | |
| 101 | .setAnchorPoint(4, 6) | |
| 102 | .build(); | |
| 103 | ||
| 104 | StaticTexture damagedTexture = | |
| 105 | new ImageTextureBuilder(10, 7) | |
| 106 | .loadResourceData("/textures/monster/damaged.png") | |
| 107 | .setAnchorPoint(4, 6) | |
| 108 | .build(); | |
| 109 | ||
| 110 |
1
1. loadMonsterTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("monster.normal", normalTexture); |
| 111 |
1
1. loadMonsterTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("monster.damaged", damagedTexture); |
| 112 | } | |
| 113 | ||
| 114 | private void loadMonsterAuraTextures() throws IOException { | |
| 115 | StaticTexture idleTexture = | |
| 116 | new ImageTextureBuilder(24, 21) | |
| 117 | .loadResourceData("/textures/monster/aura/idle.png") | |
| 118 | .setAnchorPoint(11, 11) | |
| 119 | .build(); | |
| 120 | ||
| 121 | StaticTexture attackTexture = | |
| 122 | new ImageTextureBuilder(24, 21) | |
| 123 | .loadResourceData("/textures/monster/aura/attack.png") | |
| 124 | .setAnchorPoint(11, 11) | |
| 125 | .build(); | |
| 126 | ||
| 127 |
1
1. loadMonsterAuraTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("monster.aura.idle", idleTexture); |
| 128 |
1
1. loadMonsterAuraTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("monster.aura.attack", attackTexture); |
| 129 | } | |
| 130 | ||
| 131 | private void loadOpenRoomHorizontalWallsTextures() throws IOException { | |
| 132 | ImageTextureBuilder builder = | |
| 133 | new ImageTextureBuilder(143, 3) | |
| 134 | .loadResourceData("/textures/room/walls/open/horizontal.png"); | |
| 135 | ||
| 136 | StaticTexture topWallTexture = builder.setAnchorPoint(0, 0).build(); | |
| 137 | StaticTexture bottomWallTexture = builder.setAnchorPoint(0, -63).build(); | |
| 138 | ||
| 139 |
1
1. loadOpenRoomHorizontalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.open.top", topWallTexture); |
| 140 |
1
1. loadOpenRoomHorizontalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.open.bottom", bottomWallTexture); |
| 141 | } | |
| 142 | ||
| 143 | private void loadOpenRoomVerticalWallsTextures() throws IOException { | |
| 144 | ImageTextureBuilder builder = | |
| 145 | new ImageTextureBuilder(3, 66) | |
| 146 | .loadResourceData("/textures/room/walls/open/vertical.png"); | |
| 147 | ||
| 148 | StaticTexture leftWallTexture = builder.setAnchorPoint(0, 0).build(); | |
| 149 | StaticTexture rightWallTexture = builder.setAnchorPoint(-140, 0).build(); | |
| 150 | ||
| 151 |
1
1. loadOpenRoomVerticalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.open.left", leftWallTexture); |
| 152 |
1
1. loadOpenRoomVerticalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.open.right", rightWallTexture); |
| 153 | } | |
| 154 | ||
| 155 | private void loadClosedRoomVerticalWallsTextures() throws IOException { | |
| 156 | ImageTextureBuilder builder = | |
| 157 | new ImageTextureBuilder(3, 66) | |
| 158 | .loadResourceData("/textures/room/walls/closed/vertical.png"); | |
| 159 | ||
| 160 | StaticTexture leftWallTexture = builder.setAnchorPoint(0, 0).build(); | |
| 161 | StaticTexture rightWallTexture = builder.setAnchorPoint(-140, 0).build(); | |
| 162 | ||
| 163 |
1
1. loadClosedRoomVerticalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.closed.left", leftWallTexture); |
| 164 |
1
1. loadClosedRoomVerticalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.closed.right", rightWallTexture); |
| 165 | } | |
| 166 | ||
| 167 | private void loadClosedRoomHorizontalWallsTextures() throws IOException { | |
| 168 | ImageTextureBuilder builder = | |
| 169 | new ImageTextureBuilder(143, 3) | |
| 170 | .loadResourceData("/textures/room/walls/closed/horizontal.png"); | |
| 171 | ||
| 172 | StaticTexture topWallTexture = builder.setAnchorPoint(0, 0).build(); | |
| 173 | StaticTexture bottomWallTexture = builder.setAnchorPoint(0, -63).build(); | |
| 174 | ||
| 175 |
1
1. loadClosedRoomHorizontalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.closed.top", topWallTexture); |
| 176 |
1
1. loadClosedRoomHorizontalWallsTextures : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("room.walls.closed.bottom", bottomWallTexture); |
| 177 | } | |
| 178 | ||
| 179 | private void loadHeartTexture() throws IOException { | |
| 180 | StaticTexture heartTexture = | |
| 181 | new ImageTextureBuilder(5, 5) | |
| 182 | .loadResourceData("/textures/heart.png") | |
| 183 | .setAnchorPoint(2, 2) | |
| 184 | .build(); | |
| 185 | ||
| 186 |
1
1. loadHeartTexture : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("heart", heartTexture); |
| 187 | } | |
| 188 | ||
| 189 | private void loadHudTexture() throws IOException { | |
| 190 | StaticTexture hudTexture = | |
| 191 | new ImageTextureBuilder(143, 9) | |
| 192 | .loadResourceData("/textures/hud.png") | |
| 193 | .setAnchorPoint(0, 0) | |
| 194 | .build(); | |
| 195 | ||
| 196 |
1
1. loadHudTexture : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("hud", hudTexture); |
| 197 | } | |
| 198 | ||
| 199 | private void loadRockTexture() throws IOException { | |
| 200 | StaticTexture rockTexture = | |
| 201 | new ImageTextureBuilder(9, 3) | |
| 202 | .loadResourceData("/textures/rock.png") | |
| 203 | .setAnchorPoint(4, 2) | |
| 204 | .build(); | |
| 205 | ||
| 206 |
1
1. loadRockTexture : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("rock", rockTexture); |
| 207 | } | |
| 208 | ||
| 209 | private void loadShibaTexture() throws IOException { | |
| 210 | StaticTexture shibaTexture = | |
| 211 | new ImageTextureBuilder(9, 10) | |
| 212 | .loadResourceData("/textures/shiba.png") | |
| 213 | .setAnchorPoint(5, 9) | |
| 214 | .build(); | |
| 215 | ||
| 216 |
1
1. loadShibaTexture : removed call to g0803/bindingofshiba/bundles/Bundle::register → KILLED |
bundle.register("shiba", shibaTexture); |
| 217 | } | |
| 218 | } | |
Mutations | ||
| 13 |
1.1 |
|
| 18 |
1.1 |
|
| 22 |
1.1 |
|
| 23 |
1.1 |
|
| 24 |
1.1 |
|
| 25 |
1.1 |
|
| 26 |
1.1 |
|
| 27 |
1.1 |
|
| 28 |
1.1 |
|
| 29 |
1.1 |
|
| 30 |
1.1 |
|
| 31 |
1.1 |
|
| 32 |
1.1 |
|
| 33 |
1.1 |
|
| 34 |
1.1 |
|
| 35 |
1.1 |
|
| 49 |
1.1 |
|
| 50 |
1.1 |
|
| 51 |
1.1 |
|
| 52 |
1.1 |
|
| 64 |
1.1 |
|
| 65 |
1.1 |
|
| 66 |
1.1 |
|
| 67 |
1.1 |
|
| 83 |
1.1 |
|
| 84 |
1.1 |
|
| 94 |
1.1 |
|
| 110 |
1.1 |
|
| 111 |
1.1 |
|
| 127 |
1.1 |
|
| 128 |
1.1 |
|
| 139 |
1.1 |
|
| 140 |
1.1 |
|
| 151 |
1.1 |
|
| 152 |
1.1 |
|
| 163 |
1.1 |
|
| 164 |
1.1 |
|
| 175 |
1.1 |
|
| 176 |
1.1 |
|
| 186 |
1.1 |
|
| 196 |
1.1 |
|
| 206 |
1.1 |
|
| 216 |
1.1 |