First Machine Age's Mods (Combined repo.)
修订版 | 8628bffda799ce0a7cd7752bf7f9e5050f88cc51 (tree) |
---|---|
时间 | 2022-02-04 09:46:01 |
作者 | melchior <melchior@user...> |
Commiter | melchior |
Working Brazier
Mostly functional, tweaks still needed
@@ -90,6 +90,7 @@ | ||
90 | 90 | <Compile Include="BlockClasses\CollapsingBlock.cs" /> |
91 | 91 | <Compile Include="BlockClasses\FalseWall.cs" /> |
92 | 92 | <Compile Include="BlockBehaviors\BlockBehaviorNeedSides.cs" /> |
93 | + <Compile Include="BlockClasses\RectangularBrazier.cs" /> | |
93 | 94 | </ItemGroup> |
94 | 95 | <ItemGroup> |
95 | 96 | <Folder Include="BlockClasses\" /> |
@@ -61,18 +61,20 @@ namespace FirstMachineAge | ||
61 | 61 | |
62 | 62 | private void RegisterBlockClasses( ) |
63 | 63 | { |
64 | - CoreAPI.RegisterBlockClass("BoltableDoor", typeof(BoltableDoor)); | |
65 | - CoreAPI.RegisterBlockClass("FalseWall", typeof(FalseWall)); | |
66 | - CoreAPI.RegisterBlockEntityClass(BoltableDoorEntityNameKey, typeof(BoltableDoorBlockEntity)); | |
64 | + CoreAPI.RegisterBlockClass(@"BoltableDoor", typeof(BoltableDoor)); | |
65 | + CoreAPI.RegisterBlockClass(@"FalseWall", typeof(FalseWall)); | |
66 | + CoreAPI.RegisterBlockClass(@"CollapsingBlock", typeof(CollapsingBlock)); | |
67 | + CoreAPI.RegisterBlockClass(@"RectangularBrazier", typeof(RectangularBrazier)); | |
68 | + | |
67 | 69 | |
68 | - CoreAPI.RegisterBlockClass("CollapsingBlock", typeof(CollapsingBlock)); | |
70 | + CoreAPI.RegisterBlockEntityClass(BoltableDoorEntityNameKey, typeof(BoltableDoorBlockEntity)); | |
69 | 71 | } |
70 | 72 | |
71 | 73 | private void RegisterBehaviorClasses( ) |
72 | 74 | { |
73 | - CoreAPI.RegisterBlockBehaviorClass("FreeReinforcement", typeof(BlockBehaviorFreeReinforcement)); | |
74 | - CoreAPI.RegisterBlockBehaviorClass("VerticalOrentiation",typeof(BlockBehaviorVerticalOrientation)); | |
75 | - CoreAPI.RegisterBlockBehaviorClass("NeedSides", typeof(BlockBehaviorNeedSides)); | |
75 | + CoreAPI.RegisterBlockBehaviorClass(@"FreeReinforcement", typeof(BlockBehaviorFreeReinforcement)); | |
76 | + CoreAPI.RegisterBlockBehaviorClass(@"VerticalOrentiation",typeof(BlockBehaviorVerticalOrientation)); | |
77 | + CoreAPI.RegisterBlockBehaviorClass(@"NeedSides", typeof(BlockBehaviorNeedSides)); | |
76 | 78 | } |
77 | 79 | } |
78 | 80 |
@@ -1,29 +1,31 @@ | ||
1 | 1 | { |
2 | - code: "brazier", | |
2 | + code: "brazier", | |
3 | + class: "RectangularBrazier", | |
3 | 4 | maxstacksize: 1, |
4 | 5 | variantgroups: [ |
5 | - { code: "state", states: ["unfueld","unlit","ignighted","extinguished"] } | |
6 | + { code: "state", states: ["empty","fueled","lit","extinct"] } | |
6 | 7 | ], |
7 | 8 | behaviorsByType: { |
8 | - "*-ignighted": [{ name: "HeatSource", properties: { heatStrength: 8 } }], | |
9 | - "*": [{name: "Unstable"}], | |
9 | + "*-lit": [{ name: "HeatSource", properties: { heatStrength: 8 } }], | |
10 | + "*-fueled": [{ name: "Ignitable" }], | |
11 | + "*": [{name: "UnstableFalling"}], | |
10 | 12 | }, |
11 | 13 | renderpass: "OpaqueNoCull", |
12 | 14 | shapeByType: { |
13 | - "*-unfueld": { | |
15 | + "*-empty": { | |
14 | 16 | base: "block/metal/brazier2", SelectiveElements:["Base/Leg*","Base/Grille1"], |
15 | 17 | |
16 | 18 | }, |
17 | - "*-unlit": { | |
19 | + "*-fueled": { | |
18 | 20 | base: "block/metal/brazier2", SelectiveElements:["Base/Leg*","Base/Grille1","Base/Fuel/Coal*",], |
19 | 21 | |
20 | 22 | }, |
21 | - "*-ignighted": { | |
22 | - base: "block/metal/brazier2", SelectiveElements:["Base/Leg*","Base/Grille1","Base/Fuel/Embers"], | |
23 | + "*-lit": { | |
24 | + base: "block/metal/brazier2", SelectiveElements:["Base/Leg*","Base/Grille1","Base/Embers"], | |
23 | 25 | |
24 | 26 | }, |
25 | - "*-extinguished": { | |
26 | - base: "block/metal/brazier2", SelectiveElements:["Base/Leg*","Base/Grille1","Base/Fuel/Ash/Lump*"], | |
27 | + "*-extinct": { | |
28 | + base: "block/metal/brazier2", SelectiveElements:["Base/Leg*","Base/Grille1","Base/Ash/Lump*"], | |
27 | 29 | |
28 | 30 | }, |
29 | 31 | }, |
@@ -34,7 +36,14 @@ | ||
34 | 36 | "coal": { base: "game:block/coal/charcoal"}, |
35 | 37 | "rusty-iron": { base: "game:block/currency/rusty-iron"}, |
36 | 38 | }, |
37 | - creativeinventory: { "general": ["*"], "decorative": ["*"] , "defensive": ["*"] }, | |
39 | + attributes: { | |
40 | + transientProps: { | |
41 | + convertFrom: "brazier-lit", | |
42 | + convertTo: "brazier-extinct", | |
43 | + inGameHours: "100", | |
44 | + } | |
45 | + }, | |
46 | + creativeinventory: { "decorative": ["brazier-empty"] , "defensive": ["brazier-empty"] }, | |
38 | 47 | blockmaterial: "Metal", |
39 | 48 | replaceable: 200, |
40 | 49 | lightAbsorption: 0, |
@@ -42,23 +51,24 @@ | ||
42 | 51 | sideopaque: { all: false }, |
43 | 52 | sidesolid: { all: false }, |
44 | 53 | lightHsvByType: { |
45 | - "*-ignighted": [8, 5, 10], | |
54 | + "*-lit": [8, 12, 5], | |
46 | 55 | }, |
47 | 56 | particlePropertiesByType: { |
48 | - "*-ignighted": [ | |
49 | - { | |
50 | - "__comment": "Fire quads", | |
51 | - hsvaColor: [{ avg: 20, var: 20 }, { avg: 255, var: 50 }, { avg: 255, var: 50 }, { avg: 255, var: 0 }], | |
52 | - opacityEvolve: { transform: "quadratic", factor: -16 }, | |
53 | - gravityEffect: { avg: 0, var: 0 }, | |
57 | + "*-lit": [ | |
58 | + { | |
59 | + hsvaColor: [{ avg: 50, var: 10 }, { avg: 255, var: 0 }, { avg: 200, var: 10 }, { avg: 250, var: 0 }], | |
60 | + posOffset: [{ avg: 0.55, var: 0.06 },{ avg: 0.65, var: -0.9 },{ avg: 0.0, var: -0.35 }], | |
61 | + velocity: [{ avg: 0.1, var: 0.5 },{ avg: 0.1, var: -0.1 },{ avg: -0.2, var: -0.1 }], | |
62 | + opacityEvolve: { transform: "linear", factor: -90 }, | |
63 | + gravityEffect: { avg: -0.02, var: 0.0 }, | |
54 | 64 | velocity: [ { avg: 0, var: 0.0125 }, { avg: 0.03, var: 0.01 }, { avg: 0, var: 0.0125 }], |
55 | - quantity: { avg: 0.1 }, | |
65 | + quantity: { avg: 0.3 }, | |
56 | 66 | size: { avg: 0.05, var: 0.025 }, |
57 | - lifeLength: { avg: 0.5 }, | |
58 | - sizeEvolve: { transform: "linear", factor: 0.1 }, | |
67 | + lifeLength: { avg: 0.15, var: 0.35 }, | |
68 | + sizeEvolve: { transform: "linear", factor: -0.15 }, | |
59 | 69 | particleModel: "Quad", |
60 | 70 | vertexFlags: 128, |
61 | - windAffectednes: 0.05 | |
71 | + windAffectednes: 0.3 | |
62 | 72 | } |
63 | 73 | ] |
64 | 74 | }, |
@@ -66,10 +76,10 @@ | ||
66 | 76 | "place": "game:block/anvil", |
67 | 77 | "break": "game:block/anvil", |
68 | 78 | "hit": "game:block/anvil", |
69 | - ambientByType: { "*-ignighted": "game:effect/embers" } | |
79 | + ambientByType: { "*-lit": "game:effect/embers" } | |
70 | 80 | }, |
71 | 81 | drops: [ |
72 | - { type: "block", code: "brazier-unlit", quantity: { avg: 1 } } | |
82 | + { type: "block", code: "brazier-empty", quantity: { avg: 1 } } | |
73 | 83 | ], |
74 | 84 | materialDensity: 9000, |
75 | 85 | collisionSelectionBox: { x1: 0, y1: 0, z1: 0.25, x2: 1, y2: 0.75, z2: 0.75 }, |
@@ -49,7 +49,7 @@ | ||
49 | 49 | { avg: 0.0, var: 0.0 },{ avg: 0, var: 0 },{ avg: 0.0, var: 0.0 } |
50 | 50 | ], |
51 | 51 | hsvaColor: [ |
52 | - { avg: 140, var: 15 }, { avg: 250, var: 5 }, { avg: 200, var: 5 }, { avg: 150, var: 0 } | |
52 | + { avg: 140, var: 15 }, { avg: 200, var: 5 }, { avg: 200, var: 5 }, { avg: 10, var: 5 } | |
53 | 53 | ], |
54 | 54 | quantity: { avg: 3, var: 1 }, |
55 | 55 | lifeLength: { avg: 0.12, var: 0.03 }, |
@@ -57,7 +57,7 @@ | ||
57 | 57 | size: { avg: 0.06, var: 0.01 }, |
58 | 58 | particleModel: "Quad", |
59 | 59 | sizeEvolve: { transform: "linear", factor: 0.12 }, |
60 | - opacityEvolve: { transform: "quadratic", factor: -25 }, | |
60 | + opacityEvolve: { transform: "quadratic", factor: -5 }, | |
61 | 61 | redEvolve: { transform: "quadratic", factor: -1, maxvalue: 30 }, |
62 | 62 | dieInLiquid: true, |
63 | 63 | windAffectednes: 0.06, |
@@ -71,7 +71,7 @@ | ||
71 | 71 | { avg: 0.0, var: 0.0 },{ avg: 0, var: 0 },{ avg: 0.0, var: 0.0 } |
72 | 72 | ], |
73 | 73 | hsvaColor: [ |
74 | - { avg: 140, var: 15 }, { avg: 250, var: 5 }, { avg: 200, var: 5 }, { avg: 150, var: 0 } | |
74 | + { avg: 140, var: 15 }, { avg: 200, var: 5 }, { avg: 200, var: 5 }, { avg: 10, var: 5 } | |
75 | 75 | ], |
76 | 76 | quantity: { avg: 3, var: 1 }, |
77 | 77 | lifeLength: { avg: 0.12, var: 0.03 }, |
@@ -79,7 +79,7 @@ | ||
79 | 79 | size: { avg: 0.06, var: 0.01 }, |
80 | 80 | particleModel: "Quad", |
81 | 81 | sizeEvolve: { transform: "linear", factor: 0.12 }, |
82 | - opacityEvolve: { transform: "quadratic", factor: -25 }, | |
82 | + opacityEvolve: { transform: "quadratic", factor: -5 }, | |
83 | 83 | redEvolve: { transform: "quadratic", factor: -1, maxvalue: 30 }, |
84 | 84 | dieInLiquid: true, |
85 | 85 | windAffectednes: 0.06, |
@@ -93,7 +93,7 @@ | ||
93 | 93 | { avg: 0.0, var: 0.0 },{ avg: 0, var: 0 },{ avg: 0.0, var: 0.0 } |
94 | 94 | ], |
95 | 95 | hsvaColor: [ |
96 | - { avg: 140, var: 15 }, { avg: 250, var: 5 }, { avg: 200, var: 5 }, { avg: 150, var: 0 } | |
96 | + { avg: 140, var: 15 }, { avg: 200, var: 5 }, { avg: 200, var: 5 }, { avg: 10, var: 5 } | |
97 | 97 | ], |
98 | 98 | quantity: { avg: 3, var: 1 }, |
99 | 99 | lifeLength: { avg: 0.12, var: 0.03 }, |
@@ -101,7 +101,7 @@ | ||
101 | 101 | size: { avg: 0.06, var: 0.01 }, |
102 | 102 | particleModel: "Quad", |
103 | 103 | sizeEvolve: { transform: "linear", factor: 0.12 }, |
104 | - opacityEvolve: { transform: "quadratic", factor: -25 }, | |
104 | + opacityEvolve: { transform: "quadratic", factor: -5 }, | |
105 | 105 | redEvolve: { transform: "quadratic", factor: -1, maxvalue: 30 }, |
106 | 106 | dieInLiquid: true, |
107 | 107 | windAffectednes: 0.06, |
@@ -115,7 +115,7 @@ | ||
115 | 115 | { avg: 0.0, var: 0.0 },{ avg: 0, var: 0 },{ avg: 0.0, var: 0.0 } |
116 | 116 | ], |
117 | 117 | hsvaColor: [ |
118 | - { avg: 140, var: 15 }, { avg: 250, var: 5 }, { avg: 200, var: 5 }, { avg: 150, var: 0 } | |
118 | + { avg: 140, var: 15 }, { avg: 200, var: 5 }, { avg: 200, var: 5 }, { avg: 10, var: 5 } | |
119 | 119 | ], |
120 | 120 | quantity: { avg: 3, var: 1 }, |
121 | 121 | lifeLength: { avg: 0.12, var: 0.03 }, |
@@ -123,7 +123,7 @@ | ||
123 | 123 | size: { avg: 0.06, var: 0.01 }, |
124 | 124 | particleModel: "Quad", |
125 | 125 | sizeEvolve: { transform: "linear", factor: 0.12 }, |
126 | - opacityEvolve: { transform: "quadratic", factor: -25 }, | |
126 | + opacityEvolve: { transform: "quadratic", factor: -5 }, | |
127 | 127 | redEvolve: { transform: "quadratic", factor: -1, maxvalue: 30 }, |
128 | 128 | dieInLiquid: true, |
129 | 129 | windAffectednes: 0.06, |
@@ -15,6 +15,7 @@ | ||
15 | 15 | "defensive:block-log_cornercade-*":"Log Corner Barricade", |
16 | 16 | "defensive:block-crusie_lamp-oil":"Crusie Lamp (oil)", |
17 | 17 | "defensive:block-crusie_lamp-alcohol":"Crusie Lamp (spirit)", |
18 | + "defensive:block-brazier-*":"Rectangular Brazier", | |
18 | 19 | |
19 | 20 | "defensive:item-crusie_shell":"Incomplete Crusie Lamp (shell)", |
20 | 21 |
@@ -23,13 +24,17 @@ | ||
23 | 24 | "defensive:blockdesc-grille_horizontal-*": "A horizontal grille of latticed wrought iron bars.", |
24 | 25 | "defensive:blockdesc-grille_vertical-*": "Vertical cross-bars of sturdy iron.", |
25 | 26 | "defensive:blockdesc-log_barricade-*":"A rough barrier fit for the Frontier.", |
26 | - "defensive:blockdesc-crusie_lamp-*":"Burn the midnight fuel 4x FASTER.", | |
27 | + "defensive:blockdesc-crusie_lamp-*":"Burn that midnight fuel faster.", | |
28 | + "defensive:blockdesc-brazier-empty":"Needs fuel...", | |
29 | + "defensive:blockdesc-brazier-extinct":"Needs fuel again...", | |
30 | + "defensive:blockdesc-brazier-lit":"What a lovely warm glow.", | |
27 | 31 | |
28 | 32 | "game:tabname-defensive":"Defensive Stuff", |
29 | 33 | |
30 | 34 | "defensive:placefailure-requirehorizontalside": "Cannot place block here! It needs one solid sided block adjacent.", |
31 | 35 | "defensive:ingameerror-requirehorizontalside": "Cannot place that here! Needs an adjacent solid sided block.", |
32 | 36 | "defensive:ingameerror-boltedclosed":"Bolted Shut.", |
37 | + "defensive:ingameerror-lackfuel":"Insufficient for fueling this, needs more fuel...", | |
33 | 38 | "defensive:bolted_shut": "<font color='red'>Bolted Shut!</font>", |
34 | 39 | "defensive:bolted_open": "Its Open.", |
35 | 40 | } |
\ No newline at end of file |
@@ -174,11 +174,11 @@ | ||
174 | 174 | "rotationOrigin": [ 8.0, -1.75, 0.75 ], |
175 | 175 | "rotationX": -45.0, |
176 | 176 | "faces": { |
177 | - "north": { "texture": "#ember", "uv": [ 1.0, 10.5, 14.0, 13.0 ], "glow": 128 }, | |
178 | - "east": { "texture": "#ember", "uv": [ 6.0, 4.5, 13.0, 7.0 ], "glow": 128 }, | |
179 | - "south": { "texture": "#ember", "uv": [ 1.0, 5.5, 14.0, 8.0 ], "glow": 128 }, | |
180 | - "west": { "texture": "#ember", "uv": [ 5.5, 4.5, 12.5, 7.0 ], "glow": 128 }, | |
181 | - "up": { "texture": "#ember", "uv": [ 1.0, 4.5, 14.0, 11.5 ], "glow": 128 }, | |
177 | + "north": { "texture": "#ember", "uv": [ 1.0, 10.5, 14.0, 13.0 ], "glow": 255 }, | |
178 | + "east": { "texture": "#ember", "uv": [ 6.0, 4.5, 13.0, 7.0 ], "glow": 255 }, | |
179 | + "south": { "texture": "#ember", "uv": [ 1.0, 5.5, 14.0, 8.0 ], "glow": 255 }, | |
180 | + "west": { "texture": "#ember", "uv": [ 5.5, 4.5, 12.5, 7.0 ], "glow": 255 }, | |
181 | + "up": { "texture": "#ember", "uv": [ 1.0, 4.5, 14.0, 11.5 ], "glow": 255 }, | |
182 | 182 | "down": { "texture": "#ember", "uv": [ 0.5, 4.0, 13.5, 11.0 ], "enabled": false } |
183 | 183 | } |
184 | 184 | }, |
@@ -1,7 +1,7 @@ | ||
1 | 1 | { |
2 | 2 | "type": "code", |
3 | 3 | "name": "Defensive Structures", |
4 | - "description" : "Defensive structures & emplacements, ideal for outposts, castles, forts...", | |
4 | + "description" : "Defensive structures & barriers; ideal for outposts, castles, forts...", | |
5 | 5 | "authors": ["Melchior"], |
6 | 6 | "version": "0.1.6", |
7 | 7 | "ModID":"defensive", |