Unity插件笔记 In-game Debug Console

游戏内控制台

官方文档:A uGUI based console to see debug messages and execute commands during gameplay in Unity

插件自带的指令,输入help可以查询

Available commands:
    - help: Prints all commands
    - help [String commandName]: Prints all matching commands
    - logs.save: Saves logs to persistentDataPath
    - logs.save [String filePath]: Saves logs to the specified file
    - prefs.clear: Deletes all PlayerPrefs fields
    - prefs.delete [String key]: Deletes a PlayerPrefs field
    - prefs.float [String key]: Returns the value of a Float PlayerPrefs field
    - prefs.float [String key] [Float value]: Sets the value of a Float PlayerPrefs field
    - prefs.int [String key]: Returns the value of an Integer PlayerPrefs field
    - prefs.int [String key] [Integer value]: Sets the value of an Integer PlayerPrefs field
    - prefs.string [String key]: Returns the value of a String PlayerPrefs field
    - prefs.string [String key] [String value]: Sets the value of a String PlayerPrefs field
    - scene.load [String sceneName]: Loads a scene
    - scene.load [String sceneName] [LoadSceneMode mode]: Loads a scene
    - scene.loadasync [String sceneName]: Loads a scene asynchronously
    - scene.loadasync [String sceneName] [LoadSceneMode mode]: Loads a scene asynchronously
    - scene.restart: Restarts the active scene
    - scene.unload [String sceneName]: Unloads a scene
    - sysinfo: Prints system information
    - time.scale: Returns the current Time.timeScale value
    - time.scale [Float value]: Sets the Time.timeScale value
 

上述实用的指令有:

- scene.load [String sceneName]: 加载一个场景

- scene.restart: 重启当前的关卡

  - time.scale [Float value]:修改时间速率

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值