やまめも

【 ゲーム開発・日々のことについて 】

【C#】const 定数 使用例

ufcpp.net

// Game TAGS
public const string GroundTag = "ground";
public const string ObstacleTag = "obstacle";
public const string PortalTag = "portal";
public const string ObstacleParentTag = "obstacleParent";
public const string PortalParentTag = "portalParent";
public const string PortalArrowParentTag = "portalArrowParent";
public const string SlitTag = "slit";

// game variables
private const float spawnDelay = 2f;
private const float initialDelay = 1;
private float spawnTimerCounter = 0f;
private const int spawnPos = 600;