連なったキャラクターを少しディレイさせてジャンプさせる方法の一つとして、 見えない当たり判定をとばして、タイミングを取る方法があります。 当たり判定は、ジャンプするだけのあたりになります。 One method to make connected characters jump with a slight delay is to send...
習い事
ボールクローン全体の状態を見て、見た目を変化させる場合は ボールクローン全体を管理する変数hを作って、 hの変化に対してフラッシュするように実装します。 You need to create a variable h to manage all the ball clones. When...
水がよごれにぶつかったら、状態を変更して動きを変える。 変数で状態を変化させればOKです。 If the water collides with dirt, update its state and adjust its movement. This can...
IKを使うことで自然な関節の動きが表現できます。 ゲームのキャラクターの動きや、ロボットアームなどで使われる技術ですね。 Inverse Kinematics (IK) allows for the creation of natural and realistic joint movements.It’s a key...
ゴムのような動きを作るためには、 目的地までの速度を毎フレーム減衰させることで実現しています。 To create a rubber-like motion, you can achieve it by gradually reducing the speed toward...
指数関数 𝑒^𝑥 による螺旋曲線は、角度に応じて半径が連続的に増加するため、見た目に滑らかで誤差の少ない渦を作ることができる we can create smooth, precise spirals because the eponential function e^x produces a continuously...
ネイピア数を使うことで少しずつ大きくなる現象を自然に表現できます。 100円を1年で1割ずつ増やしていく場合は 利率 𝑟=0.1、時間t=10 年 のとき: 100×e^r×t =100×𝑒^0.1×10 という式を立てることができます。 ネイピア数の計算ができないシステムでは2.718を使うと近似できます。 Using the number e allows us to...
中間座標を出す場合は 毎フレーム 距離の差を二分の一すれば座標を計算できます。 To find the middle point, just add the two coordinates and split it in...
不具合を見つけるときは、どこまで処理が進んでいるか?確認する必要があります。 スクラッチのこんにちは!と2秒言うはよく使いますね。 When I debug a program,I make sure I know how far it’s gone in the...
大きなソースコードを取り扱うときは、 区切りのいいところをみつけて、分割すると、 考えやすくなります。 When reading a large codebase.it’s helpful to identify its structure and divide it into...