Unity client features: - WebSocket connection via NativeWebSocket - 2.5D agent visuals with programmatic placeholder sprites - Billboard system for sprites and UI elements - Floating UI panels (name, HP, energy bars) - Speech bubble system with pop-in animation - RTS-style camera controller (WASD + scroll zoom) - Editor tools for prefab creation and scene setup Scripts: - NetworkManager: WebSocket singleton - GameManager: Agent spawning and event handling - AgentVisual: 2.5D sprite and UI creation - Billboard: Camera-facing behavior - SpeechBubble: Animated dialogue display - CameraController: RTS camera with UI input detection - UIManager: HUD and command input 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
36 lines
1.1 KiB
C#
Executable File
36 lines
1.1 KiB
C#
Executable File
using UnityEngine;
|
|
using System.Collections;
|
|
using TMPro;
|
|
|
|
public class EnvMapAnimator : MonoBehaviour {
|
|
|
|
//private Vector3 TranslationSpeeds;
|
|
public Vector3 RotationSpeeds;
|
|
private TMP_Text m_textMeshPro;
|
|
private Material m_material;
|
|
|
|
|
|
void Awake()
|
|
{
|
|
//Debug.Log("Awake() on Script called.");
|
|
m_textMeshPro = GetComponent<TMP_Text>();
|
|
m_material = m_textMeshPro.fontSharedMaterial;
|
|
}
|
|
|
|
// Use this for initialization
|
|
IEnumerator Start ()
|
|
{
|
|
Matrix4x4 matrix = new Matrix4x4();
|
|
|
|
while (true)
|
|
{
|
|
//matrix.SetTRS(new Vector3 (Time.time * TranslationSpeeds.x, Time.time * TranslationSpeeds.y, Time.time * TranslationSpeeds.z), Quaternion.Euler(Time.time * RotationSpeeds.x, Time.time * RotationSpeeds.y , Time.time * RotationSpeeds.z), Vector3.one);
|
|
matrix.SetTRS(Vector3.zero, Quaternion.Euler(Time.time * RotationSpeeds.x, Time.time * RotationSpeeds.y , Time.time * RotationSpeeds.z), Vector3.one);
|
|
|
|
m_material.SetMatrix("_EnvMatrix", matrix);
|
|
|
|
yield return null;
|
|
}
|
|
}
|
|
}
|