Storyboarding by Scripting
In the .osu file, under [Events]:
Note: underscores can be replaced with spaces.
(代码部分的)下划线表示空格
Sprites and Animations
The size of the active playfield is 640 pixels wide by 480 pixels high. For static background images/effects, it is best to limit images to these dimensions.
活动区域大小为宽度640p高度480p,对于静态背景图像/效果,最好将图像限制在本尺寸内。
Static Sprite:
静态精灵:
Sprite,"layer","origin","filepath",x,y
_event, easing, starttime, endtime, [params]
_event, [...]
_event, [...]
Animation:
动画:
Animation,"layer","origin","filepath",x,y,frameCount,frameDelay,looptype
_event,easing,starttime,endtime,[params]
_event, [...]
_event, [...]
For animations, specify a filename like "sliderball.png", and name your files "sliderball0.png" to "sliderball9.png" for a 10 frame animation.
对于动画,可以指定文件名类似"sliderball.png",给文件名起名"sliderball0.png"至"sliderball9.png"用于显示10帧的动画。
frameCount: number of frames in the animation
动画中帧的个数
frameDelay: delay in milliseconds between each frame.
每帧之间的毫秒延迟
looptype: LoopForever by default
默认无限重复
LoopForever - Loops over and over again
无限次的重复
LoopOnce - Loops once and stops on last frame.
重复一次并停止在最后一帧
Z-order (back to front) is determined by the order the files appear in the .osu file.
z轴顺序(从后至前)定义了出现的资源文件顺序
The first storyboard event will be behind everything else, ie.
第一个故事板event会处于最后的位置
if storyboard event 'A' is above storyboard event 'B', 'B' will be on top of 'A'.
如果故事板事件'A'在故事板事件'B'之前,'B' 会在 'A' 上方显示。
layer(层):
Background 背景
Fail 失败
Pass 通过
Foreground 前景
Note: Background and Foreground are always visible.
注意:背景和前景总是可见。
origin(原点):
TopLeft
TopCentre
TopRight
CentreLeft
Centre
CentreRight
BottomLeft
BottomCentre
BottomRight
All Rotations and Size changes (Including Vector Scaling) are affected by origin.
所有的旋转和大小的变化(包括矢量缩放)都受原点位置影响。
filepath: relative path of the image file (should be in the same directory as the .osu file)
文件路径:图像文件的相对路径(应与 .osu 文件同目录)
Note: file path must be in double quotes if it has spaces in the filename
注:文件路径中如果含有空格,必须置于双引号中
x, y: the position of the image
x,y:图像位置
Note: (0,0) is the top left corner while (640,480) is the bottom right corner.
注:(0,0)是左上角,而(640,480)是右下角。
For each of the event types below, the initial value(s) of that event will assume the first assignment given to that event.
对于下方的每一个事件类型,指定了该事件的初始值。
event type(事件类型):
F - fade (淡入淡出)
M - move (位移)
S - scale (缩放)
V - vector scale (width and height separately) (拉伸缩放,可分别指定高宽)
R - rotate (旋转)
C - colour (上色)
L - loop (循环)
T - Event-triggered loop (事件触发循环)
P - Parameters (参数)
easing(缓动):
0 - none (无)
1 - start fast and slow down (由快至慢)
2 - start slow and speed up (由慢至快)
starttime, endtime:
the times in milliseconds between which the event will be animated
该事件执行动画的时间
params(参数):
_F,[...],startopacity,endopacity
startopacity: the opacity at the beginning of the animation
开始透明度:动画开始时的透明度
endopacity: the opacity at the end of the animation
结束透明度:动画结束时的透明度
0 - invisible, 1 - fully visible
0 - 不可见, 1 - 完全可见
_M,[...],startx,starty,endx,endy
startx, starty: the position at the beginning of the animation
startx, starty: 动画开始位置
endx, endy: the position at the end of the animation
endx, endy: 动画结束位置
Note: the size of the play field is (640,480), with (0,0) being top left corner.
注:活动区域为(640,480),左上角位置为(0,0)
_S,[...],startscale,endscale
startscale: the scale factor at the beginning of the animation
开始比例:动画开始时的缩放比例因子
endscale: the scale factor at the end of the animation
结束比例:动画结束时的缩放比例因子
1 = 100%, 2 = 200% etc. decimals are allowed.
1 = 100%, 2 = 200%。允许小数值
_V,[...],startx,starty,endx,endy
startx, starty: the scale factor at the beginning of the animation
startx, starty: 动画开始时的缩放比例因子
endx, endy: the scale factor at the end of the animation
endx, endy: 动画结束时的缩放比例因子
1 = 100%, 2 = 200% etc. decimals are allowed.
1 = 100%, 2 = 200%。允许小数值
_R,[...],startangle,endangle
startangle: the angle to rotate by in radians at the beginning of the animation
开始弧度:动画开始时的旋转弧度值
endangle: the angle to rotate by in radians at the end of the animation
结束弧度:动画结束时的旋转弧度值
positive angle is clockwise rotation
正数表示顺时针旋转
_C,[...],r1,g1,b1,r2,g2,b2
r1, g1, b1: the starting component-wise colour
r1, g1, b1: 动画开始时的颜色分量
r2, g2, b2: the finishing component-wise colour
r2, g2, b2: 动画结束时的颜色分量
sprites with (255,255,255) will be their original colour. sprites with (0,0,0) will be totally black. anywhere in between will result in subtractive colouring. to make full use of this, brighter greyscale sprites work very well.
值(255,255,255)表示精灵本身颜色,值(0,0,0)表示精灵全黑。其他处于两者之间的值,都会产生染色效果。灰度精灵可以产生很棒的效果
_MX,[...],startx,endx
startx: the x position at the beginning of the animation
动画开始时的x坐标
endx: the x position at the end of the animation
动画结束时的x坐标
_MY,[...],starty,endy
starty: the y position at the beginning of the animation
动画开始时的y坐标
endy: the y position at the end of the animation
动画结束时的y坐标
_P,[...],p
p: the effect parameter to apply
要应用的效果
H - horizontal flip
水平翻转
V - vertical flip
垂直翻转
A - additive-blend colour (as opposed to alpha-blend)
添加混合色(非alpha混合)
using the shorthand below with parameters is possible. the applied parameters will take effect during the duration specified only.
也可以使用下方参数的速记,所设的参数将在指定的时间内生效
shorthand(速记):
This notation can be used to quickly script a large number of the same kind of event over the same time span.
这种写法可以用来快速脚本大量的同一类型的事件在同一时间跨度。
_event,easing,starttime,endtime,val1,val2,val3,...,valN
等同于事件:
_event,easing,starttime,endtime,val1,val2
_event,easing,starttime + duration,endtime + duration,val2,val3
_event,easing,starttime + 2duration,endtime + 2duration,val3,val4
shorthand2(速记2):
This notation can be used when the start and end time of the event is the same.
这种写法可以用于事件的开始和结束时间相同的情况
_M,0,1000,1000,320,240,320,240
可写为:
_M,0,1000,,320,240,320,240
Please note the blank space in the endtime field - this is required.
请注意结束时间位置为空值,这是必须的
shorthand3(速记3):
This notation can be used when the start and end values of the event are the same.
这种写法可以用于事件的开始和结束值相同的情况
_M,0,1000,,320,240,320,240
可写为:
_M,0,1000,,320,240
Looping
Standard Loops(简单循环):
Loops can be defined to repeat a set of events constantly for a set number of iterations.
循环可以看作是在一组指定次数的迭代中不断重复一组事件。
_L,starttime,loopcount
__event, [...]
__event, [...]
starttime: the time of the first loop's start.
开始时间:第一次循环的开始时间
loopcount: number of times to repeat the loop.
循环量:重复循环的次数
Note that events inside a loop should be timed with a zero-base. This means that you should start from 0ms for the inner event's timing and work up from there. The loop event's start time will be added to this value at game runtime.
要注意循环内的事件时间要以0为基准。就是说要以 0毫秒 作为事件的开始时间并执行后续工作,循环事件的开始时间会自行与游戏运行时叠加。
Trigger Loops(触发循环):
Trigger loops can be used to trigger animations based on play-time events. Although called loops, trigger loops only execute once when triggered.
触发循环可以用来触发基于播放时间事件的动画。虽然被称为循环,但触发循环当触发时只执行一次。
_T,triggerName,start,end
__event, [...]
__event, [...]
start: When the trigger is valid
触发器可用开始时间
end : When the trigger stops being valid
触发器可用结束时间
Current triggers supported are:
当前触发器支持:
HitSoundClap (拍掌效果音)
HitSoundFinish (结束效果音)
HitSoundWhistle (哨子效果音)
Passing (transition from fail state to pass state)
通过(将失败状态变为通过状态)
Failing (transition from pass state to fail state)
失败(将通过状态变为失败状态)
Trigger loops are zero-based similar to normal loops. If two overlap, the first will be halted and replaced by a new loop from the beginning.
If they overlap any existing storyboarded events, they will not trigger until those transformations are no in effect.
触发循环内的事件时间要以0为基准,和简单循环类似。如果有重叠的情况,前一个循环将停止,后一个循环开始执行并覆盖。如果出现与现有故事板事件重叠的情况,将不会触发到这些变化不会有什么影响。
Sound effects
Sample,time,layer,"filepath",volume
time: the time in milliseconds to start playing the sound effect
声音效果的开始时间(毫秒)
layer:
Background = 0
Fail = 1
Pass = 2
Foreground = 3
filepath: relative path of the sound file (should be in the same directory as the .osu file)
声音文件的相对路径(应与 .osu 文件同目录)
Note: file path must be in double quotes
注:文件路径必须位于双引号之内
volume: volume of the sound file. (1-100) Can be left off for 100.
声音文件的音量(1-100)。值100可省略(不确定是这个翻译,请注意)
Variables
Primitive support for variables is now available. You can define any number of variables by includin a [Variables] section in the .osb file (currently not supported in .osu-specific storyboarding).
当前支持简单的变量定义。你可以在 .osb 文件中添加一个 [Variables] 部分,定义任意数量的变量。(当前还不支持 .osu 内嵌故事板)
[Variables]
$white=255,255,255
Once you define variables, you can use them *anywhere* in the storyboard. This means you can have a variable containing as much as a whole line.
一旦定义了变量,在故事板内就可以任意位置使用。也就是说你可以把任意一整行的值定义为变量。
Please don't make variable too small for the moment (ie. don't assign $var=1) because the editor is not smart enough to know where to put variables when it saves. All occurrences of the variables will currently be replaced at save time (so if you have one place you used $white and another you used 255,255,255 they will both become $white after a save in the editor).
暂时先不要把变量的值定义的过小(如,指定 $var=1)。因为编辑器还不足够智能的去了解到,当保存时要往何处存放值。在保存时所有变量都将会被替换(就比方说有一个位置你用的是 $white 另一个位置你用的是 255,255,255 那么在编辑器保存时他俩都会变成 $white)。
Storyboarding by Scripting的更多相关文章
- 《DOM Scripting》 - 阅读笔记
DOM Scripting - Web Design with JavaScript and the Document Object Model,Jeremy Keith中文名:JavaScript ...
- JS、ActiveXObject、Scripting.FileSystemObject
Javascript之文件操作 (IE) 一.功能实现核心:FileSystemObject 对象 要在javascript中实现文件操作功能,主要就是依靠FileSystemobject对 ...
- new ActiveXObject("Scripting.FileSystemObject") 时抛出异常 .
使用JScript读写本地文件时,会使用Scripting.FileSystemObject控件. IE默认是不允许运行这类“未标记为安全执行脚本的ActiveX控件”的. 因此执行下行代码时: fs ...
- 推薦使用 Microsoft Anti-Cross Site Scripting Library V3.0
原文出至: http://blog.miniasp.com/post/2009/07/29/Recommand-Microsoft-Anti-Cross-Site-Scripting-Library- ...
- 推薦使用 Microsoft Anti-Cross Site Scripting Library v3.1
原文链接:http://blog.miniasp.com/post/2009/09/27/Recommand-Microsoft-Anti-XSS-Library-V31.aspx 雖然我之前已經寫過 ...
- How to Prevent Cross-Site Scripting Attacks
How to Prevent Cross-Site Scripting Attacks Reference From: http://resources.infosecinstitute.com/ho ...
- XSS (Cross Site Scripting) Prevention Cheat Sheet(XSS防护检查单)
本文是 XSS防御检查单的翻译版本 https://www.owasp.org/index.php/XSS_%28Cross_Site_Scripting%29_Prevention_Cheat_Sh ...
- Cross-Site Scripting(XSS)的类型
本文源自: https://www.owasp.org/index.php/Types_of_Cross-Site_Scripting 在原文理解上翻译为中文. 背景 本文描述多种不同类型的XSS攻击 ...
- Cross-site Scripting (XSS) 阅读笔记
本文源自 https://www.owasp.org/index.php/Cross-site_Scripting_%28XSS%29 通过阅读和翻译,并按照自己的理解,整理成如下文档. 概述 XSS ...
随机推荐
- SVN There are unfinished transactions detected
在ECLIPSE中报这个错,不能提交和更新代码和clean up 解决办法:关闭ECLIPSE,使用工具对SVN执行 clean up. 重新启动ECLIPSE,解决冲突文件,可以正常使用SVN
- 洛谷 P4705 玩游戏
题目分析 题目要求的是: \[ \sum_{i=1}^n\sum_{j=1}^m(a_i+b_j)^x(x\in [1,T]) \] 利用二项式定理化式子, \[ \begin{aligned} &a ...
- 协议森林08 不放弃 (TCP协议与流通信)
作者:Vamei 出处:http://www.cnblogs.com/vamei 欢迎转载,也请保留这段声明.谢谢! TCP(Transportation Control Protocol)协议与IP ...
- ARM汇编之MOV指令
http://blog.csdn.net/lsywk/article/details/8799837 一.指令格式 MOV{条件}{S} 目的寄存器,源操作数 二.指令详解 MOV指令可完成从另一个 ...
- Odoo字段类型
转载请注明原文地址:https://www.cnblogs.com/cnodoo/p/9278620.html 一:基本字段类型 Binary:二进制类型,用于保存图片.视频.文件.附件等,在视 ...
- 基于 Docker 搭建 MySQL 主从复制
本篇博文相对简单,因为是初次使用Docker,MySQL的主从复制之前也在Centos环境下搭建过,但是也忘的也差不多了,因此本次尝试在Docker中搭建. 根据网上教程走还是踩了一些坑,不过所幸最终 ...
- Dubbo实践(十三)Export
Spring在启动Dubbo服务端应用时,会实例化ServiceBean<T>并设置配置属性,然后调用export方法: @SuppressWarnings({"unchecke ...
- python sorted() count() set(list)-去重 -- search + match
2.用python实现统计一篇英文文章内每个单词的出现频率,并返回出现频率最高的前10个单词及其出现次数,并解答以下问题?(标点符号可忽略) (1) 创建文件对象f后,解释f的readlines和xr ...
- Linux---关闭Elasticsearch进程,并重新启动
有时候,当我们启动elasticsearch之后, 经过很长一段时间没有操作, 自己已经忘了是否已经启动了elasticsearch, 这时候我们可以通过下面的方式验证是否启动,并重新启动: step ...
- flashback query闪回数据
误删除了部分重要数据,已提交,需要恢复.首先尝试flashback query闪回数据. 数据库运行在归档模式,首先确认数据库的SCN的变化: SQL> col fscn for 9999999 ...