آموزش نورپردازی یونیتی ایران
154 subscribers
2.64K photos
442 videos
143 files
192 links
در این کانال نمونه کارهای آقای زنجیران قرار میگیرد
Download Telegram
Media is too big
VIEW IN TELEGRAM
نتیجه کار بر روی اسلحه امروز
❤3
using UnityEngine;

public class HeadBobController : MonoBehaviour
{
// Adjust these values in the Inspector to fine-tune the effect
public float amplitude = 0.01f; // The height of the bob
public float frequency = 10.0f; // The speed of the bob
public Transform cameraHolder; // Reference to the CameraHolder GameObject

private Vector3 startPosition;

void Start()
{
// Record the camera's original local position
startPosition = cameraHolder.localPosition;
}

void Update()
{
if (Input.GetAxis("Vertical") != 0)
{
// Use a sine wave to create a smooth, looping bobbing motion
float bobbingAmount = Mathf.Sin(Time.time * frequency) * amplitude;
// Apply the bobbing only to the Y axis (up and down)
cameraHolder.localPosition = startPosition + new Vector3(0, bobbingAmount, 0);
}
else
{
// If not moving, smoothly return the camera to its starting position
cameraHolder.localPosition = Vector3.Lerp(cameraHolder.localPosition, startPosition, Time.deltaTime * frequency);
}
}
}
❤2
آموزش نورپردازی یونیتی ایران
using UnityEngine; public class HeadBobController : MonoBehaviour { // Adjust these values in the Inspector to fine-tune the effect public float amplitude = 0.01f; // The height of the bob public float frequency = 10.0f; // The speed of the bob…
حرکت دوربین (سر کارکتر) با حرکت
HeadBobController
بالا و پایین میشه دوربین... مثلا قدم زدن رو شبیه سازی میکنه

مقدار cameraHolder رو باید پرنت دوربین رو بدید
❤3
using UnityEngine;

namespace NewTechnology
{
public class WeaponSway : MonoBehaviour
{
[Header("Sway Settings")]
[HideInInspector] public float smooth = 7f;
[HideInInspector] public float intensity = 1f;

[HideInInspector] public float mouseX;
[HideInInspector] public float mouseY;

public void Update_MouseInput(float x, float y)
{
mouseX = x * intensity;
mouseY = y * intensity / 2;
}

void Update()
{

// calculate target rotation
Quaternion rotationX = Quaternion.AngleAxis(-mouseY, Vector3.right);
Quaternion rotationY = Quaternion.AngleAxis(mouseX, Vector3.up);

Quaternion targetRotation = rotationX * rotationY;

// rotate
transform.localRotation = Quaternion.Slerp(transform.localRotation, targetRotation, smooth * Time.deltaTime);
}
}
}
❤1
آموزش نورپردازی یونیتی ایران
using UnityEngine; namespace NewTechnology { public class WeaponSway : MonoBehaviour { [Header("Sway Settings")] [HideInInspector] public float smooth = 7f; [HideInInspector] public float intensity = 1f; [HideInInspector]…
اینم با چرخش دوربین اسلحه نرم دنبال میکنه دوربین رو بر اساس مقدار MouseX و MouseY باید بهش پاس بدید
این اسکریپت رو بدید به مدل اسلحه

بهش WeaponSway میگن
❤4
این گزینه رو برای هر پروژه جدیدی که ایجاد کردید بزنید
جرینگی وارد Play Mode میشه
از قدیم اینجور بود چند ساله گزاشتن خیلی رو اعصابه

هیچ مشکلی نمی خورید یساله رو این ده تا بازی ساختم شاید بیشتر
❤4
دشمن جدید قراره بیاد...
🔥2
FPS_3.apk
183.4 MB
تستش کنید رو قوشی ها تون گیم پلی رو
صداگزاری نشده هنوز
👍1
ساخت تکسچر:
https://gemini.google.com/

دستور:
highway 3 lines road texture flat top down view
👍1
This media is not supported in your browser
VIEW IN TELEGRAM
آموزش ترکیب اسکای باکس با مه صحنه

افق نامحدود بسازید

#علی_زنجیران

#آموزش
❤3
https://gemini.google.com/app

mud wet ground texture flat top down view with orthographic camera view
❤2
آموزش نورپردازی یونیتی ایران
https://gemini.google.com/app mud wet ground texture flat top down view with orthographic camera view
قسمت وسط که نورش یک دسته برش بزنید ببرید این سایت Seamless کنید حاشیه یکدست بشه برای زمین یونیتی:

https://www.imgonline.com.ua/eng/make-seamless-texture.php
❤2