KURUMA
Downloadダウンロード
KurumaMod / Car Pack Guideカーパック作成ガイド / Partsパーツ

Make partsパーツを作る

Body parts such as aero and fenders, exhausts, and turbos and blow-off valves.エアロやフェンダーなどの外装パーツ、マフラー、ターボとブローオフバルブ。

1外装パーツ

1Body parts

ウイング・バンパー・フェンダーなど、車体に固定される部品です。

Wings, bumpers, fenders — parts fixed to the body.

最小のパーツを作る

Make a minimal part

  1. Blender車体の .blend の中に、部品を別のオブジェクトとして作る。名前は part_<場所>-<部品名>(例 part_rear_wing-gt_wing)。場所は下の表から選ぶ
  2. Blender付け替え候補の部品を全部表示にして、車体と一緒に 1 つの .glb に書き出す。
  3. ファイル部品のファイルを置く。data/mypack/car_parts/gt_wing.json(ファイル名が部品名):
    { "slot": "rear_wing" }
  4. lang表示名を lang に書く。"part.mypack.gt_wing": "GT ウイング"

これで、ゲームの G →「パーツ」に、その場所のタブと部品が並びます。

  1. BlenderModel the part as a separate object inside the car's .blend. Name it part_<slot>-<part> (e.g. part_rear_wing-gt_wing); pick the slot from the table below
  2. BlenderUnhide every selectable part and export them together with the body, as one .glb.
  3. FileAdd the part file data/mypack/car_parts/gt_wing.json (the file name is the part name):
    { "slot": "rear_wing" }
  4. langAdd the display name to lang. "part.mypack.gt_wing": "GT Wing"

The slot's tab and the part now appear under G → "Parts" in game.

Four rear wing part objects overlapping inside the S15 model in Blender, all visible in the outliner
図 22. S15 の .blend。ウイングの部品 4 つ(part_rear_wing-…)が車体と同じモデルの中に重なって入っています。アウトライナーで全部を表示(目のアイコンが開いた状態)にしたまま書き出します。ゲームでは付けている 1 つだけが描かれます
Fig. 22. The S15 .blend. Four wing part objects (part_rear_wing-…) overlap inside the same model as the body. Export with all of them visible in the outliner (eye icon open); in game only the fitted one is drawn.

付ける場所(slot)

Slots (slot)

slot入るもの
front_bumperフロントバンパー、リップ、スプリッター、カナード
side_skirtサイドスカート
fenderオーバーフェンダー
rear_wingスポイラー、ウイング、ダックテール
rear_diffuserリアバンパー、ディフューザー
exhaustマフラー(2 章)
slotWhat goes there
front_bumperFront bumper, lip, splitter, canards
side_skirtSide skirts
fenderOver-fenders
rear_wingSpoiler, wing, duck tail
rear_diffuserRear bumper, diffuser
exhaustExhaust (chapter 2)

その車にオブジェクトのある部品も初期装備も無い場所は、タブが出ません。

A slot's tab only appears if the car has an object for one of its parts, or a default part.

必要なときだけ

Only when you need it

走りを変えたい(ダウンフォース aero)

効きを調整しない部品(ダックテールなど)は、数字 1 つで書きます。data/mypack/car_parts/ducktail.json:

{
  "slot": "rear_wing",
  "aero": { "rear": 0.25 }
}

換装画面の「角度」で効きを調整できる部品(GT ウイングなど)は、[最小, 最大] で書きます。前にも効かせたいときは front も書きます。data/mypack/car_parts/gt_wing.json:

{
  "slot": "rear_wing",
  "aero": {
    "rear": [0.6, 1.6],
    "front": 0.1,
    "angle": 0.4
  }
}
  • front / rear … 前と後ろを、どれだけ押し付けるか。大きいほど強い(0〜3)。1 で 200km/h のとき約 190kg
  • 目安: ウイング付きの市販車で前後合わせて 0.3〜0.6、GT 系のレーシングカーで 2〜3
  • angle … 「角度」のスライダーの最初の位置(0〜1、省略で 0.5)。角度で変わるのは走りだけで、見た目は動かない
  • 強くするほど高速コーナーは速くなるが、最高速は落ちる。空気抵抗は自動で決まるので、書く項目はない
  • 前を強くすると曲がりやすく(オーバー)、後ろを強くすると安定する(アンダー)

換装画面の右には、その部品のダウンフォースと、付けたときの配分・グリップ・最高速の目安が出ます。

Change how it drives (downforce, aero)

A part whose effect is fixed (a duck tail, say) takes a single number. data/mypack/car_parts/ducktail.json:

{
  "slot": "rear_wing",
  "aero": { "rear": 0.25 }
}

A part whose effect players can adjust with the parts screen's "Angle" slider (a GT wing, say) takes [min, max]. Add front if it should press the front too. data/mypack/car_parts/gt_wing.json:

{
  "slot": "rear_wing",
  "aero": {
    "rear": [0.6, 1.6],
    "front": 0.1,
    "angle": 0.4
  }
}
  • front / rear — how hard it presses the front and rear down. Bigger is stronger (0 to 3). 1 is about 190 kg at 200 km/h
  • Guide: 0.3–0.6 in total for a road car with a wing, 2–3 for a GT race car
  • angle — where the "Angle" slider starts (0–1, default 0.5). The angle changes driving only; the object does not move
  • More downforce makes fast corners quicker but lowers top speed. Drag follows automatically, so there is nothing to write for it
  • More at the front turns in harder (oversteer); more at the rear is more stable (understeer)

The parts screen shows the part's downforce and how balance, grip and estimated top speed change.

オブジェクトに別の名前を付けたい・1 つの部品で複数のオブジェクトを出したい

名前は part_<部品名>(例 part_gt_wing)でも通ります。どちらの決まりにも合わない名前にしたいときは、車の vehicles/<車>.json に対応を書きます。

"parts": {
  "mypack:twin_muffler": { "show": ["part_exhaust-twin", "part_exhaust-twin_tip"] }
}

show に書けるのは part_ で始まる名前だけです。

Free object names, or several objects for one part

part_<part> (e.g. part_gt_wing) works too. For any other name, map it in the car's vehicles/<car>.json:

"parts": {
  "mypack:twin_muffler": { "show": ["part_exhaust-twin", "part_exhaust-twin_tip"] }
}

Only names starting with part_ are allowed in show.

最初から付いている部品にしたい(初期装備)

車の諸元 data/mypack/cars/<車>.json の、values と同じいちばん外側に書きます。

{
  "values": { "mass": 1250 },
  "default_parts": {
    "rear_wing": "mypack:s15_spoiler",
    "exhaust": { "part": "mypack:stock_muffler", "removable": false }
  }
}
  • 換装画面の「純正」が初期装備になる。外せる初期装備のある場所には「なし」も並ぶ
  • "removable": false なら外せない。外すと穴だけ残る部品に使う
  • 置いてある車にも効く。パックで初期装備を変えれば、すでに置いた車も変わる

部品のカーパックを外すと、その部品を付けていた車は、その場所の初期装備(無ければ純正・ノーマル・なし)に戻ります。外せない初期装備が消えて穴が開くことはありません。付けていた部品の id は残っているので、パックを入れ直せば元の部品に戻ります。

Have it fitted from the start (default parts)

Put them in the car's spec, data/mypack/cars/<car>.json, at the top level next to values:

{
  "values": { "mass": 1250 },
  "default_parts": {
    "rear_wing": "mypack:s15_spoiler",
    "exhaust": { "part": "mypack:stock_muffler", "removable": false }
  }
}
  • "Stock" in the parts screen becomes the default part. Slots with a removable default also get "None"
  • "removable": false means it cannot come off. Use it for parts that would leave a hole
  • It reaches cars already placed: change the default in the pack and existing cars follow

If a part's car pack is removed, cars that had the part fitted go back to that slot's default part (or to stock, normal or none if there is no default). A non-removable default never disappears to leave a hole. The fitted part's id is kept, so putting the pack back restores the part.

仕組みを知りたい(なぜ全部を 1 つのファイルに入れるのか)

ゲームは、車体のモデルの中に入っている部品のオブジェクトを、表示・非表示で切り替えているだけです。付けている部品のオブジェクトだけを描き、残りは描きません。そのため:

  • 車体のモデルに入っていない部品は出せない。部品だけを別のファイルにして、あとから足すことはできない
  • 非表示のまま書き出したオブジェクトはファイルに入らないので、出せない
  • 部品を 1 つ増やしたら、車体のモデルを書き出し直す
  • ほかの人の車には、部品パックだけでは外装パーツを足せない
うまくいかないとき
  • 非表示のまま書き出さない。「選択物のみ」で書き出すと、非表示のオブジェクトは選べないので抜け落ちる
  • 純正の部品も別のオブジェクトにする。body に一体で残した部分は、付け替えても消えない
  • 部品の中の面に light_tail などのマテリアルを割り当てると、部品と一緒に光る(車の 3 章)
  • cars で付けられる車種を絞れる。表示名は part.<パック>.<部品名>
How it works (why everything goes into one file)

The game only shows or hides part objects that are already inside the car's model. It draws the objects of the fitted parts and skips the rest. So:

  • A part that is not in the body model cannot appear. You cannot ship a part as a separate file and add it later
  • An object exported while hidden is not in the file, so it cannot appear either
  • Adding a part means exporting the car's model again
  • A parts-only pack cannot add body parts to someone else's car
When it doesn't work
  • Don't export with objects hidden. With "Selected Objects", hidden objects cannot be selected and drop out
  • Make stock pieces separate objects too. Anything left merged into body stays, whatever is fitted
  • Faces inside a part with a light_tail material light up with the part (chapter 3 of the Car guide)
  • cars limits which cars can fit it. The display name is part.<pack>.<part>

2マフラー

2Exhausts

見た目と排気音を変える部品です。走りは変わりません。

A part that changes the look and the exhaust note. Driving does not change.

最小のマフラーを作る

Make a minimal exhaust

  1. Blender車体の .blend の中に、マフラーを別のオブジェクトとして作る。名前は part_exhaust-<部品名>(例 part_exhaust-titanium)
  2. Blender付け替え候補のマフラーを全部表示にして、車体と一緒に 1 つの .glb に書き出す。
  3. ファイル部品のファイルを置く。data/mypack/car_parts/titanium.json:
    { "slot": "exhaust" }
  4. lang表示名を lang に書く。"part.mypack.titanium": "チタンマフラー"

これで、ゲームの G →「パーツ」→「マフラー」のタブに並びます。このままでは音はその車のままです。

  1. BlenderModel the exhaust as a separate object inside the car's .blend. Name it part_exhaust-<part> (e.g. part_exhaust-titanium)
  2. BlenderUnhide every selectable exhaust and export them together with the body, as one .glb.
  3. FileAdd the part file data/mypack/car_parts/titanium.json:
    { "slot": "exhaust" }
  4. langAdd the display name to lang. "part.mypack.titanium": "Titanium exhaust"

It now appears under G → "Parts" → the "Exhaust" tab. The sound is still the car's own.

必要なときだけ

Only when you need it

音を低く・大きくしたい

見た目の JSON を置きます。assets/mypack/car_parts/titanium.json(素性と同じファイル名):

{
  "exhaust": {
    "pitch": [0.85, 1.00],
    "volume": 1.2,
    "tone": 0.3
  }
}
  • pitch … 音の高さの倍率。1 未満で低くなる。[最小, 最大] で書くと、換装画面の「音の低さ」でその範囲を動かせる
  • volume … 音量の倍率(0〜2)
  • tone … 「音の低さ」の最初の位置(0 でいちばん高い、1 でいちばん低い。省略で 0)
  • 下げるのは 0.78 くらいまでよく効く。上げるのはほとんど効かない(甲高くしたいなら、次の「音源ごと差し替えたい」)
Make it deeper or louder

Add a looks JSON, assets/mypack/car_parts/titanium.json (same file name as the definition):

{
  "exhaust": {
    "pitch": [0.85, 1.00],
    "volume": 1.2,
    "tone": 0.3
  }
}
  • pitch — pitch multiplier; below 1 is deeper. Written as [min, max], the parts screen's "Deepness" slider moves within it
  • volume — volume multiplier (0 to 2)
  • tone — where the "Deepness" slider starts (0 = highest, 1 = lowest; default 0)
  • Going down works well to about 0.78. Going up barely works (for a high-pitched exhaust, see "Use your own sound" below)
音源ごと差し替えたい
  1. 音源を置く(OGG・モノラル、継ぎ目なくループするもの)。assets/mypack/sounds/titanium_exhaust.ogg
  2. パックの assets/mypack/sounds.json にサウンドイベントを書く:
    {
      "titanium_exhaust": {
        "sounds": [{ "name": "mypack:titanium_exhaust" }],
        "attenuation_distance": 64
      }
    }
  3. 見た目の JSON の exhaust で指す:
    {
      "exhaust": { "sound": "mypack:titanium_exhaust" }
    }

高回転まで音程を伸ばしたいときは、1 オクターブ上の音源も作って "sound_high" で指します。sound_tools/make_octave_up.py で作れます。音源の作り方の詳しいことは車の 11 章と同じです。

Use your own sound
  1. Add the sound (OGG, mono, a seamless loop): assets/mypack/sounds/titanium_exhaust.ogg
  2. Declare a sound event in your pack's assets/mypack/sounds.json:
    {
      "titanium_exhaust": {
        "sounds": [{ "name": "mypack:titanium_exhaust" }],
        "attenuation_distance": 64
      }
    }
  3. Point to it from exhaust in the looks JSON:
    {
      "exhaust": { "sound": "mypack:titanium_exhaust" }
    }

To keep the pitch rising at high revs, also make a one-octave-up copy and point "sound_high" at it; sound_tools/make_octave_up.py makes one. More on making sounds in chapter 11 of the Car guide.

純正のマフラーも付け替えられるようにしたい

純正のマフラーも別のオブジェクト(例 part_exhaust-stock)にして部品を作り、車の諸元 data/mypack/cars/<車>.json のいちばん外側で初期装備にします。外すと穴だけ残るなら、外せないようにします:

{
  "values": { ... },
  "default_parts": {
    "exhaust": { "part": "mypack:stock", "removable": false }
  }
}

初期装備の詳しいことは1 章の「最初から付いている部品にしたい」にあります。

Make the stock exhaust swappable too

Make the stock exhaust a separate object too (e.g. part_exhaust-stock), give it a part, and make it a default part at the top level of the car's spec data/mypack/cars/<car>.json. If removing it would leave just a hole, make it non-removable:

{
  "values": { ... },
  "default_parts": {
    "exhaust": { "part": "mypack:stock", "removable": false }
  }
}

More on default parts in chapter 1, "Have it fitted from the start".

うまくいかないとき
  • 「マフラー」のタブが出ない … 車体のモデルにそのオブジェクトが入っていない。非表示のまま書き出していないか見る
  • 差し替えた音が鳴らず、いつもの音のまま … sound の名前が sounds.json に無い。ログに警告が 1 行出ている
  • pitch を 1 より大きくしても高くならない … Minecraft の音程の上限に当たっている。高い音源を sound で差し替える
When it doesn't work
  • No "Exhaust" tab — the object is not in the body model. Check it was not hidden when you exported
  • Your sound does not play; it is the usual one — the sound name is missing from sounds.json. A warning is in the log
  • pitch above 1 does not raise it — Minecraft's pitch ceiling. Replace the source with a higher one via sound

3ターボとブローオフバルブ

3Turbos and blow-off valves

ターボは加速が変わる部品、ブローオフバルブは、ブーストが掛かった状態でアクセルを抜いたときやシフトアップのときに「プシュッ」と鳴るだけの部品です。どちらもモデルは要りません。

A turbo changes how the car accelerates; a blow-off valve only adds the "pssh" when you lift off or shift up under boost. Neither needs a model.

最小のターボを作る

Make a minimal turbo

  1. ファイル部品のファイルを置く。data/mypack/car_parts/my_turbo.json:
    {
      "slot": "turbo",
      "turbo": { "boost": 0.5 }
    }
  2. lang表示名を lang に書く。"part.mypack.my_turbo": "マイタービン"

これで、ゲームの G →「パーツ」→「ターボ」のタブに並びます。boost は全開のときにトルクを何割増やすか(0.5 で 1.5 倍)です。

  1. FileAdd the part file data/mypack/car_parts/my_turbo.json:
    {
      "slot": "turbo",
      "turbo": { "boost": 0.5 }
    }
  2. langAdd the display name to lang. "part.mypack.my_turbo": "My Turbo"

It now appears under G → "Parts" → the "Turbo" tab. boost is how much extra torque at full boost (0.5 means 1.5×).

最小のブローオフバルブを作る

Make a minimal blow-off valve

  1. ファイル部品のファイルを置く。data/mypack/car_parts/my_bov.json:
    { "slot": "blowoff" }
  2. lang表示名を lang に書く。"part.mypack.my_bov": "マイブローオフ"

ターボを付けている車にだけ、「ブローオフ」のタブが出ます。

  1. FileAdd the part file data/mypack/car_parts/my_bov.json:
    { "slot": "blowoff" }
  2. langAdd the display name to lang. "part.mypack.my_bov": "My Blow-off"

The "Blow-off" tab only appears on a car with a turbo fitted.

必要なときだけ

Only when you need it

ターボの効き方を変えたい(立ち上がり・ターボラグ)
{
  "slot": "turbo",
  "turbo": {
    "boost": 0.50,
    "spool_from": 0.30,
    "spool_full": 0.65,
    "spool_rate": 2.0
  }
}
  • boost … 全開のときにトルクを何割増やすか(0〜1.5)
  • spool_from / spool_full … 効き始める回転と、いっぱいに効く回転。アイドルを 0、レブリミットを 1 とした割合で書く。大きいタービンほど高い回転へ寄せる
  • spool_rate … 効きが上がる速さ(0.1〜20)。小さいほどターボラグが長い
  • 書かなかった項目は、純正タービンくらいの値になる

同梱の 2 つ(比べる目安):

boostspool_fromspool_fullspool_rate既定の車の 0-160km/h
なし————11.3 秒
純正タービン0.350.220.553.08.9 秒
ビッグタービン0.700.400.781.48.0 秒
Change how the turbo behaves (spool, lag)
{
  "slot": "turbo",
  "turbo": {
    "boost": 0.50,
    "spool_from": 0.30,
    "spool_full": 0.65,
    "spool_rate": 2.0
  }
}
  • boost — extra torque at full boost (0 to 1.5)
  • spool_from / spool_full — where boost starts and where it is full, as a fraction from idle (0) to the rev limit (1). Bigger turbos sit higher
  • spool_rate — how fast boost builds (0.1 to 20). Smaller means more lag
  • Anything you leave out takes roughly stock-turbo values

The two bundled turbos, for reference:

boostspool_fromspool_fullspool_rateDefault car 0-160 km/h
None————11.3 s
Stock turbo0.350.220.553.08.9 s
Big turbo0.700.400.781.48.0 s
決まった車種にだけ付けたい

cars に車種の id を並べます(ディーゼル車専用のタービン、など)。書かなければ、どの車種にも付けられます。

{
  "slot": "turbo",
  "cars": ["mypack:prado"],
  "turbo": { "boost": 0.4 }
}
Only fit certain cars

List car ids in cars (a turbo only for a diesel, say). Leave it out and every car can fit it.

{
  "slot": "turbo",
  "cars": ["mypack:prado"],
  "turbo": { "boost": 0.4 }
}
ブローオフの音を変えたい

音は部品ではなく車の側で変えます。車の vehicles/<車>.json の sounds に "blowoff" を書きます(車の 11 章)。

Change the blow-off sound

The sound belongs to the car, not the part: set "blowoff" in sounds in the car's vehicles/<car>.json (chapter 11 of the Car guide).

うまくいかないとき
  • 「ブローオフ」のタブが出ない … ターボが付いていない。先にターボを付ける
  • ログに「ターボの部品に turbo が書かれていません」と出る … "turbo": { ... } を書く(書かないと純正タービンくらいの値になる)
  • 見た目が変わらない … ターボとブローオフは、いまは見た目を持たない(換装画面の絵とメーターの TURBO ランプだけ)
When it doesn't work
  • No "Blow-off" tab — no turbo is fitted. Fit a turbo first
  • The log says the turbo part has no turbo — add "turbo": { ... } (without it you get roughly stock-turbo values)
  • Nothing changes on the car's body — turbos and blow-off valves have no looks yet (only the parts-screen icon and the TURBO lamp on the gauges)

4ナンバープレート2.0.0〜

4Licence plates2.0.0+

前後のナンバーです。見た目だけで、走りは変わりません。字はプレイヤーが換装画面で打ち、MOD がプレートの絵に焼き込みます。KurumaMod には日本(自家用・軽・事業用)・EU・UK・US の 6 種類が入っていて、どの車にも付けられます。パックで作るのは、それ以外のデザインのナンバーです。

どこに付けるかはプレートではなく車が決めます(車の 8 章)。プレートの側は形と絵と字の決まりだけを持ちます。

Front and rear plates. Looks only; driving does not change. Players type the text in the parts screen and the mod bakes it into the plate's texture. KurumaMod comes with six styles (Japanese private, kei and commercial, EU, UK and US) that fit any car. What a pack adds is a plate of another design.

Where a plate goes is decided by the car, not the plate (chapter 8 of the Car guide). The plate only brings its shape, its picture and the rules for its text.

最小のナンバーを作る(同梱の形に自分の絵を貼る)

Make a minimal plate (your own picture on a built-in shape)

  1. 画像地の絵を描く。assets/mypack/textures/plate/my_plate.png。地の色・縁・帯だけで、字は描かない。ここでは US の形を借りるので縦横比は 2:1(例 1024×512)
  2. ファイル部品のファイル(素性)を置く。data/mypack/car_parts/my_plate.json。fields が字を打つ欄で、名前は借りる形に合わせる(下の表):
    {
      "slot": "plate",
      "plate": {
        "fields": {
          "top":    { "max": 16, "default": "MY PACK" },
          "text":   { "max": 8, "chars": ["A-Z", "0-9", " ", "-"], "default": "ABC 123" },
          "bottom": { "max": 16, "default": "DRIVE SAFE" }
        }
      }
    }
  3. ファイル見た目のファイルを置く。assets/mypack/car_parts/my_plate.json(素性と同じファイル名):
    {
      "plate": {
        "model": "kurumamod:models/plate/us.obj",
        "texture": "mypack:textures/plate/my_plate.png",
        "fields": {
          "top":    { "color": "#1E326E", "fit": "center" },
          "text":   { "color": "#1E326E", "emboss": 0.02 },
          "bottom": { "color": "#1E326E", "fit": "center" }
        }
      }
    }
  4. lang表示名を lang に書く。"part.mypack.my_plate": "マイナンバー"

これで、ゲームの G →「パーツ」→「ナンバー」のタブに並びます。選ぶと、欄ごとの入力欄が出ます。

  1. ImageDraw the background. assets/mypack/textures/plate/my_plate.png. Only the colour, border and bands; no text. This borrows the US shape, so make it 2:1 (e.g. 1024×512)
  2. FileAdd the part file (definition) data/mypack/car_parts/my_plate.json. fields are the boxes players type into; their names must match the borrowed shape (table below):
    {
      "slot": "plate",
      "plate": {
        "fields": {
          "top":    { "max": 16, "default": "MY PACK" },
          "text":   { "max": 8, "chars": ["A-Z", "0-9", " ", "-"], "default": "ABC 123" },
          "bottom": { "max": 16, "default": "DRIVE SAFE" }
        }
      }
    }
  3. FileAdd the looks file assets/mypack/car_parts/my_plate.json (same file name as the definition):
    {
      "plate": {
        "model": "kurumamod:models/plate/us.obj",
        "texture": "mypack:textures/plate/my_plate.png",
        "fields": {
          "top":    { "color": "#1E326E", "fit": "center" },
          "text":   { "color": "#1E326E", "emboss": 0.02 },
          "bottom": { "color": "#1E326E", "fit": "center" }
        }
      }
    }
  4. langAdd the display name to lang. "part.mypack.my_plate": "My Plate"

It now appears under G → "Parts" → the "Licence plate" tab. Picking it shows a text box for each field.

借りられる形

Shapes you can borrow

model欄の名前絵の縦横比
kurumamod:models/plate/jp.objregion・class・kana・number2:1
kurumamod:models/plate/eu.objcountry(青帯の中)・textおよそ 4.7:1
kurumamod:models/plate/uk.objtextおよそ 4.7:1
kurumamod:models/plate/us.objtop・text・bottom2:1
modelField namesPicture aspect
kurumamod:models/plate/jp.objregion, class, kana, number2:1
kurumamod:models/plate/eu.objcountry (in the blue band), textabout 4.7:1
kurumamod:models/plate/uk.objtextabout 4.7:1
kurumamod:models/plate/us.objtop, text, bottom2:1

同梱の 6 種類の JSON(data/kurumamod/car_parts/plate_*.json と assets/kurumamod/car_parts/plate_*.json)は KurumaMod の jar の中にあります。写して書き換えるのがいちばん早い土台です。

The JSON for the six built-in styles (data/kurumamod/car_parts/plate_*.json and assets/kurumamod/car_parts/plate_*.json) is inside the KurumaMod jar. Copying one and editing it is the quickest start.

必要なときだけ

Only when you need it

打てる字・字の数を決めたい

素性の JSON(data/ 側)の fields に書きます。並べた順がそのまま換装画面の入力欄の順になります。

  • max … 字の数の上限(1〜16、省略で 16)
  • chars … 使える字。"0-9" のような範囲、"-" のような 1 字、名前(hiragana・katakana・kanji・latin(英字の大小)・digits)を並べる。省略するとどの字でも打てる
  • default … 最初に出ている字
  • 欄は 8 つまで。欄の名前は小文字・数字・_・-
  • サーバーもこの決まりで検査します。使えない字・長すぎる字は落とされます
  • fields を書かなければ、字の無い飾りのプレートになります(入力欄は出ない)
Choose which characters can be typed, and how many

Write them under fields in the definition JSON (the data/ side). The order you list them in is the order of the text boxes in the parts screen.

  • max — maximum length (1 to 16, default 16)
  • chars — allowed characters: ranges like "0-9", single characters like "-", or names (hiragana, katakana, kanji, latin (upper and lower case), digits). Left out, anything can be typed
  • default — the text shown at first
  • Up to 8 fields. Field names use lower case, digits, _ and -
  • The server checks text against these rules too; disallowed or overlong text is dropped
  • Without fields, the plate is decorative and has no text (no text boxes appear)
字の見た目(フォント・色・詰め方)を変えたい

見た目の JSON(assets/ 側)の fields に、欄ごとに書きます。どれも省略できます。

  • font … TTF のパス(例 mypack:plate_fonts/my_font.ttf)。省略で Barlow Condensed。配る jar に入れるので、再配布してよいライセンスのフォント(OFL など)を使い、ライセンス文も一緒に入れる
  • color … 字の色(#RRGGBB、省略で黒に近い灰)
  • fit … 枠への収め方。condense(省略時。収まるうちは中央、はみ出すときだけ横に縮める)・justify(短ければ字の間を広げて枠の幅に揃える。日本の地名)・center(condense と同じだが縮めすぎない。小さな字向け)
  • format … upper(大文字にして出す)・jp_serial(日本の一連番号の形。4 桁に右詰めで、空きは「・」)
  • mono … 字の幅を揃える(数字向け)
  • emboss … 型押しの深さ(0〜0.1、枠の高さに対する比。日本・US は 0.02)
Change how the text looks (font, colour, fitting)

Write them per field under fields in the looks JSON (the assets/ side). All are optional.

  • font — a TTF path (e.g. mypack:plate_fonts/my_font.ttf). Default Barlow Condensed. The font ships inside your jar, so use one whose licence allows redistribution (such as the OFL) and include the licence text
  • color — text colour (#RRGGBB; default a near-black grey)
  • fit — how text fills its box: condense (default; centred while it fits, squeezed sideways only when it would overflow), justify (short text is spread to the box width, as for Japanese place names), center (like condense but never squeezed too far; for small text)
  • format — upper (shown in capitals) or jp_serial (the Japanese serial-number layout: right-aligned in four places, blanks filled with "・")
  • mono — equal-width characters (good for numbers)
  • emboss — depth of the pressed-in look (0 to 0.1, as a fraction of the box height; the Japanese and US plates use 0.02)
形から自分で作りたい(バイク用・架空の国など)
  1. Blender で modeling_tools/blender_plate_gauge_custom.py を開き、先頭の SIZE_MM(外形 [mm])と FIELDS(欄の名前と位置)を書き換えてから実行する。各国の規格どおりの大きさなら blender_plate_gauge_jp.py・_eu.py・_uk.py・_us.py を使う
  2. ゲージに合わせてプレートを作る。守ることは次のとおり:
    • 実寸で作る(車に付けるときに伸び縮みしない。大きさは見た目の JSON の scale で変える)
    • 原点は取り付け面の中心(車の plates の pos はこの点を置く位置)
    • 表を −Y(車の前)へ向ける。後ろに付けるときは MOD が回す。前後で作り分けない
    • ゲージの厚みの限界より前へ出さない
    • UV は表の全体に 0〜1 で張る。絵の縦横比はプレートに合わせる
  3. 字の位置は、スクリプトが置く text_<欄> の板で決める。板そのものは描かれません(位置・大きさ・向きだけを読み、その上に字を描く)。欄の名前は JSON の fields と揃える(text_number なら "number")。字をメッシュで作らない(型押しも MOD が描く)
  4. プレートと text_ の板を選んで glTF で書き出し、assets/mypack/models/plate/my_plate.glb に置く。見た目の JSON の model を "mypack:models/plate/my_plate.glb" にする

影はプレートを囲む箱で描かれます。角の丸みや絵の抜きは影に出ません。

Build the shape yourself (motorbike plates, made-up countries…)
  1. Open modeling_tools/blender_plate_gauge_custom.py in Blender, edit SIZE_MM (outline in mm) and FIELDS (field names and positions) at the top, then run it. For a plate of a real country's standard size, use blender_plate_gauge_jp.py, _eu.py, _uk.py or _us.py
  2. Build the plate to the gauge. The rules:
    • Model it at real size (it is not stretched to fit the car; change the size with scale in the looks JSON)
    • The origin is the centre of the mounting face (the car's plates pos places this point)
    • Face it towards −Y (the front of the car). The mod turns it round for the rear; do not make separate front and rear versions
    • Keep it behind the gauge's depth limit
    • Map the UVs across the whole face, 0 to 1. Match the picture's aspect to the plate
  3. The text positions come from the text_<field> boards the script places. The boards themselves are not drawn (only their position, size and angle are read, and the text is drawn on top). Field names must match fields in the JSON (text_number is "number"). Do not model the letters (the pressed-in look is drawn by the mod too)
  4. Select the plate and the text_ boards, export them as glTF to assets/mypack/models/plate/my_plate.glb, and set model in the looks JSON to "mypack:models/plate/my_plate.glb"

The shadow is drawn as a box around the plate; rounded corners and cut-outs in the picture do not show in it.

後ろだけ色を変えたい・大きさを変えたい

見た目の JSON に書きます:

{
  "plate": {
    "model": "...",
    "texture": "mypack:textures/plate/my_plate_front.png",
    "texture_rear": "mypack:textures/plate/my_plate_rear.png",
    "scale": 1.2
  }
}
  • texture_rear … 後ろにだけ使う絵(UK は前が白地・後ろが黄地)
  • scale … 描く大きさの倍率(省略で 1.2、0.1〜3)。メッシュは実寸ですが、車はどれも実車より大きく作ってあるので、実寸のままでは小さく見えます。日本のプレートは 1.15。車の plates の scale はこれに掛かる
Use a different picture at the rear, or change the size

Write these in the looks JSON:

{
  "plate": {
    "model": "...",
    "texture": "mypack:textures/plate/my_plate_front.png",
    "texture_rear": "mypack:textures/plate/my_plate_rear.png",
    "scale": 1.2
  }
}
  • texture_rear — picture used only at the rear (UK plates are white at the front and yellow at the rear)
  • scale — drawing size multiplier (default 1.2, 0.1 to 3). Meshes are real size, but every car is built larger than the real thing, so a real-size plate looks small. Japanese plates use 1.15. The car's plates scale is applied on top
入力欄の名前を出したい

換装画面の入力欄の横に出る名前は、lang の "plate.<名前空間>.<部品>.field.<欄>" です(例 "plate.mypack.my_plate.field.top": "上の字")。書かなければ、同梱の欄と同じ名前(region・class・kana・number・country・text・top・bottom)ならその訳が出て、それ以外は欄の名前がそのまま出ます。

Name the text boxes

The label next to each text box in the parts screen is the lang key "plate.<namespace>.<part>.field.<field>" (e.g. "plate.mypack.my_plate.field.top": "Top line"). Without it, a field named like a built-in one (region, class, kana, number, country, text, top, bottom) uses that translation; any other name is shown as is.

最初から付けておきたい

車の諸元 data/mypack/cars/<車>.json のいちばん外側で初期装備にします。同梱のナンバーも、自分のナンバーも指せます:

{
  "values": { ... },
  "default_parts": {
    "plate": "kurumamod:plate_jp_private"
  }
}

書かなければ、プレイヤーが選ぶまでナンバーは付きません。字は部品の default で始まり、プレイヤーが打ち替えます。付ける位置は車の plates の先頭です(車の 8 章)。

Have one fitted from the start

Make it a default part at the top level of the car's spec data/mypack/cars/<car>.json. It can point to a built-in plate or to your own:

{
  "values": { ... },
  "default_parts": {
    "plate": "kurumamod:plate_jp_private"
  }
}

Without it, there is no plate until the player picks one. The text starts as the part's default and players retype it. It goes in the first position of the car's plates (chapter 8 of the Car guide).

うまくいかないとき
  • 「ナンバー」のタブに並ぶのに、車に何も付かない … 見た目の JSON(assets/ 側)が無いか、model・texture が欠けている。ログに ナンバーの見た目の定義 で始まる行が出ている
  • 入力欄は出るのに、字が描かれない … メッシュに text_<欄> の板が無いか、欄の名前が fields と違う
  • 字が裏返る・上下が逆 … プレートの表が −Y を向いていない。Blender の正面図(テンキー 1)で字が普通に読める向きにする
  • 字が横に潰れる … 枠より長い字を打った。枠を広げるか、max を減らす
  • 付く位置がずれている … 車の側の plates を直す(車の 8 章)
When it doesn't work
  • It is listed in the "Licence plate" tab but nothing appears on the car — the looks JSON (the assets/ side) is missing, or lacks model or texture. A line about the plate's looks definition is in the log
  • The text boxes appear but no text is drawn — the mesh has no text_<field> board, or its name differs from fields
  • The text is mirrored or upside down — the plate does not face −Y. In Blender's front view (numpad 1) the text should read normally
  • The text is squashed sideways — the text is longer than its box. Widen the box or lower max
  • It sits in the wrong place — fix the car's plates (chapter 8 of the Car guide)

5チェックリスト

5Checklist

見落としやすいところを並べます。症状が出てから探すときは配布の 3 章へ。

What is easy to miss. If something is already wrong, go to chapter 3 of Shipping.

外装パーツ・マフラーを入れたとき(Blender)

If you added body parts or exhausts (in Blender)

  • 部品のオブジェクト名が part_<場所>-<部品名> で、部品名が car_parts/ のファイル名と同じ
  • 付け替える純正の部分も、body から分けて別のオブジェクトにした
  • 付け替え候補の部品を全部表示にしてから選んだ(非表示のものは書き出されない)
  • 部品の中のライトは、その面に light_ のマテリアルを割り当てた
  • Part objects are named part_<slot>-<part>, and the part name matches the file name in car_parts/
  • Stock pieces that can be swapped are split from body into their own objects
  • Every selectable part was unhidden before selecting (hidden objects are not exported)
  • Lights inside a part use a light_ material on those faces

ナンバーを入れたとき

If you added a licence plate

  • 素性(data/)と見た目(assets/)の car_parts/ に、同じファイル名で両方置いた
  • 見た目の fields と素性の fields の欄の名前が、メッシュの text_<欄> と揃っている
  • 地の絵に字を描いていない(字は MOD が描く)
  • 自分で作った形なら、実寸・原点は取り付け面の中心・表は −Y で書き出した
  • フォントを入れたなら、再配布してよいライセンスで、ライセンス文も入れた
  • Both the definition (data/) and the looks (assets/) are in car_parts/ under the same file name
  • Field names in both fields match the mesh's text_<field> boards
  • No text is painted on the background picture (the mod draws the text)
  • For your own shape: real size, origin at the centre of the mounting face, face towards −Y
  • Any font you included may be redistributed, and its licence text is included

付録 A. 部品の全項目

Appendix A. Every part key

ホイールとタイヤの項目は、ホイールの付録 A・タイヤの付録 Aにあります。

Wheel and tyre keys are in the Wheel guide's Appendix A and the Tyre guide's Appendix A.

_ で始まるキーは読み飛ばされます。JSON にはコメントが書けないので、"_comment": "…" のようにメモを残せます。

Keys starting with _ are skipped. JSON has no comments, so use "_comment": "…" to leave notes.

素性 — data/<pack>/car_parts/<part>.json

キー型既定値意味
slot文字列必須付ける場所。"wheel"・"tire"・"turbo"・"blowoff"・"front_bumper"・"side_skirt"・"fender"・"rear_wing"・"rear_diffuser"・"exhaust"・"plate"
order整数100換装画面に並ぶ順
cars車種 id の配列(すべての車種)付けられる車種。読める値が 1 つも無ければ、その部品は捨てられる
turbo.boost数字0.35ターボだけ。ブーストいっぱいでトルクを何割増やすか(0〜1.5)
turbo.spool_from数字0.25ターボだけ。過給が立ち上がり始める回転の割合(アイドル 0〜レブ 1。0〜0.95)
turbo.spool_full数字0.60ターボだけ。過給がいっぱいになる回転の割合(spool_from より少し上〜1)
turbo.spool_rate数字3.0ターボだけ。ブーストが上がる速さ [1/秒](0.1〜20)
aero.front / aero.rear数字 or [最小, 最大]0外装パーツだけ。その軸のダウンフォースの面積 [m²](0〜3)。範囲なら角度で調整できる(パーツの 1 章)
aero.angle数字0.5外装パーツだけ。調整していないときの角度(0〜1)
plate.fields.<欄>.max整数16ナンバーだけ。字の数の上限(1〜16)。欄は 8 つまで、並べた順が入力欄の順。欄の名前は小文字・数字・_ - の 32 字まで
plate.fields.<欄>.chars文字列の配列(どの字でも)ナンバーだけ。使える字。範囲 "0-9"・1 字・名前(hiragana・katakana・kanji・latin・digits)
plate.fields.<欄>.default文字列""ナンバーだけ。最初に出ている字(chars と max に合わない字は落とされる)

Definition — data/<pack>/car_parts/<part>.json

KeyTypeDefaultMeaning
slotstringrequiredWhere it fits: "wheel", "tire", "turbo", "blowoff", "front_bumper", "side_skirt", "fender", "rear_wing", "rear_diffuser", "exhaust" or "plate"
orderinteger100Position in the parts screen
carsarray of car ids(every car)Which cars can fit it. If none of the values can be read, the part is dropped
turbo.boostnumber0.35Turbos only. Extra torque at full boost (0 to 1.5)
turbo.spool_fromnumber0.25Turbos only. Where boost starts to build, as a fraction from idle (0) to the rev limit (1); 0 to 0.95
turbo.spool_fullnumber0.60Turbos only. Where boost is full (just above spool_from to 1)
turbo.spool_ratenumber3.0Turbos only. How fast boost builds [1/s] (0.1 to 20)
aero.front / aero.rearnumber or [min, max]0Body parts only. Downforce area on that axle [m²] (0 to 3). A range is adjustable by angle (chapter 1 of the Parts guide)
aero.anglenumber0.5Body parts only. Default angle (0 to 1)
plate.fields.<field>.maxinteger16Plates only. Maximum length (1 to 16). Up to 8 fields; the order is the order of the text boxes. Field names: lower case, digits and _ -, up to 32 characters
plate.fields.<field>.charsarray of strings(anything)Plates only. Allowed characters: ranges like "0-9", single characters, or names (hiragana, katakana, kanji, latin, digits)
plate.fields.<field>.defaultstring""Plates only. The text shown at first (characters outside chars or beyond max are dropped)

マフラーの音 — assets/<pack>/car_parts/<part>.json("exhaust": { ... } の中。いちばん外側には書けない)

キー型既定値意味
pitch数字 or [最小, 最大]1音程の倍率(0.5〜1.5)。範囲なら「音の低さ」で動かせる
volume数字1音量の倍率(0〜2)
soundid(その車の音)排気音のサウンドイベント
sound_highid(無し)高回転側(1 オクターブ上)のサウンドイベント
tone数字0調整していないときの低さ(0〜1)

Exhaust sound — assets/<pack>/car_parts/<part>.json (inside "exhaust": { ... }; not at the top level)

KeyTypeDefaultMeaning
pitchnumber or [min, max]1Pitch multiplier (0.5 to 1.5). A range is adjustable with "Deepness"
volumenumber1Volume multiplier (0 to 2)
soundid(the car's)Exhaust sound event
sound_highid(none)High-rev (one octave up) sound event
tonenumber0Default deepness (0 to 1)

ナンバーの見た目 — assets/<pack>/car_parts/<part>.json("plate": { ... } の中)

キー型既定値意味
modelパス必須プレートのモデル(.glb。Wavefront の .obj も可)。同梱の形は kurumamod:models/plate/jp.obj・eu.obj・uk.obj・us.obj
textureパス必須地の絵。字は描かない
texture_rearパス(texture と同じ)後ろにだけ使う絵
scale数字1.2描く大きさの倍率(0.1〜3)
fields.<欄>.fontパスBarlow Condensed字の TTF
fields.<欄>.color#RRGGBB#141414字の色
fields.<欄>.fit文字列condense枠への収め方。condense・justify・center
fields.<欄>.format文字列(そのまま)upper(大文字)・jp_serial(日本の一連番号)
fields.<欄>.mono真偽false字の幅を揃える
fields.<欄>.emboss数字0型押しの深さ(0〜0.1)

Plate looks — assets/<pack>/car_parts/<part>.json (inside "plate": { ... })

KeyTypeDefaultMeaning
modelpathrequiredThe plate model (.glb; a Wavefront .obj works too). Built-in shapes: kurumamod:models/plate/jp.obj, eu.obj, uk.obj, us.obj
texturepathrequiredThe background picture, without text
texture_rearpath(same as texture)Picture used only at the rear
scalenumber1.2Drawing size multiplier (0.1 to 3)
fields.<field>.fontpathBarlow CondensedTTF for the text
fields.<field>.color#RRGGBB#141414Text colour
fields.<field>.fitstringcondenseHow text fills its box: condense, justify or center
fields.<field>.formatstring(as typed)upper (capitals) or jp_serial (Japanese serial number)
fields.<field>.monoboolfalseEqual-width characters
fields.<field>.embossnumber0Depth of the pressed-in look (0 to 0.1)

車の側 — 初期装備(data/<pack>/cars/<car>.json のいちばん外側)と対応(assets/<pack>/vehicles/<car>.json)

キー型意味
default_parts.<場所>部品 id or {"part": id, "removable": 真偽}何も付けていないときの部品。removable の既定は true。ホイールとタイヤの既定はそれぞれのページの付録
parts.<部品 id>.showオブジェクト名の配列その部品を付けたときに出すオブジェクト(part_ で始まる名前だけ)
plates.front / plates.rear候補の配列ナンバーを付ける位置。候補は id・pos・yaw・pitch・scale・anchor(車の 8 章)

On the car — default parts (top level of data/<pack>/cars/<car>.json) and mapping (assets/<pack>/vehicles/<car>.json)

KeyTypeMeaning
default_parts.<slot>part id or {"part": id, "removable": bool}The part fitted when nothing is chosen. removable defaults to true. For wheel and tyre defaults, see the appendix on their pages
parts.<part id>.showarray of object namesObjects shown while that part is fitted (names starting with part_ only)
plates.front / plates.reararray of candidatesWhere licence plates go. Each has id, pos, yaw, pitch, scale and anchor (chapter 8 of the Car guide)

KurumaMod — 諸元の全項目は車の付録 A。ゲージスクリプトは modeling_tools/blender_gauge.py・modeling_tools/blender_wheel_gauge.py・modeling_tools/blender_tire_gauge.py、ナンバーは modeling_tools/blender_plate_gauge_*.py。

KurumaMod — every spec key is in Appendix A of the Car guide. The gauge scripts are modeling_tools/blender_gauge.py, modeling_tools/blender_wheel_gauge.py and modeling_tools/blender_tire_gauge.py, plus modeling_tools/blender_plate_gauge_*.py for plates.