编程
Fundamentals
Setting Up Development Environment
UnigineScript
High-Level Systems
C++
C#
UUSL (Unified UNIGINE Shader Language)
File Formats
Rebuilding the Engine and Tools
GUI
Double Precision Coordinates
应用程序接口
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Math Functionality
Node-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
Rendering-Related Classes

Break语句

break终结当前迭代中forforloopforeachforeachkeywhiledo-while 循环语句的执行。也可终结switch-case模块。继续执行循环中的第一行代码或者switch-case模块的第一行代码。

语法

源代码 (UnigineScript)
break;

示例

源代码 (UnigineScript)
for(int i = 0; i < 10; i++) {
	if(i == 3) break;
		log.message("%d ",i);
}

// 此示例的输出结果为: 0 1 2
最新更新: 2017-07-03