Finished assembler, more packets, sound tests, fluid tanks

This commit is contained in:
HbmMods 2017-07-17 19:55:18 +02:00
parent a4293ed222
commit 3889d4df80
39 changed files with 2809 additions and 1577 deletions

View File

@ -1,7 +1,8 @@
itemGroup.tabTest=Nuclear Tech Mod Test Tab
itemGroup.tabParts=Nuclear Tech Mod Bauteile
itemGroup.tabBlocks=Nuclear Tech Mod Blöcke
itemGroup.tabNuke=Nuclear Tech Mod Bomben
itemGroup.tabParts=NTM Ressourcen und Bauteile
itemGroup.tabBlocks=NTM Blöcke und Maschinen
itemGroup.tabNuke=NTM Bomben und Ausrüstung
itemGroup.tabMachine=NTM Vorlagen
achievement.getTitanium=Es ist ein Anfang
achievement.getTitanium.desc=Finde etwas Titanerz

View File

@ -1,7 +1,8 @@
itemGroup.tabTest=Nuclear Tech Mod Test Tab
itemGroup.tabParts=Nuclear Tech Mod Parts
itemGroup.tabBlocks=Nuclear Tech Mod Blocks
itemGroup.tabNuke=Nuclear Tech Mod Nukes
itemGroup.tabParts=NTM Resources and Parts
itemGroup.tabBlocks=NTM Blocks and Machines
itemGroup.tabNuke=NTM Bombs and Gear
itemGroup.tabMachine=NTM Templates
achievement.getTitanium=It's A Start
achievement.getTitanium.desc=Collect titanium ore

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,645 @@
# Blender v2.76 (sub 0) OBJ File: 'assembler_wheel.blend'
# www.blender.org
o Cylinder
v 0.000000 1.162500 -0.750000
v 0.000000 1.537500 -0.750000
v 0.194114 1.162500 -0.724444
v 0.194114 1.537500 -0.724444
v 0.375000 1.162500 -0.649519
v 0.375000 1.537500 -0.649519
v 0.530330 1.162500 -0.530330
v 0.530330 1.537500 -0.530330
v 0.649519 1.162500 -0.375000
v 0.649519 1.537500 -0.375000
v 0.724444 1.162500 -0.194114
v 0.724444 1.537500 -0.194114
v 0.750000 1.162500 -0.000000
v 0.750000 1.537500 -0.000000
v 0.724444 1.162500 0.194114
v 0.724444 1.537500 0.194114
v 0.649519 1.162500 0.375000
v 0.649519 1.537500 0.375000
v 0.530330 1.162500 0.530330
v 0.530330 1.537500 0.530330
v 0.375000 1.162500 0.649519
v 0.375000 1.537500 0.649519
v 0.194115 1.162500 0.724444
v 0.194115 1.537500 0.724444
v 0.000000 1.162500 0.750000
v 0.000000 1.537500 0.750000
v -0.194114 1.162500 0.724444
v -0.194114 1.537500 0.724444
v -0.375000 1.162500 0.649519
v -0.375000 1.537500 0.649519
v -0.530330 1.162500 0.530330
v -0.530330 1.537500 0.530330
v -0.649519 1.162500 0.375000
v -0.649519 1.537500 0.375000
v -0.724444 1.162500 0.194115
v -0.724444 1.537500 0.194115
v -0.750000 1.162500 0.000000
v -0.750000 1.537500 0.000000
v -0.724444 1.162500 -0.194114
v -0.724444 1.537500 -0.194114
v -0.649519 1.162500 -0.375000
v -0.649519 1.537500 -0.375000
v -0.530330 1.162500 -0.530330
v -0.530330 1.537500 -0.530330
v -0.375000 1.162500 -0.649519
v -0.375000 1.537500 -0.649519
v -0.194115 1.162500 -0.724444
v -0.194115 1.537500 -0.724444
v 0.000000 1.162500 -0.562500
v 0.000000 1.537500 -0.562500
v 0.145586 1.162500 -0.543333
v 0.145586 1.537500 -0.543333
v 0.281250 1.162500 -0.487139
v 0.281250 1.537500 -0.487139
v 0.397748 1.162500 -0.397748
v 0.397748 1.537500 -0.397748
v 0.487139 1.162500 -0.281250
v 0.487139 1.537500 -0.281250
v 0.543333 1.162500 -0.145586
v 0.543333 1.537500 -0.145586
v 0.562500 1.162500 -0.000000
v 0.562500 1.537500 -0.000000
v 0.543333 1.162500 0.145586
v 0.543333 1.537500 0.145586
v 0.487139 1.162500 0.281250
v 0.487139 1.537500 0.281250
v 0.397748 1.162500 0.397747
v 0.397748 1.537500 0.397747
v 0.281250 1.162500 0.487139
v 0.281250 1.537500 0.487139
v 0.145586 1.162500 0.543333
v 0.145586 1.537500 0.543333
v 0.000000 1.162500 0.562500
v 0.000000 1.537500 0.562500
v -0.145585 1.162500 0.543333
v -0.145585 1.537500 0.543333
v -0.281250 1.162500 0.487139
v -0.281250 1.537500 0.487139
v -0.397747 1.162500 0.397748
v -0.397747 1.537500 0.397748
v -0.487139 1.162500 0.281250
v -0.487139 1.537500 0.281250
v -0.543333 1.162500 0.145586
v -0.543333 1.537500 0.145586
v -0.562500 1.162500 0.000000
v -0.562500 1.537500 0.000000
v -0.543333 1.162500 -0.145585
v -0.543333 1.537500 -0.145585
v -0.487139 1.162500 -0.281250
v -0.487139 1.537500 -0.281250
v -0.397748 1.162500 -0.397747
v -0.397748 1.537500 -0.397747
v -0.281250 1.162500 -0.487139
v -0.281250 1.537500 -0.487139
v -0.145586 1.162500 -0.543333
v -0.145586 1.537500 -0.543333
v 0.000000 1.537500 -0.281250
v 0.072793 1.537500 -0.271667
v 0.140625 1.537500 -0.243570
v 0.198874 1.537500 -0.198874
v 0.243570 1.537500 -0.140625
v 0.271667 1.537500 -0.072793
v 0.281250 1.537500 0.000000
v 0.271667 1.537500 0.072793
v 0.243570 1.537500 0.140625
v 0.198874 1.537500 0.198874
v 0.140625 1.537500 0.243570
v 0.072793 1.537500 0.271667
v 0.000000 1.537500 0.281250
v -0.072793 1.537500 0.271667
v -0.140625 1.537500 0.243570
v -0.198874 1.537500 0.198874
v -0.243570 1.537500 0.140625
v -0.271667 1.537500 0.072793
v -0.281250 1.537500 0.000000
v -0.271667 1.537500 -0.072793
v -0.243570 1.537500 -0.140625
v -0.198874 1.537500 -0.198874
v -0.140625 1.537500 -0.243569
v -0.072793 1.537500 -0.271667
v 0.000000 1.287500 0.281250
v 0.072793 1.287500 0.271667
v 0.140625 1.287500 0.243570
v 0.198874 1.287500 0.198874
v 0.243570 1.287500 0.140625
v 0.271667 1.287500 0.072793
v 0.281250 1.287500 0.000000
v 0.271667 1.287500 -0.072793
v 0.243570 1.287500 -0.140625
v 0.198874 1.287500 -0.198874
v 0.140625 1.287500 -0.243570
v 0.072793 1.287500 -0.271667
v 0.000000 1.287500 -0.281250
v -0.072793 1.287500 0.271667
v -0.140625 1.287500 0.243570
v -0.198874 1.287500 0.198874
v -0.243570 1.287500 0.140625
v -0.271667 1.287500 0.072793
v -0.281250 1.287500 0.000000
v -0.271667 1.287500 -0.072793
v -0.243570 1.287500 -0.140625
v -0.198874 1.287500 -0.198874
v -0.140625 1.287500 -0.243569
v -0.072793 1.287500 -0.271667
vt 0.190885 0.497428
vt 0.190885 0.622697
vt 0.128251 0.622697
vt 0.607699 0.748393
vt 0.542295 0.748393
vt 0.542295 0.623125
vt 0.062848 0.622697
vt 0.000214 0.622697
vt 0.000214 0.497429
vt 0.367975 0.748393
vt 0.302572 0.748393
vt 0.302572 0.623125
vt 0.670333 0.748821
vt 0.670333 0.874089
vt 0.607699 0.874089
vt 0.128251 0.748393
vt 0.062848 0.748393
vt 0.062848 0.623125
vt 0.542296 0.874090
vt 0.479662 0.874090
vt 0.479662 0.748821
vt 0.607699 0.999786
vt 0.542296 0.999786
vt 0.542296 0.874518
vt 0.430609 0.748821
vt 0.430609 0.874090
vt 0.367975 0.874090
vt 0.367975 0.999786
vt 0.302572 0.999786
vt 0.302572 0.874518
vt 0.302572 0.874090
vt 0.239938 0.874090
vt 0.239938 0.748821
vt 0.128251 0.999786
vt 0.062848 0.999786
vt 0.062848 0.874518
vt 0.190886 0.748821
vt 0.190886 0.874090
vt 0.128251 0.874089
vt 0.607699 0.622697
vt 0.542295 0.622697
vt 0.542295 0.497428
vt 0.000214 0.874089
vt 0.000214 0.748821
vt 0.062848 0.748821
vt 0.367975 0.622697
vt 0.302572 0.622697
vt 0.302572 0.497428
vt 0.670333 0.623125
vt 0.670333 0.748393
vt 0.062848 0.497429
vt 0.479661 0.748393
vt 0.479661 0.623125
vt 0.542296 0.748821
vt 0.430609 0.623125
vt 0.430609 0.748393
vt 0.302572 0.748821
vt 0.176700 0.075008
vt 0.134220 0.099534
vt 0.096090 0.049843
vt 0.062848 0.874089
vt 0.239938 0.748393
vt 0.049843 0.096090
vt 0.099534 0.134219
vt 0.075008 0.176700
vt 0.719385 0.748393
vt 0.190885 0.748393
vt 0.128251 0.623125
vt 0.000214 0.748393
vt 0.190885 0.623125
vt 0.670333 0.999786
vt 0.607699 0.874518
vt 0.719385 0.999786
vt 0.670333 0.874518
vt 0.479661 0.999786
vt 0.479661 0.874518
vt 0.430609 0.999786
vt 0.430609 0.874518
vt 0.239938 0.999786
vt 0.190885 0.999786
vt 0.190885 0.874518
vt 0.239938 0.874518
vt 0.719385 0.622697
vt 0.670333 0.622697
vt 0.670333 0.497428
vt 0.239938 0.622697
vt 0.239938 0.497428
vt 0.479661 0.622697
vt 0.430609 0.622697
vt 0.430609 0.497428
vt 0.000214 0.999786
vt 0.000214 0.874518
vt 0.719385 0.874089
vt 0.479661 0.497428
vt 0.323144 0.191413
vt 0.397680 0.134219
vt 0.422206 0.176700
vt 0.273133 0.062312
vt 0.224081 0.062312
vt 0.215906 0.000214
vt 0.362995 0.099534
vt 0.320514 0.075008
vt 0.344483 0.017142
vt 0.480073 0.152731
vt 0.434902 0.224081
vt 0.497000 0.215905
vt 0.497000 0.281309
vt 0.397680 0.362995
vt 0.422206 0.320514
vt 0.480073 0.344483
vt 0.362995 0.397680
vt 0.401124 0.447371
vt 0.344484 0.480073
vt 0.224081 0.434902
vt 0.273133 0.434902
vt 0.281309 0.497000
vt 0.134219 0.397680
vt 0.176700 0.422206
vt 0.152731 0.480073
vt 0.017142 0.344483
vt 0.075008 0.320514
vt 0.099534 0.362995
vt 0.062312 0.224081
vt 0.062312 0.273133
vt 0.000214 0.281309
vt 0.305801 0.174071
vt 0.521955 0.167717
vt 0.521955 0.084205
vt 0.546481 0.084205
vt 0.546481 0.335598
vt 0.546481 0.252086
vt 0.571007 0.252086
vt 0.497428 0.251658
vt 0.497428 0.168145
vt 0.521955 0.168145
vt 0.571007 0.083752
vt 0.571036 0.000239
vt 0.595562 0.000248
vt 0.546481 0.167717
vt 0.571007 0.084205
vt 0.521955 0.251658
vt 0.546481 0.168145
vt 0.571007 0.335598
vt 0.595533 0.252086
vt 0.571007 0.167717
vt 0.595533 0.084205
vt 0.595533 0.083760
vt 0.620088 0.000256
vt 0.546481 0.251658
vt 0.571007 0.168145
vt 0.595533 0.167717
vt 0.620059 0.084205
vt 0.595533 0.335598
vt 0.620059 0.252086
vt 0.571007 0.251658
vt 0.595533 0.168145
vt 0.620059 0.083769
vt 0.644614 0.000265
vt 0.620059 0.167717
vt 0.644585 0.084205
vt 0.497428 0.083726
vt 0.497457 0.000214
vt 0.521983 0.000223
vt 0.595533 0.251658
vt 0.620059 0.168145
vt 0.620059 0.335598
vt 0.644585 0.252086
vt 0.497428 0.335598
vt 0.497428 0.252086
vt 0.521955 0.252086
vt 0.620059 0.251658
vt 0.644585 0.168145
vt 0.521955 0.083735
vt 0.546510 0.000231
vt 0.497428 0.167717
vt 0.497428 0.084205
vt 0.521955 0.335598
vt 0.546481 0.083743
vt 0.341755 0.236344
vt 0.335407 0.212654
vt 0.434902 0.273133
vt 0.341755 0.260870
vt 0.335407 0.284561
vt 0.323144 0.305801
vt 0.305801 0.323144
vt 0.284561 0.335407
vt 0.260870 0.341754
vt 0.320514 0.422206
vt 0.236344 0.341754
vt 0.212654 0.335407
vt 0.191413 0.323144
vt 0.174071 0.305801
vt 0.161808 0.284561
vt 0.155460 0.260870
vt 0.155460 0.236344
vt 0.161808 0.212653
vt 0.174071 0.191413
vt 0.191413 0.174071
vt 0.212654 0.161807
vt 0.236344 0.155460
vt 0.260870 0.155460
vt 0.284561 0.161808
vt 0.128251 0.497428
vt 0.607699 0.623125
vt 0.367975 0.623125
vt 0.607699 0.748821
vt 0.367975 0.748821
vt 0.367975 0.874518
vt 0.128251 0.874518
vt 0.128251 0.748821
vt 0.607699 0.497428
vt 0.367975 0.497428
vt 0.152731 0.017142
vt 0.239938 0.623125
vt 0.017142 0.152731
vt 0.719385 0.623125
vt 0.000214 0.623125
vt 0.719385 0.874518
vt 0.719385 0.497428
vt 0.719385 0.748821
vt 0.281309 0.000214
vt 0.401124 0.049843
vt 0.447371 0.096090
vt 0.447371 0.401124
vt 0.215906 0.497000
vt 0.096090 0.447371
vt 0.049843 0.401124
vt 0.000214 0.215905
vt 0.644585 0.083777
vt 0.644585 0.167717
vt 0.644585 0.335598
vt 0.644585 0.251658
vn 0.258800 0.000000 0.965900
vn 0.382700 0.000000 -0.923900
vn -0.000000 0.000000 -1.000000
vn 0.793400 0.000000 -0.608800
vn -0.258800 0.000000 0.965900
vn 0.991400 0.000000 -0.130500
vn 0.500000 0.000000 -0.866000
vn 0.923900 0.000000 0.382700
vn -0.707100 0.000000 0.707100
vn 0.608800 0.000000 0.793400
vn 0.866000 0.000000 -0.500000
vn 0.130500 0.000000 0.991400
vn -0.965900 0.000000 0.258800
vn -0.382700 0.000000 0.923900
vn 1.000000 0.000000 -0.000000
vn -0.793400 0.000000 0.608800
vn -0.965900 0.000000 -0.258800
vn -0.991400 0.000000 0.130500
vn 0.866000 0.000000 0.500000
vn -0.923900 0.000000 -0.382700
vn -0.707100 0.000000 -0.707100
vn -0.608800 0.000000 -0.793400
vn 0.000000 1.000000 -0.000000
vn -0.130500 0.000000 -0.991400
vn 0.500000 0.000000 0.866000
vn 0.130500 0.000000 -0.991400
vn -0.258800 0.000000 -0.965900
vn 0.608800 0.000000 -0.793400
vn 0.000000 0.000000 1.000000
vn 0.923900 0.000000 -0.382700
vn 0.258800 0.000000 -0.965900
vn 0.991400 0.000000 0.130500
vn -0.500000 0.000000 0.866000
vn 0.793400 0.000000 0.608800
vn 0.707100 0.000000 -0.707100
vn 0.382700 0.000000 0.923900
vn -0.866000 0.000000 0.500000
vn -0.130500 0.000000 0.991400
vn -0.500000 0.000000 -0.866000
vn -0.608800 0.000000 0.793400
vn 0.965900 0.000000 -0.258800
vn -0.923900 0.000000 0.382700
vn -1.000000 0.000000 0.000000
vn -0.991400 0.000000 -0.130500
vn 0.965900 0.000000 0.258800
vn -0.793400 0.000000 -0.608800
vn -0.866000 0.000000 -0.500000
vn 0.707100 0.000000 0.707100
vn -0.382700 0.000000 -0.923900
s off
f 83/1/1 84/2/1 36/3/1
f 4/4/2 6/5/2 5/6/2
f 38/7/3 86/8/3 85/9/3
f 8/10/4 10/11/4 9/12/4
f 87/13/5 88/14/5 40/15/5
f 12/16/6 14/17/6 13/18/6
f 42/19/7 90/20/7 89/21/7
f 16/22/8 18/23/8 17/24/8
f 91/25/9 92/26/9 44/27/9
f 20/28/10 22/29/10 21/30/10
f 46/31/11 94/32/11 93/33/11
f 24/34/12 26/35/12 25/36/12
f 95/37/13 96/38/13 48/39/13
f 28/40/14 30/41/14 29/42/14
f 50/43/15 49/44/15 1/45/15
f 32/46/16 34/47/16 33/48/16
f 51/49/17 52/50/17 4/4/17
f 36/3/18 38/7/18 37/51/18
f 6/5/19 54/52/19 53/53/19
f 40/15/20 42/19/20 41/54/20
f 55/55/21 56/56/21 8/10/21
f 44/27/22 46/31/22 45/57/22
f 80/58/23 82/59/23 34/60/23
f 48/39/24 2/61/24 1/45/24
f 9/12/25 10/11/25 58/62/25
f 36/63/23 84/64/23 86/65/23
f 50/66/26 52/50/26 51/49/26
f 60/67/27 12/16/27 11/68/27
f 54/52/28 56/56/28 55/55/28
f 13/18/29 14/17/29 62/69/29
f 58/62/30 60/67/30 59/70/30
f 64/71/31 16/22/31 15/72/31
f 62/73/32 64/71/32 63/74/32
f 18/23/33 66/75/33 65/76/33
f 66/75/34 68/77/34 67/78/34
f 67/78/35 68/77/35 20/28/35
f 70/79/36 72/80/36 71/81/36
f 22/29/37 70/79/37 69/82/37
f 74/83/38 76/84/38 75/85/38
f 34/47/39 82/86/39 81/87/39
f 78/88/40 80/89/40 79/90/40
f 71/81/41 72/80/41 24/34/41
f 82/86/42 84/2/42 83/1/42
f 26/35/43 74/91/43 73/92/43
f 86/93/44 88/14/44 87/13/44
f 75/85/45 76/84/45 28/40/45
f 90/20/46 92/26/46 91/25/46
f 30/41/47 78/88/47 77/94/47
f 79/90/48 80/89/48 32/46/48
f 94/32/49 96/38/49 95/37/49
f 107/95/23 70/96/23 68/97/23
f 76/98/23 78/99/23 30/100/23
f 72/101/23 74/102/23 26/103/23
f 20/104/23 68/97/23 70/96/23
f 66/105/23 18/106/23 16/107/23
f 60/108/23 62/109/23 14/110/23
f 58/111/23 10/112/23 8/113/23
f 52/114/23 54/115/23 6/116/23
f 96/117/23 50/118/23 2/119/23
f 44/120/23 92/121/23 94/122/23
f 88/123/23 90/124/23 42/125/23
f 108/126/23 72/101/23 70/96/23
f 116/127/8 140/128/8 141/129/8
f 105/130/46 125/131/46 124/132/46
f 109/133/26 121/134/26 134/135/26
f 100/136/16 130/137/16 129/138/16
f 117/139/34 141/129/34 142/140/34
f 110/141/2 134/135/2 135/142/2
f 106/143/22 124/132/22 123/144/22
f 118/145/10 142/140/10 143/146/10
f 101/147/42 129/138/42 128/148/42
f 111/149/28 135/142/28 136/150/28
f 119/151/36 143/146/36 144/152/36
f 107/153/49 123/144/49 122/154/49
f 112/155/4 136/150/4 137/156/4
f 102/157/18 128/148/18 127/158/18
f 120/159/12 144/152/12 133/160/12
f 97/161/38 133/162/38 132/163/38
f 113/164/30 137/156/30 138/165/30
f 108/166/24 122/154/24 121/167/24
f 103/168/44 127/169/44 126/170/44
f 114/171/6 138/165/6 139/172/6
f 98/173/14 132/163/14 131/174/14
f 115/175/32 139/176/32 140/128/32
f 104/177/20 126/170/20 125/131/20
f 99/178/40 131/174/40 130/137/40
f 105/179/23 106/180/23 68/97/23
f 64/181/23 104/182/23 105/179/23
f 103/183/23 104/182/23 64/181/23
f 102/184/23 103/183/23 62/109/23
f 101/185/23 102/184/23 60/108/23
f 100/186/23 101/185/23 58/111/23
f 99/187/23 100/186/23 56/188/23
f 52/114/23 98/189/23 99/187/23
f 97/190/23 98/189/23 52/114/23
f 120/191/23 97/190/23 50/118/23
f 119/192/23 120/191/23 96/117/23
f 118/193/23 119/192/23 94/122/23
f 117/194/23 118/193/23 92/121/23
f 116/195/23 117/194/23 90/124/23
f 115/196/23 116/195/23 88/123/23
f 84/64/23 114/197/23 115/196/23
f 82/59/23 113/198/23 114/197/23
f 112/199/23 113/198/23 82/59/23
f 78/99/23 111/200/23 112/199/23
f 110/201/23 111/200/23 78/99/23
f 74/102/23 109/202/23 110/201/23
f 108/126/23 109/202/23 74/102/23
f 35/203/1 83/1/1 36/3/1
f 3/204/2 4/4/2 5/6/2
f 37/51/3 38/7/3 85/9/3
f 7/205/4 8/10/4 9/12/4
f 39/206/5 87/13/5 40/15/5
f 11/68/6 12/16/6 13/18/6
f 41/54/7 42/19/7 89/21/7
f 15/72/8 16/22/8 17/24/8
f 43/207/9 91/25/9 44/27/9
f 19/208/10 20/28/10 21/30/10
f 45/57/11 46/31/11 93/33/11
f 23/209/12 24/34/12 25/36/12
f 47/210/13 95/37/13 48/39/13
f 27/211/14 28/40/14 29/42/14
f 2/61/15 50/43/15 1/45/15
f 31/212/16 32/46/16 33/48/16
f 3/204/17 51/49/17 4/4/17
f 35/203/18 36/3/18 37/51/18
f 5/6/19 6/5/19 53/53/19
f 39/206/20 40/15/20 41/54/20
f 7/205/21 55/55/21 8/10/21
f 43/207/22 44/27/22 45/57/22
f 32/213/23 80/58/23 34/60/23
f 47/210/24 48/39/24 1/45/24
f 57/214/25 9/12/25 58/62/25
f 38/215/23 36/63/23 86/65/23
f 49/216/26 50/66/26 51/49/26
f 59/70/27 60/67/27 11/68/27
f 53/53/28 54/52/28 55/55/28
f 61/217/29 13/18/29 62/69/29
f 57/214/30 58/62/30 59/70/30
f 63/74/31 64/71/31 15/72/31
f 61/218/32 62/73/32 63/74/32
f 17/24/33 18/23/33 65/76/33
f 65/76/34 66/75/34 67/78/34
f 19/208/35 67/78/35 20/28/35
f 69/82/36 70/79/36 71/81/36
f 21/30/37 22/29/37 69/82/37
f 73/219/38 74/83/38 75/85/38
f 33/48/39 34/47/39 81/87/39
f 77/94/40 78/88/40 79/90/40
f 23/209/41 71/81/41 24/34/41
f 81/87/42 82/86/42 83/1/42
f 25/36/43 26/35/43 73/92/43
f 85/220/44 86/93/44 87/13/44
f 27/211/45 75/85/45 28/40/45
f 89/21/46 90/20/46 91/25/46
f 29/42/47 30/41/47 77/94/47
f 31/212/48 79/90/48 32/46/48
f 93/33/49 94/32/49 95/37/49
f 106/180/23 107/95/23 68/97/23
f 28/221/23 76/98/23 30/100/23
f 24/222/23 72/101/23 26/103/23
f 22/223/23 20/104/23 70/96/23
f 64/181/23 66/105/23 16/107/23
f 12/224/23 60/108/23 14/110/23
f 56/188/23 58/111/23 8/113/23
f 4/225/23 52/114/23 6/116/23
f 48/226/23 96/117/23 2/119/23
f 46/227/23 44/120/23 94/122/23
f 40/228/23 88/123/23 42/125/23
f 107/95/23 108/126/23 70/96/23
f 117/139/8 116/127/8 141/129/8
f 106/143/46 105/130/46 124/132/46
f 110/141/26 109/133/26 134/135/26
f 101/147/16 100/136/16 129/138/16
f 118/145/34 117/139/34 142/140/34
f 111/149/2 110/141/2 135/142/2
f 107/153/22 106/143/22 123/144/22
f 119/151/10 118/145/10 143/146/10
f 102/157/42 101/147/42 128/148/42
f 112/155/28 111/149/28 136/150/28
f 120/159/36 119/151/36 144/152/36
f 108/166/49 107/153/49 122/154/49
f 113/164/4 112/155/4 137/156/4
f 103/229/18 102/157/18 127/158/18
f 97/230/12 120/159/12 133/160/12
f 98/173/38 97/161/38 132/163/38
f 114/171/30 113/164/30 138/165/30
f 109/231/24 108/166/24 121/167/24
f 104/177/44 103/168/44 126/170/44
f 115/232/6 114/171/6 139/172/6
f 99/178/14 98/173/14 131/174/14
f 116/127/32 115/175/32 140/128/32
f 105/130/20 104/177/20 125/131/20
f 100/136/40 99/178/40 130/137/40
f 66/105/23 105/179/23 68/97/23
f 66/105/23 64/181/23 105/179/23
f 62/109/23 103/183/23 64/181/23
f 60/108/23 102/184/23 62/109/23
f 58/111/23 101/185/23 60/108/23
f 56/188/23 100/186/23 58/111/23
f 54/115/23 99/187/23 56/188/23
f 54/115/23 52/114/23 99/187/23
f 50/118/23 97/190/23 52/114/23
f 96/117/23 120/191/23 50/118/23
f 94/122/23 119/192/23 96/117/23
f 92/121/23 118/193/23 94/122/23
f 90/124/23 117/194/23 92/121/23
f 88/123/23 116/195/23 90/124/23
f 86/65/23 115/196/23 88/123/23
f 86/65/23 84/64/23 115/196/23
f 84/64/23 82/59/23 114/197/23
f 80/58/23 112/199/23 82/59/23
f 80/58/23 78/99/23 112/199/23
f 76/98/23 110/201/23 78/99/23
f 76/98/23 74/102/23 110/201/23
f 72/101/23 108/126/23 74/102/23

View File

@ -6,6 +6,7 @@
"block.crateBreak": {"category": "block", "sounds": ["block/crateBreak1", "block/crateBreak2", "block/crateBreak3", "block/crateBreak4", "block/crateBreak5"]},
"block.shutdown": {"category": "block", "sounds": [{"name": "block/shutdown", "stream": false}]},
"block.minerOperate": {"category": "block", "sounds": [{"name": "block/minerOperate", "stream": false}]},
"item.techBleep": {"category": "player", "sounds": [{"name": "tool/techBleep", "stream": false}]},
"item.techBoop": {"category": "player", "sounds": [{"name": "tool/techBoop", "stream": false}]},

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 275 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 368 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 321 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 542 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 570 KiB

After

Width:  |  Height:  |  Size: 569 KiB

View File

@ -357,23 +357,6 @@ public class ModBlocks {
public static final int guiID_machine_assembler = 48;
public static Block launch_pad;
public static Block launch_pad_generic;
public static Block launch_pad_incendiary;
public static Block launch_pad_cluster;
public static Block launch_pad_buster;
public static Block launch_pad_strong;
public static Block launch_pad_incendiary_strong;
public static Block launch_pad_cluster_strong;
public static Block launch_pad_buster_strong;
public static Block launch_pad_burst;
public static Block launch_pad_inferno;
public static Block launch_pad_rain;
public static Block launch_pad_drill;
public static Block launch_pad_nuclear;
public static Block launch_pad_endo;
public static Block launch_pad_exo;
public static Block launch_pad_mirv;
public static Block launch_pad_anti;
public static final int guiID_launch_pad = 19;
public static Block book_guide;
@ -668,23 +651,6 @@ public class ModBlocks {
marker_structure = new BlockMarker(Material.iron).setBlockName("marker_structure").setHardness(0.0F).setResistance(0.0F).setLightLevel(1.0F).setCreativeTab(MainRegistry.tabBlock).setBlockTextureName(RefStrings.MODID + ":marker_structure");
launch_pad = new LaunchPad(Material.iron).setBlockName("launch_pad").setHardness(5.0F).setResistance(10.0F).setCreativeTab(MainRegistry.tabNuke).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_generic = new LaunchPad(Material.iron).setBlockName("launch_pad_generic").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_incendiary = new LaunchPad(Material.iron).setBlockName("launch_pad_incendiary").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_cluster = new LaunchPad(Material.iron).setBlockName("launch_pad_cluster").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_buster = new LaunchPad(Material.iron).setBlockName("launch_pad_buster").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_strong = new LaunchPad(Material.iron).setBlockName("launch_pad_strong").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_incendiary_strong = new LaunchPad(Material.iron).setBlockName("launch_pad_incendiary_strong").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_cluster_strong = new LaunchPad(Material.iron).setBlockName("launch_pad_cluster_strong").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_buster_strong = new LaunchPad(Material.iron).setBlockName("launch_pad_buster_strong").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_burst = new LaunchPad(Material.iron).setBlockName("launch_pad_burst").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_inferno = new LaunchPad(Material.iron).setBlockName("launch_pad_inferno").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_rain = new LaunchPad(Material.iron).setBlockName("launch_pad_rain").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_drill = new LaunchPad(Material.iron).setBlockName("launch_pad_drill").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_nuclear = new LaunchPad(Material.iron).setBlockName("launch_pad_nuclear").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_endo = new LaunchPad(Material.iron).setBlockName("launch_pad_endo").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_exo = new LaunchPad(Material.iron).setBlockName("launch_pad_exo").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_mirv = new LaunchPad(Material.iron).setBlockName("launch_pad_mirv").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
launch_pad_anti = new LaunchPad(Material.iron).setBlockName("launch_pad_anti").setHardness(5.0F).setResistance(10.0F).setBlockTextureName(RefStrings.MODID + ":launch_pad");
book_guide = new Guide(Material.iron).setBlockName("book_guide").setHardness(5.0F).setResistance(10.0F).setCreativeTab(MainRegistry.tabNuke);
@ -1001,23 +967,6 @@ public class ModBlocks {
//Launch Pads
GameRegistry.registerBlock(launch_pad, launch_pad.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_generic, launch_pad_generic.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_incendiary, launch_pad_incendiary.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_cluster, launch_pad_cluster.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_buster, launch_pad_buster.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_strong, launch_pad_strong.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_incendiary_strong, launch_pad_incendiary_strong.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_cluster_strong, launch_pad_cluster_strong.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_buster_strong, launch_pad_buster_strong.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_burst, launch_pad_burst.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_inferno, launch_pad_inferno.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_rain, launch_pad_rain.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_drill, launch_pad_drill.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_nuclear, launch_pad_nuclear.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_endo, launch_pad_endo.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_exo, launch_pad_exo.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_mirv, launch_pad_mirv.getUnlocalizedName());
GameRegistry.registerBlock(launch_pad_anti, launch_pad_anti.getUnlocalizedName());
//Guide
GameRegistry.registerBlock(book_guide, book_guide.getUnlocalizedName());

View File

@ -179,74 +179,6 @@ public class LaunchPad extends BlockContainer implements IBomb {
world.setBlockMetadataWithNotify(x, y, z, 2, 2);
}
}
public static void updateBlockState(int type, World world, int x, int y, int z) {
int i = world.getBlockMetadata(x, y, z);
TileEntity entity = world.getTileEntity(x, y, z);
keepInventory = true;
if(type == 1)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_generic);
} else if(type == 2)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_strong);
} else if(type == 3)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_cluster);
} else if(type == 4)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_nuclear);
} else if(type == 5)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_incendiary);
} else if(type == 6)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_buster);
} else if(type == 7)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_incendiary_strong);
} else if(type == 8)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_cluster_strong);
} else if(type == 9)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_buster_strong);
} else if(type == 10)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_burst);
} else if(type == 11)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_inferno);
} else if(type == 12)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_rain);
} else if(type == 13)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_drill);
} else if(type == 14)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_endo);
} else if(type == 15)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_exo);
} else if(type == 16)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_mirv);
} else if(type == 17)
{
world.setBlock(x, y, z, ModBlocks.launch_pad_anti);
} else {
world.setBlock(x, y, z, ModBlocks.launch_pad);
}
keepInventory = false;
if(entity != null) {
entity.validate();
world.setTileEntity(x, y, z, entity);
}
}
@Override
public void setBlockBoundsBasedOnState(IBlockAccess p_149719_1_, int p_149719_2_, int p_149719_3_, int p_149719_4_)

View File

@ -11,6 +11,7 @@ public class MachineTab extends CreativeTabs {
public MachineTab(int p_i1853_1_, String p_i1853_2_) {
super(p_i1853_1_, p_i1853_2_);
setBackgroundImageName("item_search.png");
}
@Override
@ -24,4 +25,9 @@ public class MachineTab extends CreativeTabs {
return Items.iron_pickaxe;
}
@Override
public boolean hasSearchBar() {
return true;
}
}

View File

@ -5,8 +5,10 @@ import com.hbm.items.tool.ItemAssemblyTemplate.EnumAssemblyTemplate;
public class FluidTypeHandler {
public enum FluidType {
NONE(0x888888, 8947848, 0, 0), WATER(0x3333FF, 3355647, 1, 0), LAVA(0xFF3300, 16724736, 2, 0), UF6(0xD1CEBE, 13749950, 3, 0), PUF6(0x4C4C4C, 5000268, 0, 1),
DEUTERIUM(0x0000FF, 255, 1, 1), TRITIUM(0x000099, 153, 2, 1);
NONE(0x888888, 8947848, 0, 0), WATER(0x3333FF, 3355647, 1, 0),
LAVA(0xFF3300, 16724736, 2, 0), UF6(0xD1CEBE, 13749950, 3, 0),
PUF6(0x4C4C4C, 5000268, 0, 1), DEUTERIUM(0x0000FF, 255, 1, 1),
TRITIUM(0x000099, 153, 2, 1);
private int color;
private int msa;

View File

@ -0,0 +1,8 @@
package com.hbm.interfaces;
public interface IFluidContainer {
//Args: fill, what the fill should be set to; index, index for array if there are multiple tanks
public void setFillstate(int fill, int index);
}

View File

@ -0,0 +1,26 @@
package com.hbm.inventory;
import com.hbm.handler.FluidTypeHandler.FluidType;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
public class FluidContainer {
//The full container (e.g. deuterium cell)
public ItemStack fullContainer;
//Them empty container (e.g. empty cell)
public ItemStack emptyContainer;
//The type of the contained liquid (e.g. deuterium)
public FluidType type;
//The amount of liquid stored in mB (e.g. 1000)
public int content;
public FluidContainer(ItemStack full, ItemStack empty, FluidType type, int amount) {
fullContainer = full;
emptyContainer = empty;
this.type = type;
content = amount;
}
}

View File

@ -0,0 +1,101 @@
package com.hbm.inventory;
import java.util.ArrayList;
import java.util.List;
import com.hbm.handler.FluidTypeHandler.FluidType;
import net.minecraft.item.ItemStack;
public class FluidContainerRegistry {
public static final FluidContainerRegistry instance = new FluidContainerRegistry();
List<FluidContainer> allContainers = new ArrayList<FluidContainer>();
public void registerContainer(FluidContainer con) {
allContainers.add(con);
}
/*public static boolean containsFluid(ItemStack stack, FluidType type) {
if(stack == null)
return false;
ItemStack sta = stack.copy();
sta.stackSize = 1;
for(FluidContainer container : instance.allContainers) {
if(container.type == type && getEmptyContainer(sta) != null)
return container.content > 0;
}
return false;
}*/
public static int getFluidContent(ItemStack stack, FluidType type) {
if(stack == null)
return 0;
ItemStack sta = stack.copy();
sta.stackSize = 1;
for(FluidContainer container : instance.allContainers) {
if(container.type.name().equals(type.name()) && getEmptyContainer(sta) != null)
return container.content;
}
return 0;
}
public static FluidType getFluidType(ItemStack stack) {
if(stack == null)
return FluidType.NONE;
ItemStack sta = stack.copy();
sta.stackSize = 1;
for(FluidContainer container : instance.allContainers) {
if(ItemStack.areItemStacksEqual(container.fullContainer, sta) &&
ItemStack.areItemStackTagsEqual(container.fullContainer, sta))
return container.type;
}
return FluidType.NONE;
}
public static ItemStack getFullContainer(ItemStack stack, FluidType type) {
if(stack == null)
return null;
ItemStack sta = stack.copy();
sta.stackSize = 1;
for(FluidContainer container : instance.allContainers) {
if(ItemStack.areItemStacksEqual(container.emptyContainer, sta) &&
ItemStack.areItemStackTagsEqual(container.emptyContainer, sta) &&
container.type.name().equals(type.name()))
return container.fullContainer.copy();
}
return null;
}
public static ItemStack getEmptyContainer(ItemStack stack) {
if(stack == null)
return null;
ItemStack sta = stack.copy();
sta.stackSize = 1;
for(FluidContainer container : instance.allContainers) {
if(ItemStack.areItemStacksEqual(container.fullContainer, sta) &&
ItemStack.areItemStackTagsEqual(container.fullContainer, sta))
return container.emptyContainer.copy();
}
return null;
}
}

View File

@ -0,0 +1,115 @@
package com.hbm.inventory;
import java.util.Arrays;
import com.hbm.handler.FluidTypeHandler.FluidType;
import com.hbm.items.ModItems;
import com.hbm.packet.PacketDispatcher;
import com.hbm.packet.TEAssemblerPacket;
import com.hbm.packet.TEFluidPacket;
import net.minecraft.client.gui.inventory.GuiContainer;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
public class FluidTank {
FluidType type;
int fluid;
int maxFluid;
public boolean takeIn = true;
public boolean letOut = false;
int index;
public FluidTank(FluidType type, int maxFluid, int index) {
this.type = type;
this.maxFluid = maxFluid;
this.index = index;
}
public void setFill(int i) {
fluid = i;
}
//Called on TE update
public void updateTank(int x, int y, int z) {
PacketDispatcher.wrapper.sendToAll(new TEFluidPacket(x, y, z, fluid, index));
}
//Fills tank from canisters
public void loadTank(int in, int out, ItemStack[] slots) {
FluidType inType = FluidType.NONE;
if(slots[in] != null) {
inType = FluidContainerRegistry.getFluidType(slots[in]);
}
if(slots[in] != null && inType.name().equals(type.name()) && fluid + FluidContainerRegistry.getFluidContent(slots[in], type) <= maxFluid) {
if(slots[out] == null) {
fluid += FluidContainerRegistry.getFluidContent(slots[in], type);
slots[out] = FluidContainerRegistry.getEmptyContainer(slots[in]);
slots[in].stackSize--;
if(slots[in].stackSize <= 0)
slots[in] = null;
} else if(slots[out] != null && slots[out].getItem() == FluidContainerRegistry.getEmptyContainer(slots[in]).getItem() && slots[out].stackSize < slots[out].getMaxStackSize()) {
fluid += FluidContainerRegistry.getFluidContent(slots[in], type);
slots[in].stackSize--;
if(slots[in].stackSize <= 0)
slots[in] = null;
slots[out].stackSize++;
}
}
}
//Fills canisters from tank
public void unloadTank(int in, int out, ItemStack[] slots) {
ItemStack full = null;
if(slots[in] != null) {
full = FluidContainerRegistry.getFullContainer(slots[in], type);
}
if(full == null)
return;
if(slots[in] != null && fluid - FluidContainerRegistry.getFluidContent(full, type) >= 0) {
if(slots[out] == null) {
fluid -= FluidContainerRegistry.getFluidContent(full, type);
slots[out] = full.copy();
slots[in].stackSize--;
if(slots[in].stackSize <= 0)
slots[in] = null;
} else if(slots[out] != null && slots[out].getItem() == FluidContainerRegistry.getFullContainer(slots[in], type).getItem() && slots[out].stackSize < slots[out].getMaxStackSize()) {
fluid -= FluidContainerRegistry.getFluidContent(full, type);
slots[in].stackSize--;
if(slots[in].stackSize <= 0)
slots[in] = null;
slots[out].stackSize++;
}
}
}
//Used in the GUI rendering, renders correct fluid type in container with progress
public void renderTank(GuiContainer gui, int x, int y, int tx, int ty, int width, int height) {
int i = (fluid * height) / maxFluid;
gui.drawTexturedModalRect(x, y - i, tx, ty - i, width, i);
}
//Called by TE to save fillstate
public void writeToNBT(NBTTagCompound nbt, String s) {
nbt.setInteger(s, fluid);
nbt.setInteger(s + "_type", Arrays.asList(FluidType.values()).indexOf(type));
nbt.setBoolean(s + "_in", takeIn);
nbt.setBoolean(s + "_out", letOut);
}
//Called by TE to load fillstate
public void readFromNBT(NBTTagCompound nbt, String s) {
fluid = nbt.getInteger(s);
type = FluidType.getEnum(nbt.getInteger(s + "_type"));
takeIn = nbt.getBoolean(s + "_in");
letOut = nbt.getBoolean(s + "_out");
}
}

View File

@ -13,11 +13,8 @@ import net.minecraft.item.ItemStack;
public class ContainerUF6Tank extends Container {
private TileEntityMachineUF6Tank testNuke;
private int fillState;
public ContainerUF6Tank(InventoryPlayer invPlayer, TileEntityMachineUF6Tank tedf) {
fillState = 0;
testNuke = tedf;
this.addSlotToContainer(new Slot(tedf, 0, 44, 17));
@ -42,7 +39,6 @@ public class ContainerUF6Tank extends Container {
@Override
public void addCraftingToCrafters(ICrafting crafting) {
super.addCraftingToCrafters(crafting);
crafting.sendProgressBarUpdate(this, 0, this.testNuke.fillState);
}
@Override
@ -85,30 +81,5 @@ public class ContainerUF6Tank extends Container {
public boolean canInteractWith(EntityPlayer player) {
return testNuke.isUseableByPlayer(player);
}
@Override
public void detectAndSendChanges() {
super.detectAndSendChanges();
for(int i = 0; i < this.crafters.size(); i++)
{
ICrafting par1 = (ICrafting)this.crafters.get(i);
if(this.fillState != this.testNuke.fillState)
{
par1.sendProgressBarUpdate(this, 0, this.testNuke.fillState);
}
}
this.fillState = this.testNuke.fillState;
}
@Override
public void updateProgressBar(int i, int j) {
if(i == 0)
{
testNuke.fillState = j;
}
}
}

View File

@ -39,10 +39,6 @@ public class GUIMachineUF6Tank extends GuiContainer {
Minecraft.getMinecraft().getTextureManager().bindTexture(texture);
drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);
if(tank.fillState > 0)
{
int i1 = tank.getFillStateScaled(52);
drawTexturedModalRect(guiLeft + 80, guiTop + 69 - i1, 177, 52 - i1, 16, i1);
}
tank.tank.renderTank(this, guiLeft + 80, guiTop + 69, 177, 52, 16, 52);
}
}

View File

@ -27,8 +27,9 @@ public class ItemAntiCheat extends ItemCustomLore {
player.inventory.consumeInventoryItem(ModItems.nugget_euphemium);
}
}
entity.attackEntityFrom(ModDamageSource.cheater, Float.POSITIVE_INFINITY);
//entity.attackEntityFrom(ModDamageSource.cheater, Float.POSITIVE_INFINITY);
entity.attackEntityFrom(ModDamageSource.cheater, 10000);
//if(!world.isRemote)
// ExplosionChaos.antiCheat(world, (int)entity.posX, (int)entity.posY, (int)entity.posZ, 20);

View File

@ -2,6 +2,7 @@ package com.hbm.items.tool;
import java.util.List;
import com.hbm.blocks.ModBlocks;
import com.hbm.inventory.MachineRecipes;
import com.hbm.items.ModItems;
@ -101,6 +102,222 @@ public class ItemAssemblyTemplate extends Item {
switch (enum1) {
case TEST:
return 200;
case MIXED_PLATE:
return 50;
case HAZMAT_CLOTH:
return 50;
case ASBESTOS_CLOTH:
return 50;
case COAL_FILTER:
return 50;
case CENTRIFUGE_ELEMENT:
return 200;
case CENTRIFUGE_TOWER:
return 150;
case DEE_MAGNET:
return 100;
case FLAT_MAGNET:
return 150;
case CYCLOTRON_TOWER:
return 300;
case REACTOR_CORE:
return 100;
case RTG_UNIT:
return 100;
case HEAT_UNIT:
return 100;
case GRAVITY_UNIT:
return 100;
case TITANIUM_DRILL:
return 100;
case TELEPAD:
return 300;
case TELEKIT:
return 200;
case GEASS_REACTOR:
return 200;
case GENERATOR_FRONT:
return 200;
case WT1_GENERIC:
return 100;
case WT2_GENERIC:
return 150;
case WT3_GENERIC:
return 200;
case WT1_FIRE:
return 100;
case WT2_FIRE:
return 150;
case WT3_FIRE:
return 200;
case WT1_CLUSTER:
return 100;
case WT2_CLUSTER:
return 150;
case WT3_CLUSTER:
return 200;
case WT1_BUSTER:
return 100;
case WT2_BUSTER:
return 150;
case WT3_BUSTER:
return 200;
case W_NUCLEAR:
return 300;
case W_MIRVLET:
return 250;
case W_MIRV:
return 500;
case W_ENDOTHERMIC:
return 300;
case W_EXOTHERMIC:
return 300;
case T1_TANK:
return 100;
case T2_TANK:
return 150;
case T3_TANK:
return 200;
case T1_THRUSTER:
return 100;
case T2_THRUSTER:
return 150;
case T3_THRUSTER:
return 200;
case CHOPPER_HEAD:
return 300;
case CHOPPER_GUN:
return 150;
case CHOPPER_BODY:
return 350;
case CHOPPER_TAIL:
return 200;
case CHOPPER_WING:
return 150;
case CHOPPER_BLADES:
return 200;
case CIRCUIT_2:
return 100;
case CIRCUIT_3:
return 150;
case RTG_PELLET:
return 50;
case WEAK_PELLET:
return 50;
case FUSION_PELLET:
return 150;
case CLUSTER_PELLETS:
return 50;
case GUN_PELLETS:
return 50;
case AUSTRALIUM_MACHINE:
return 150;
case MAGNETRON:
return 100;
case W_SP:
return 200;
case W_SHE:
return 200;
case W_SME:
return 200;
case W_SLE:
return 200;
case W_B:
return 200;
case W_N:
return 200;
case W_L:
return 200;
case W_A:
return 200;
case UPGRADE_TEMPLATE:
return 100;
case UPGRADE_RED_I:
return 200;
case UPGRADE_RED_II:
return 300;
case UPGRADE_RED_III:
return 500;
case UPGRADE_GREEN_I:
return 200;
case UPGRADE_GREEN_II:
return 300;
case UPGRADE_GREEN_III:
return 500;
case UPGRADE_BLUE_I:
return 200;
case UPGRADE_BLUE_II:
return 300;
case UPGRADE_BLUE_III:
return 500;
case UPGRADE_PURPLE_I:
return 200;
case UPGRADE_PURPLE_II:
return 300;
case UPGRADE_PURPLE_III:
return 500;
case FUSE:
return 100;
case REDCOIL_CAPACITOR:
return 200;
case TITANIUM_FILTER:
return 200;
case LITHIUM_BOX:
return 50;
case BERYLLIUM_BOX:
return 50;
case COAL_BOX:
return 50;
case COPPER_BOX:
return 50;
case PLUTONIUM_BOX:
return 50;
case THERMO_ELEMENT:
return 150;
case LIMITER:
return 150;
case ANGRY_METAL:
return 50;
case CMB_TILE:
return 100;
case CMB_BRICKS:
return 200;
case HATCH_FRAME:
return 50;
case HATCH_CONTROLLER:
return 100;
case CENTRIFUGE:
return 250;
case BREEDING_REACTOR:
return 150;
case RTG_FURNACE:
return 150;
case DIESEL_GENERATOR:
return 200;
case NUCLEAR_GENERATOR:
return 300;
case INDUSTRIAL_GENERATOR:
return 500;
case CYCLOTRON:
return 600;
case RT_GENERATOR:
return 200;
case BATTERY:
return 200;
case HE_TO_RF:
return 150;
case RF_TO_HE:
return 150;
case SHREDDER:
return 200;
case DEUTERIUM_EXTRACTOR:
return 150;
case DERRICK:
return 250;
case FLARE_STACK:
return 200;
case REFINERY:
return 150;
default:
return 100;
}

View File

@ -773,7 +773,7 @@ public class Library {
}
//Flut-Füll gesteuerter Energieübertragungsalgorithmus
//Flood fill controlle energy transmission algorithm
//Flood fill controlled energy transmission algorithm
public static void ffgeua(int x, int y, int z, boolean newTact, ISource that, World worldObj) {
Block block = worldObj.getBlock(x, y, z);
TileEntity tileentity = worldObj.getTileEntity(x, y, z);

View File

@ -111,8 +111,11 @@ import com.hbm.entity.projectile.EntityRubble;
import com.hbm.entity.projectile.EntitySchrab;
import com.hbm.entity.projectile.EntityShrapnel;
import com.hbm.entity.projectile.EntitySparkBeam;
import com.hbm.handler.FluidTypeHandler.FluidType;
import com.hbm.handler.FuelHandler;
import com.hbm.handler.GUIHandler;
import com.hbm.inventory.FluidContainer;
import com.hbm.inventory.FluidContainerRegistry;
import com.hbm.inventory.MachineRecipes;
import com.hbm.inventory.MachineRecipes.ShredderRecipe;
import com.hbm.items.ModItems;
@ -784,6 +787,19 @@ public class MainRegistry
recipes.overridePreSetRecipe(new ItemStack(ModItems.powder_lapis), new ItemStack(ModItems.powder_cobalt_tiny, 1));
recipes.PrintRecipes();
FluidContainerRegistry.instance.registerContainer(new FluidContainer(new ItemStack(ModItems.canister_oil), new ItemStack(ModItems.canister_empty), FluidType.LAVA, 1000));
FluidContainerRegistry.instance.registerContainer(new FluidContainer(new ItemStack(ModItems.cell_deuterium), new ItemStack(ModItems.cell_empty), FluidType.DEUTERIUM, 1000));
FluidContainerRegistry.instance.registerContainer(new FluidContainer(new ItemStack(ModItems.cell_tritium), new ItemStack(ModItems.cell_empty), FluidType.TRITIUM, 1000));
FluidContainerRegistry.instance.registerContainer(new FluidContainer(new ItemStack(ModItems.cell_uf6), new ItemStack(ModItems.cell_empty), FluidType.UF6, 1000));
FluidContainerRegistry.instance.registerContainer(new FluidContainer(new ItemStack(ModItems.cell_puf6), new ItemStack(ModItems.cell_empty), FluidType.PUF6, 1000));
/*System.out.println(FluidContainerRegistry.getEmptyContainer(new ItemStack(ModItems.cell_deuterium))); //cell_empty
System.out.println(FluidContainerRegistry.getEmptyContainer(new ItemStack(ModItems.board_copper))); //null
System.out.println(FluidContainerRegistry.getFluidContent(new ItemStack(ModItems.cell_deuterium), FluidType.DEUTERIUM)); //1000
System.out.println(FluidContainerRegistry.getFluidContent(new ItemStack(ModItems.cell_deuterium), FluidType.WATER)); //0
System.out.println(FluidContainerRegistry.containsFluid(new ItemStack(ModItems.cell_deuterium), FluidType.DEUTERIUM)); //true
System.out.println(FluidContainerRegistry.containsFluid(new ItemStack(ModItems.cell_deuterium), FluidType.WATER)); //false*/
}
@EventHandler

View File

@ -13,18 +13,28 @@ public class PacketDispatcher {
public static final void registerPackets()
{
int i = 0;
//Packet sent for every connected electricity pole, for wire rendering
wrapper.registerMessage(TEPylonSenderPacket.Handler.class, TEPylonSenderPacket.class, 0, Side.CLIENT);
wrapper.registerMessage(TEPylonSenderPacket.Handler.class, TEPylonSenderPacket.class, i++, Side.CLIENT);
//Resets connection list in client-sided pole rendering
wrapper.registerMessage(TEPylonDestructorPacket.Handler.class, TEPylonDestructorPacket.class, 1, Side.CLIENT);
wrapper.registerMessage(TEPylonDestructorPacket.Handler.class, TEPylonDestructorPacket.class, i++, Side.CLIENT);
//Flywheel rotation for industrial generator rendering
wrapper.registerMessage(TEIGeneratorPacket.Handler.class, TEIGeneratorPacket.class, 2, Side.CLIENT);
wrapper.registerMessage(TEIGeneratorPacket.Handler.class, TEIGeneratorPacket.class, i++, Side.CLIENT);
//Machine type for marker rendering
wrapper.registerMessage(TEStructurePacket.Handler.class, TEStructurePacket.class, 3, Side.CLIENT);
//Mingin drill rotation for rendering
wrapper.registerMessage(TEDrillPacket.Handler.class, TEDrillPacket.class, 4, Side.CLIENT);
wrapper.registerMessage(TEStructurePacket.Handler.class, TEStructurePacket.class, i++, Side.CLIENT);
//Mining drill rotation for rendering
wrapper.registerMessage(TEDrillPacket.Handler.class, TEDrillPacket.class, i++, Side.CLIENT);
//Mining drill torque for sounds
wrapper.registerMessage(TEDrillSoundPacket.Handler.class, TEDrillSoundPacket.class, i++, Side.CLIENT);
//Assembler cog rotation for rendering
wrapper.registerMessage(TEAssemblerPacket.Handler.class, TEAssemblerPacket.class, i++, Side.CLIENT);
//Fluid type for pipe rendering
wrapper.registerMessage(TEFluidPipePacket.Handler.class, TEFluidPipePacket.class, 5, Side.CLIENT);
wrapper.registerMessage(TEFluidPipePacket.Handler.class, TEFluidPipePacket.class, i++, Side.CLIENT);
//Missile type for rendering
wrapper.registerMessage(TEMissilePacket.Handler.class, TEMissilePacket.class, i++, Side.CLIENT);
//Fluid packet for GUI
wrapper.registerMessage(TEFluidPacket.Handler.class, TEFluidPacket.class, i++, Side.CLIENT);
}
}

View File

@ -0,0 +1,68 @@
package com.hbm.packet;
import java.util.ArrayList;
import java.util.List;
import com.hbm.tileentity.TileEntityMachineAssembler;
import com.hbm.tileentity.TileEntityMachineIGenerator;
import com.hbm.tileentity.TileEntityMachineMiningDrill;
import com.hbm.tileentity.TileEntityPylonRedWire;
import cpw.mods.fml.common.network.simpleimpl.IMessage;
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
import io.netty.buffer.ByteBuf;
import net.minecraft.client.Minecraft;
import net.minecraft.tileentity.TileEntity;
public class TEAssemblerPacket implements IMessage {
int x;
int y;
int z;
float spin;
public TEAssemblerPacket()
{
}
public TEAssemblerPacket(int x, int y, int z, float spin)
{
this.x = x;
this.y = y;
this.z = z;
this.spin = spin;
}
@Override
public void fromBytes(ByteBuf buf) {
x = buf.readInt();
y = buf.readInt();
z = buf.readInt();
spin = buf.readFloat();
}
@Override
public void toBytes(ByteBuf buf) {
buf.writeInt(x);
buf.writeInt(y);
buf.writeInt(z);
buf.writeFloat(spin);
}
public static class Handler implements IMessageHandler<TEAssemblerPacket, IMessage> {
@Override
public IMessage onMessage(TEAssemblerPacket m, MessageContext ctx) {
TileEntity te = Minecraft.getMinecraft().theWorld.getTileEntity(m.x, m.y, m.z);
if (te != null && te instanceof TileEntityMachineAssembler) {
TileEntityMachineAssembler gen = (TileEntityMachineAssembler) te;
gen.rotation = m.spin;
}
return null;
}
}
}

View File

@ -0,0 +1,67 @@
package com.hbm.packet;
import java.util.ArrayList;
import java.util.List;
import com.hbm.tileentity.TileEntityMachineIGenerator;
import com.hbm.tileentity.TileEntityMachineMiningDrill;
import com.hbm.tileentity.TileEntityPylonRedWire;
import cpw.mods.fml.common.network.simpleimpl.IMessage;
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
import io.netty.buffer.ByteBuf;
import net.minecraft.client.Minecraft;
import net.minecraft.tileentity.TileEntity;
public class TEDrillSoundPacket implements IMessage {
int x;
int y;
int z;
float spin;
public TEDrillSoundPacket()
{
}
public TEDrillSoundPacket(int x, int y, int z, float spin)
{
this.x = x;
this.y = y;
this.z = z;
this.spin = spin;
}
@Override
public void fromBytes(ByteBuf buf) {
x = buf.readInt();
y = buf.readInt();
z = buf.readInt();
spin = buf.readFloat();
}
@Override
public void toBytes(ByteBuf buf) {
buf.writeInt(x);
buf.writeInt(y);
buf.writeInt(z);
buf.writeFloat(spin);
}
public static class Handler implements IMessageHandler<TEDrillSoundPacket, IMessage> {
@Override
public IMessage onMessage(TEDrillSoundPacket m, MessageContext ctx) {
TileEntity te = Minecraft.getMinecraft().theWorld.getTileEntity(m.x, m.y, m.z);
if (te != null && te instanceof TileEntityMachineMiningDrill) {
TileEntityMachineMiningDrill gen = (TileEntityMachineMiningDrill) te;
gen.torque = m.spin;
}
return null;
}
}
}

View File

@ -0,0 +1,73 @@
package com.hbm.packet;
import java.util.ArrayList;
import java.util.List;
import com.hbm.interfaces.IFluidContainer;
import com.hbm.tileentity.TileEntityMachineAssembler;
import com.hbm.tileentity.TileEntityMachineIGenerator;
import com.hbm.tileentity.TileEntityMachineMiningDrill;
import com.hbm.tileentity.TileEntityPylonRedWire;
import cpw.mods.fml.common.network.simpleimpl.IMessage;
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
import io.netty.buffer.ByteBuf;
import net.minecraft.client.Minecraft;
import net.minecraft.tileentity.TileEntity;
public class TEFluidPacket implements IMessage {
int x;
int y;
int z;
int fill;
int index;
public TEFluidPacket()
{
}
public TEFluidPacket(int x, int y, int z, int fill, int index)
{
this.x = x;
this.y = y;
this.z = z;
this.fill = fill;
this.index = index;
}
@Override
public void fromBytes(ByteBuf buf) {
x = buf.readInt();
y = buf.readInt();
z = buf.readInt();
fill = buf.readInt();
index = buf.readInt();
}
@Override
public void toBytes(ByteBuf buf) {
buf.writeInt(x);
buf.writeInt(y);
buf.writeInt(z);
buf.writeInt(fill);
buf.writeInt(index);
}
public static class Handler implements IMessageHandler<TEFluidPacket, IMessage> {
@Override
public IMessage onMessage(TEFluidPacket m, MessageContext ctx) {
TileEntity te = Minecraft.getMinecraft().theWorld.getTileEntity(m.x, m.y, m.z);
if (te != null && te instanceof IFluidContainer) {
IFluidContainer gen = (IFluidContainer) te;
gen.setFillstate(m.fill, m.index);
}
return null;
}
}
}

View File

@ -0,0 +1,67 @@
package com.hbm.packet;
import java.util.ArrayList;
import java.util.List;
import com.hbm.tileentity.TileEntityLaunchPad;
import com.hbm.tileentity.TileEntityMachineIGenerator;
import com.hbm.tileentity.TileEntityPylonRedWire;
import cpw.mods.fml.common.network.simpleimpl.IMessage;
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
import io.netty.buffer.ByteBuf;
import net.minecraft.client.Minecraft;
import net.minecraft.tileentity.TileEntity;
public class TEMissilePacket implements IMessage {
int x;
int y;
int z;
int type;
public TEMissilePacket()
{
}
public TEMissilePacket(int x, int y, int z, int type)
{
this.x = x;
this.y = y;
this.z = z;
this.type = type;
}
@Override
public void fromBytes(ByteBuf buf) {
x = buf.readInt();
y = buf.readInt();
z = buf.readInt();
type = buf.readInt();
}
@Override
public void toBytes(ByteBuf buf) {
buf.writeInt(x);
buf.writeInt(y);
buf.writeInt(z);
buf.writeInt(type);
}
public static class Handler implements IMessageHandler<TEMissilePacket, IMessage> {
@Override
public IMessage onMessage(TEMissilePacket m, MessageContext ctx) {
TileEntity te = Minecraft.getMinecraft().theWorld.getTileEntity(m.x, m.y, m.z);
if (te != null && te instanceof TileEntityLaunchPad) {
TileEntityLaunchPad gen = (TileEntityLaunchPad) te;
gen.state = m.type;
}
return null;
}
}
}

View File

@ -3,6 +3,7 @@ package com.hbm.render.tileentity;
import org.lwjgl.opengl.GL11;
import com.hbm.lib.RefStrings;
import com.hbm.tileentity.TileEntityMachineAssembler;
import com.hbm.tileentity.TileEntityMachineIGenerator;
import com.hbm.tileentity.TileEntityMachineMiningDrill;
@ -14,15 +15,20 @@ import net.minecraftforge.client.model.IModelCustom;
public class RenderAssembler extends TileEntitySpecialRenderer {
private static final ResourceLocation body = new ResourceLocation(/*"/assets/" + */RefStrings.MODID, "models/assembler.obj");
private static final ResourceLocation body = new ResourceLocation(/*"/assets/" + */RefStrings.MODID, "models/assembler_main.obj");
private static final ResourceLocation bolt = new ResourceLocation(/*"/assets/" + */RefStrings.MODID, "models/assembler_wheel.obj");
private IModelCustom bodyModel;
private ResourceLocation bodyTexture;
private IModelCustom boltModel;
private ResourceLocation boltTexture;
public RenderAssembler()
{
bodyModel = AdvancedModelLoader.loadModel(body);
bodyTexture = new ResourceLocation(RefStrings.MODID, "textures/models/TheGadget3_.png");
bodyTexture = new ResourceLocation(RefStrings.MODID, "textures/models/assembler.png");
boltModel = AdvancedModelLoader.loadModel(bolt);
boltTexture = new ResourceLocation(RefStrings.MODID, "textures/models/textureIGenRotor.png");
}
@Override
@ -54,5 +60,38 @@ public class RenderAssembler extends TileEntitySpecialRenderer {
bodyModel.renderAll();
GL11.glPopMatrix();
renderTileEntityAt2(tileEntity, x, y, z, f);
}
public void renderTileEntityAt2(TileEntity tileEntity, double x, double y, double z, float f)
{
GL11.glPushMatrix();
GL11.glTranslated(x, y, z);
GL11.glEnable(GL11.GL_LIGHTING);
GL11.glDisable(GL11.GL_CULL_FACE);
GL11.glRotatef(180, 0F, 1F, 0F);
switch(tileEntity.getBlockMetadata())
{
case 2:
GL11.glTranslated(-1, 0, 0);
GL11.glRotatef(90, 0F, 1F, 0F); break;
case 4:
GL11.glRotatef(180, 0F, 1F, 0F); break;
case 3:
GL11.glTranslated(0, 0, -1);
GL11.glRotatef(270, 0F, 1F, 0F); break;
case 5:
GL11.glTranslated(-1, 0, -1);
GL11.glRotatef(0, 0F, 1F, 0F); break;
}
GL11.glRotatef(((TileEntityMachineAssembler)tileEntity).rotation, 0F, 1F, 0F);
bindTexture(boltTexture);
boltModel.renderAll();
GL11.glPopMatrix();
}
}

View File

@ -25,7 +25,7 @@ public class RenderMiningDrill extends TileEntitySpecialRenderer {
public RenderMiningDrill()
{
bodyModel = AdvancedModelLoader.loadModel(body);
bodyTexture = new ResourceLocation(RefStrings.MODID, "textures/models/TheGadget3_.png");
bodyTexture = new ResourceLocation(RefStrings.MODID, "textures/models/mining_drill.png");
boltModel = AdvancedModelLoader.loadModel(bolt);
boltTexture = new ResourceLocation(RefStrings.MODID, "textures/models/textureIGenRotor.png");
}

View File

@ -0,0 +1,46 @@
package com.hbm.sound;
import net.minecraft.client.audio.ITickableSound;
import net.minecraft.client.audio.PositionedSound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ResourceLocation;
public class SoundLoopMachine extends PositionedSound implements ITickableSound {
boolean donePlaying = false;
TileEntity te;
public SoundLoopMachine(ResourceLocation path, TileEntity te) {
super(path);
this.repeat = true;
this.volume = 1;
this.field_147663_c = 1;
this.xPosF = te.xCoord;
this.yPosF = te.yCoord;
this.zPosF = te.zCoord;
this.field_147665_h = 0;
this.te = te;
}
@Override
public void update() {
if(te == null || (te != null && te.isInvalid()))
donePlaying = true;
}
@Override
public boolean isDonePlaying() {
return this.donePlaying;
}
public void setVolume(float f) {
volume = f;
}
public void setPitch(float f) {
field_147663_c = f;
}
public void stop() {
donePlaying = true;
}
}

View File

@ -5,6 +5,9 @@ import com.hbm.interfaces.IConductor;
import com.hbm.interfaces.IConsumer;
import com.hbm.items.ModItems;
import com.hbm.lib.Library;
import com.hbm.packet.PacketDispatcher;
import com.hbm.packet.TEFluidPipePacket;
import com.hbm.packet.TEMissilePacket;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -28,13 +31,11 @@ public class TileEntityLaunchPad extends TileEntity implements ISidedInventory,
private static final int[] slots_top = new int[] {0};
private static final int[] slots_bottom = new int[] {2};
private static final int[] slots_side = new int[] {1};
public int state = 0;
public int targetX = this.xCoord + 50;
public int targetZ = this.zCoord;
public int state = 0;
public int preState = 0;
private String customName;
public TileEntityLaunchPad() {
@ -139,7 +140,6 @@ public class TileEntityLaunchPad extends TileEntity implements ISidedInventory,
super.readFromNBT(nbt);
NBTTagList list = nbt.getTagList("items", 10);
power = nbt.getInteger("power");
state = nbt.getShort("state");
slots = new ItemStack[getSizeInventory()];
for(int i = 0; i < list.tagCount(); i++)
@ -158,7 +158,6 @@ public class TileEntityLaunchPad extends TileEntity implements ISidedInventory,
super.writeToNBT(nbt);
NBTTagList list = new NBTTagList();
nbt.setInteger("power", power);
nbt.setShort("state", (short) state);
for(int i = 0; i < slots.length; i++)
{
@ -199,193 +198,44 @@ public class TileEntityLaunchPad extends TileEntity implements ISidedInventory,
power = Library.chargeTEFromItems(slots, 2, power, maxPower);
this.preState = this.state;
ItemStack stack = slots[0];
if(this.slots[0] == null ||
(this.slots[0] != null &&
(this.slots[0].getItem() != ModItems.missile_generic &&
this.slots[0].getItem() != ModItems.missile_strong &&
this.slots[0].getItem() != ModItems.missile_cluster &&
this.slots[0].getItem() != ModItems.missile_nuclear &&
this.slots[0].getItem() != ModItems.missile_incendiary &&
this.slots[0].getItem() != ModItems.missile_buster &&
this.slots[0].getItem() != ModItems.missile_incendiary_strong &&
this.slots[0].getItem() != ModItems.missile_cluster_strong &&
this.slots[0].getItem() != ModItems.missile_buster_strong &&
this.slots[0].getItem() != ModItems.missile_burst &&
this.slots[0].getItem() != ModItems.missile_inferno &&
this.slots[0].getItem() != ModItems.missile_rain &&
this.slots[0].getItem() != ModItems.missile_drill &&
this.slots[0].getItem() != ModItems.missile_endo &&
this.slots[0].getItem() != ModItems.missile_exo &&
this.slots[0].getItem() != ModItems.missile_nuclear_cluster)))
{
this.state = 0;
if(stack != null) {
if(stack.getItem() == ModItems.missile_generic)
state = 1;
if(stack.getItem() == ModItems.missile_strong)
state = 2;
if(stack.getItem() == ModItems.missile_cluster)
state = 3;
if(stack.getItem() == ModItems.missile_nuclear)
state = 4;
if(stack.getItem() == ModItems.missile_incendiary)
state = 5;
if(stack.getItem() == ModItems.missile_buster)
state = 6;
if(stack.getItem() == ModItems.missile_incendiary_strong)
state = 7;
if(stack.getItem() == ModItems.missile_cluster_strong)
state = 8;
if(stack.getItem() == ModItems.missile_buster_strong)
state = 9;
if(stack.getItem() == ModItems.missile_burst)
state = 10;
if(stack.getItem() == ModItems.missile_inferno)
state = 11;
if(stack.getItem() == ModItems.missile_rain)
state = 12;
if(stack.getItem() == ModItems.missile_drill)
state = 13;
if(stack.getItem() == ModItems.missile_endo)
state = 14;
if(stack.getItem() == ModItems.missile_exo)
state = 15;
if(stack.getItem() == ModItems.missile_nuclear_cluster)
state = 16;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_generic)
{
this.state = 1;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_strong)
{
this.state = 2;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_cluster)
{
this.state = 3;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_nuclear)
{
this.state = 4;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_incendiary)
{
this.state = 5;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_buster)
{
this.state = 6;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_incendiary_strong)
{
this.state = 7;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_cluster_strong)
{
this.state = 8;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_buster_strong)
{
this.state = 9;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_burst)
{
this.state = 10;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_inferno)
{
this.state = 11;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_rain)
{
this.state = 12;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_drill)
{
this.state = 13;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_endo)
{
this.state = 14;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_exo)
{
this.state = 15;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
}
if(this.slots[0] != null && this.slots[0].getItem() == ModItems.missile_nuclear_cluster)
{
this.state = 16;
if(this.state != this.preState)
{
LaunchPad.updateBlockState(this.state, this.worldObj, this.xCoord, this.yCoord, this.zCoord);
}
if(!worldObj.isRemote)
PacketDispatcher.wrapper.sendToAll(new TEMissilePacket(xCoord, yCoord, zCoord, state));
}
}

View File

@ -11,7 +11,9 @@ import com.hbm.items.special.ItemBattery;
import com.hbm.items.tool.ItemAssemblyTemplate;
import com.hbm.lib.Library;
import com.hbm.packet.PacketDispatcher;
import com.hbm.packet.TEAssemblerPacket;
import com.hbm.packet.TEDrillPacket;
import com.hbm.packet.TEIGeneratorPacket;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -37,7 +39,10 @@ public class TileEntityMachineAssembler extends TileEntity implements ISidedInve
public static final int maxPower = 100000;
public int progress;
public int maxProgress = 100;
public float rotation = 0;
int age = 0;
int consumption = 100;
int speed = 100;
Random rand = new Random();
@ -211,19 +216,63 @@ public class TileEntityMachineAssembler extends TileEntity implements ISidedInve
@Override
public void updateEntity() {
this.consumption = 100;
this.speed = 100;
for(int i = 1; i < 4; i++) {
ItemStack stack = slots[i];
if(stack != null) {
if(stack.getItem() == ModItems.upgrade_speed_1) {
this.speed -= 25;
this.consumption += 300;
}
if(stack.getItem() == ModItems.upgrade_speed_2) {
this.speed -= 50;
this.consumption += 600;
}
if(stack.getItem() == ModItems.upgrade_speed_3) {
this.speed -= 75;
this.consumption += 900;
}
if(stack.getItem() == ModItems.upgrade_power_1) {
this.consumption -= 30;
this.speed += 5;
}
if(stack.getItem() == ModItems.upgrade_power_2) {
this.consumption -= 60;
this.speed += 10;
}
if(stack.getItem() == ModItems.upgrade_power_3) {
this.consumption -= 90;
this.speed += 15;
}
}
}
if(speed < 25)
speed = 25;
if(consumption < 10)
consumption = 10;
if(!worldObj.isRemote) {
power = Library.chargeTEFromItems(slots, 0, power, maxPower);
if(MachineRecipes.getOutputFromTempate(slots[4]) != null && MachineRecipes.getRecipeFromTempate(slots[4]) != null) {
this.maxProgress = ItemAssemblyTemplate.getProcessTime(slots[4]);
this.maxProgress = (ItemAssemblyTemplate.getProcessTime(slots[4]) * speed) / 100;
if(power >= 100 && removeItems(MachineRecipes.getRecipeFromTempate(slots[4]), cloneItemStackProper(slots))) {
if(power >= consumption && removeItems(MachineRecipes.getRecipeFromTempate(slots[4]), cloneItemStackProper(slots))) {
if(slots[5] == null || (slots[5] != null && slots[5].getItem() == MachineRecipes.getOutputFromTempate(slots[4]).copy().getItem()) && slots[5].stackSize + MachineRecipes.getOutputFromTempate(slots[4]).copy().stackSize <= slots[5].getMaxStackSize()) {
progress++;
rotation += 5;
if(rotation >= 360)
rotation -= 360;
if(progress >= maxProgress) {
progress = 0;
if(slots[5] == null) {
@ -235,7 +284,7 @@ public class TileEntityMachineAssembler extends TileEntity implements ISidedInve
removeItems(MachineRecipes.getRecipeFromTempate(slots[4]), slots);
}
power -= 100;
power -= consumption;
}
} else
progress = 0;
@ -298,7 +347,8 @@ public class TileEntityMachineAssembler extends TileEntity implements ISidedInve
if(tryFillAssembler(hopper, i))
break;
}
PacketDispatcher.wrapper.sendToAll(new TEAssemblerPacket(xCoord, yCoord, zCoord, rotation));
}
}

View File

@ -17,11 +17,14 @@ import com.hbm.items.special.ItemBattery;
import com.hbm.lib.Library;
import com.hbm.packet.PacketDispatcher;
import com.hbm.packet.TEDrillPacket;
import com.hbm.packet.TEDrillSoundPacket;
import com.hbm.packet.TEIGeneratorPacket;
import com.hbm.sound.SoundLoopMachine;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.block.Block;
import net.minecraft.client.Minecraft;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.inventory.IInventory;
@ -33,6 +36,7 @@ import net.minecraft.tileentity.TileEntity;
import net.minecraft.tileentity.TileEntityChest;
import net.minecraft.tileentity.TileEntityHopper;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.fluids.BlockFluidBase;
import net.minecraftforge.oredict.OreDictionary;
@ -51,6 +55,7 @@ public class TileEntityMachineMiningDrill extends TileEntity implements ISidedIn
boolean flag = true;
public float torque;
public float rotation;
//SoundLoopMachine sound;
private static final int[] slots_top = new int[] {1};
private static final int[] slots_bottom = new int[] {2, 0};
@ -454,8 +459,23 @@ public class TileEntityMachineMiningDrill extends TileEntity implements ISidedIn
rotation -= 360;
PacketDispatcher.wrapper.sendToAll(new TEDrillPacket(xCoord, yCoord, zCoord, rotation));
PacketDispatcher.wrapper.sendToAll(new TEDrillSoundPacket(xCoord, yCoord, zCoord, torque));
}
/*if(worldObj.isRemote) {
if(torque > 0) {
if(sound == null) {
sound = new SoundLoopMachine(new ResourceLocation("hbm:block.minerOperate"), this);
sound.setVolume(2.5F);
Minecraft.getMinecraft().getSoundHandler().playSound(sound);
}
} else {
if(sound != null) {
sound.stop();
sound = null;
}
}
}*/
}
public boolean tryFillContainer(IInventory inventory, int slot) {

View File

@ -1,5 +1,8 @@
package com.hbm.tileentity;
import com.hbm.handler.FluidTypeHandler.FluidType;
import com.hbm.interfaces.IFluidContainer;
import com.hbm.inventory.FluidTank;
import com.hbm.items.ModItems;
import cpw.mods.fml.relauncher.Side;
@ -13,12 +16,12 @@ import net.minecraft.nbt.NBTTagList;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.AxisAlignedBB;
public class TileEntityMachineUF6Tank extends TileEntity implements ISidedInventory {
public class TileEntityMachineUF6Tank extends TileEntity implements ISidedInventory, IFluidContainer {
private ItemStack slots[];
public int fillState;
public static final int maxFill = 64 * 3;
//public static final int maxFill = 64 * 3;
public FluidTank tank;
private static final int[] slots_top = new int[] {0};
private static final int[] slots_bottom = new int[] {1, 3};
@ -28,6 +31,7 @@ public class TileEntityMachineUF6Tank extends TileEntity implements ISidedInvent
public TileEntityMachineUF6Tank() {
slots = new ItemStack[4];
tank = new FluidTank(FluidType.UF6, 64000, 0);
}
@Override
@ -132,9 +136,10 @@ public class TileEntityMachineUF6Tank extends TileEntity implements ISidedInvent
super.readFromNBT(nbt);
NBTTagList list = nbt.getTagList("items", 10);
fillState = nbt.getShort("fillState");
slots = new ItemStack[getSizeInventory()];
tank.readFromNBT(nbt, "content");
for(int i = 0; i < list.tagCount(); i++)
{
NBTTagCompound nbt1 = list.getCompoundTagAt(i);
@ -149,9 +154,10 @@ public class TileEntityMachineUF6Tank extends TileEntity implements ISidedInvent
@Override
public void writeToNBT(NBTTagCompound nbt) {
super.writeToNBT(nbt);
nbt.setShort("fillState", (short) fillState);
NBTTagList list = new NBTTagList();
tank.writeToNBT(nbt, "content");
for(int i = 0; i < slots.length; i++)
{
if(slots[i] != null)
@ -181,84 +187,14 @@ public class TileEntityMachineUF6Tank extends TileEntity implements ISidedInvent
return true;
}
public int getFillStateScaled(int i) {
return (fillState * i) / maxFill;
}
public boolean canGive() {
if(slots[0] != null && slots[0].getItem() == ModItems.cell_uf6)
{
if(slots[1] == null || (slots[1] != null && slots[1].getItem() == ModItems.cell_empty && slots[1].stackSize < slots[1].getMaxStackSize()))
{
if(fillState < maxFill)
{
return true;
}
}
}
return false;
}
public boolean canTake() {
if(slots[2] != null && slots[2].getItem() == ModItems.cell_empty)
{
if(slots[3] == null || (slots[3] != null && slots[3].getItem() == ModItems.cell_uf6 && slots[3].stackSize < slots[3].getMaxStackSize()))
{
if(fillState > 0)
{
return true;
}
}
}
return false;
}
@Override
public void updateEntity() {
if(!worldObj.isRemote)
{
if(this.canGive())
{
this.slots[0].stackSize--;
if(slots[0].stackSize <= 0)
{
slots[0] = null;
}
this.fillState++;
if(slots[1] != null)
{
slots[1].stackSize++;
}
else
{
slots[1] = new ItemStack(ModItems.cell_empty, 1);
}
}
if(this.canTake())
{
this.slots[2].stackSize--;
if(slots[2].stackSize <= 0)
{
slots[2] = null;
}
this.fillState--;
if(slots[3] != null)
{
slots[3].stackSize++;
}
else
{
slots[3] = new ItemStack(ModItems.cell_uf6, 1);
}
}
tank.loadTank(0, 1, slots);
tank.unloadTank(2, 3, slots);
tank.updateTank(xCoord, yCoord, zCoord);
}
}
@ -273,4 +209,9 @@ public class TileEntityMachineUF6Tank extends TileEntity implements ISidedInvent
{
return 65536.0D;
}
@Override
public void setFillstate(int fill, int index) {
tank.setFill(fill);
}
}

View File

@ -373,14 +373,14 @@ public class DesertAtom003
if(tank0 instanceof TileEntityMachineUF6Tank)
{
TileEntityMachineUF6Tank tankuf0 = (TileEntityMachineUF6Tank)tank0;
tankuf0.fillState = rand.nextInt(tankuf0.maxFill);
//tankuf0.fillState = rand.nextInt(tankuf0.maxFill);
}
world.setBlock(x + 29, y + 4, z + 7, Block20, 3, 3);
TileEntity tank1 = world.getTileEntity(x + 29, y + 4, z + 7);
if(tank0 instanceof TileEntityMachineUF6Tank)
{
TileEntityMachineUF6Tank tankuf1 = (TileEntityMachineUF6Tank)tank1;
tankuf1.fillState = rand.nextInt(tankuf1.maxFill);
//tankuf1.fillState = rand.nextInt(tankuf1.maxFill);
}
world.setBlock(x + 30, y + 4, z + 7, Block21, 3, 3);
TileEntity tank2 = world.getTileEntity(x + 30, y + 4, z + 7);