123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557 |
- // ParseBinary IDL file
- // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- // !! When adding new pairs to the maps below, !!
- // !! please add to the last position of the map. !!
- // !! It will ensure the reader's version compatible. !!
- // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- namespace flatbuffers;
- table CSParseBinary
- {
- //Make sure the version is the 1st pair in this map!
- //It will make sure Cocos2d-x can parse the version string correctly from csbs in various versions.
- version:string;
-
- textures:[string];
- texturePngs:[string];
- nodeTree:NodeTree;
- action:NodeAction;
- animationList:[AnimationInfo];
- }
- root_type CSParseBinary;
- table NodeTree
- {
- classname:string;
-
- children:[NodeTree];
- options:Options;
- customClassName:string;
- }
- table Options
- {
- data:WidgetOptions;
- }
- table WidgetOptions
- {
- name:string;
- actionTag:int= 0;
- rotationSkew:RotationSkew;
- zOrder:int;
- visible:bool = true;
- alpha:ubyte = 255;
- tag:int = 0;
- position:Position;
- scale:Scale;
- anchorPoint:AnchorPoint;
- color:Color;
- size:FlatSize;
- flipX:bool = false;
- flipY:bool = false;
- ignoreSize:bool = false;
- touchEnabled:bool;
- frameEvent:string;
- customProperty:string;
- callBackType:string;
- callBackName:string;
- layoutComponent:LayoutComponentTable;
- }
- table LayoutComponentTable
- {
- positionXPercentEnabled:bool;
- positionYPercentEnabled:bool;
- positionXPercent:float;
- positionYPercent:float;
- sizeXPercentEnable:bool;
- sizeYPercentEnable:bool;
- sizeXPercent:float;
- sizeYPercent:float;
- stretchHorizontalEnabled:bool;
- stretchVerticalEnabled:bool;
- horizontalEdge:string;
- verticalEdge:string;
- leftMargin:float;
- rightMargin:float;
- topMargin:float;
- bottomMargin:float;
- }
- table SingleNodeOptions
- {
- nodeOptions:WidgetOptions;
- }
- table SpriteOptions
- {
- nodeOptions:WidgetOptions;
- fileNameData:ResourceData;
- blendFunc:BlendFunc;
- }
- table ParticleSystemOptions
- {
- nodeOptions:WidgetOptions;
- fileNameData:ResourceData;
- blendFunc:BlendFunc;
- }
- table GameMapOptions
- {
- nodeOptions:WidgetOptions;
- fileNameData:ResourceData;
- }
- table ButtonOptions
- {
- widgetOptions:WidgetOptions;
- normalData:ResourceData;
- pressedData:ResourceData;
- disabledData:ResourceData;
- fontResource:ResourceData;
- text:string;
- isLocalized:bool = false;
- fontName:string;
- fontSize:int;
- textColor:Color;
- capInsets:CapInsets;
- scale9Size:FlatSize;
- scale9Enabled:bool;
- displaystate:bool = true;
- outlineEnabled:bool = false;
- outlineColor:Color;
- outlineSize:int = 1;
- shadowEnabled:bool = false;
- shadowColor:Color;
- shadowOffsetX:float = 2;
- shadowOffsetY:float = -2;
- shadowBlurRadius:int;
- }
- table CheckBoxOptions
- {
- widgetOptions:WidgetOptions;
- backGroundBoxData:ResourceData;
- backGroundBoxSelectedData:ResourceData;
- frontCrossData:ResourceData;
- backGroundBoxDisabledData:ResourceData;
- frontCrossDisabledData:ResourceData;
- selectedState:bool = true;
- displaystate:bool = true;
- }
- table ImageViewOptions
- {
- widgetOptions:WidgetOptions;
- fileNameData:ResourceData;
- capInsets:CapInsets;
- scale9Size:FlatSize;
- scale9Enabled:bool;
- }
- table TextAtlasOptions
- {
- widgetOptions:WidgetOptions;
- charMapFileData:ResourceData;
- stringValue:string;
- startCharMap:string;
- itemWidth:int;
- itemHeight:int;
- }
- table TextBMFontOptions
- {
- widgetOptions:WidgetOptions;
- fileNameData:ResourceData;
- text:string;
- isLocalized:bool = false;
- }
- table TextOptions
- {
- widgetOptions:WidgetOptions;
- fontResource:ResourceData;
- fontName:string;
- fontSize:int;
- text:string;
- isLocalized:bool = false;
- areaWidth:int;
- areaHeight:int;
- hAlignment:int;
- vAlignment:int;
- touchScaleEnable:bool = false;
- isCustomSize:bool = false;
- outlineEnabled:bool = false;
- outlineColor:Color;
- outlineSize:int = 1;
- shadowEnabled:bool = false;
- shadowColor:Color;
- shadowOffsetX:float = 2;
- shadowOffsetY:float = -2;
- shadowBlurRadius:int;
- }
- table TextFieldOptions
- {
- widgetOptions:WidgetOptions;
- fontResource:ResourceData;
- fontName:string;
- fontSize:int;
- text:string;
- isLocalized:bool = false;
- placeHolder:string;
- passwordEnabled:bool = false;
- passwordStyleText:string;
- maxLengthEnabled:bool = false;
- maxLength:int;
- areaWidth:int;
- areaHeight:int;
- isCustomSize:bool = false;
- }
- table LoadingBarOptions
- {
- widgetOptions:WidgetOptions;
- textureData:ResourceData;
- percent:int = 80;
- direction:int = 0;
- }
- table SliderOptions
- {
- widgetOptions:WidgetOptions;
- barFileNameData:ResourceData;
- ballNormalData:ResourceData;
- ballPressedData:ResourceData;
- ballDisabledData:ResourceData;
- progressBarData:ResourceData;
- percent:int = 50;
- displaystate:bool = true;
- }
- table PanelOptions
- {
- widgetOptions:WidgetOptions;
- backGroundImageData:ResourceData;
- clipEnabled:bool = false;
- bgColor:Color;
- bgStartColor:Color;
- bgEndColor:Color;
- colorType:int = 0;
- bgColorOpacity:ubyte = 255;
- colorVector:ColorVector;
- capInsets:CapInsets;
- scale9Size:FlatSize;
- backGroundScale9Enabled:bool = false;
- }
- table ScrollViewOptions
- {
- widgetOptions:WidgetOptions;
- backGroundImageData:ResourceData;
- clipEnabled:bool = false;
- bgColor:Color;
- bgStartColor:Color;
- bgEndColor:Color;
- colorType:int = 0;
- bgColorOpacity:ubyte = 255;
- colorVector:ColorVector;
- capInsets:CapInsets;
- scale9Size:FlatSize;
- backGroundScale9Enabled:bool = false;
- innerSize:FlatSize;
- direction:int;
- bounceEnabled:bool = false;
- scrollbarEnabeld:bool = true;
- scrollbarAutoHide:bool = true;
- scrollbarAutoHideTime:float = 0.2;
- }
- table PageViewOptions
- {
- widgetOptions:WidgetOptions;
- backGroundImageData:ResourceData;
- clipEnabled:bool = false;
- bgColor:Color;
- bgStartColor:Color;
- bgEndColor:Color;
- colorType:int = 0;
- bgColorOpacity:ubyte = 255;
- colorVector:ColorVector;
- capInsets:CapInsets;
- scale9Size:FlatSize;
- backGroundScale9Enabled:bool = false;
- }
- table ListViewOptions
- {
- widgetOptions:WidgetOptions;
- backGroundImageData:ResourceData;
- clipEnabled:bool = false;
- bgColor:Color;
- bgStartColor:Color;
- bgEndColor:Color;
- colorType:int = 0;
- bgColorOpacity:ubyte = 255;
- colorVector:ColorVector;
- capInsets:CapInsets;
- scale9Size:FlatSize;
- backGroundScale9Enabled:bool = false;
- innerSize:FlatSize;
- direction:int;
- bounceEnabled:bool = false;
- itemMargin:int = 0;
- directionType:string;
- horizontalType:string;
- verticalType:string;
- }
- table ProjectNodeOptions
- {
- nodeOptions:WidgetOptions;
- fileName:string;
- innerActionSpeed:float;
- }
- table ComponentOptions
- {
- nodeOptions:WidgetOptions;
- type:string;
- comAudioOptions:ComAudioOptions;
- }
- table ComAudioOptions
- {
- nodeOptions:WidgetOptions;
- name:string;
- enabled:bool;
- loop:bool;
- volume:int;
- fileNameData:ResourceData;
- }
- table AnimationInfo
- {
- name:string;
- startIndex:int;
- endIndex:int;
- }
- table NodeAction
- {
- duration:int;
- speed:float;
- timeLines:[TimeLine];
- currentAnimationName:string;
- }
- table TimeLine
- {
- property:string;
- actionTag:int;
- frames:[Frame];
- }
- table Frame
- {
- pointFrame:PointFrame;
- scaleFrame:ScaleFrame;
- colorFrame:ColorFrame;
- textureFrame:TextureFrame;
- eventFrame:EventFrame;
- intFrame:IntFrame;
- boolFrame:BoolFrame;
- innerActionFrame:InnerActionFrame;
- blendFrame:BlendFrame;
- }
- // PointFrame
- table PointFrame
- {
- frameIndex:int;
- tween:bool = true;
- position:Position;
- easingData:EasingData;
- }
- // ScaleFrame
- table ScaleFrame
- {
- frameIndex:int;
- tween:bool = true;
- scale:Scale;
- easingData:EasingData;
- }
- // ColorFrame
- table ColorFrame
- {
- frameIndex:int;
- tween:bool = true;
- color:Color;
- easingData:EasingData;
- }
- // TextureFrame
- table TextureFrame
- {
- frameIndex:int;
- tween:bool = true;
- textureFile:ResourceData;
- easingData:EasingData;
- }
- // EventFrame
- table EventFrame
- {
- frameIndex:int;
- tween:bool = true;
- value:string;
- easingData:EasingData;
- }
- // IntFrame
- table IntFrame
- {
- frameIndex:int;
- tween:bool = true;
- value:int;
- easingData:EasingData;
- }
- // BoolFrame
- table BoolFrame
- {
- frameIndex:int;
- tween:bool = true;
- value:bool = true;
- easingData:EasingData;
- }
- // InnerActionFrame
- table InnerActionFrame
- {
- frameIndex:int;
- tween:bool = true;
- innerActionType:int;
- currentAniamtionName:string;
- singleFrameIndex:int;
- easingData:EasingData;
- }
- // EasingData
- table EasingData
- {
- type:int = -1;
- points:[Position];
- }
- struct RotationSkew
- {
- rotationSkewX:float;
- rotationSkewY:float;
- }
- struct Position
- {
- x:float;
- y:float;
- }
- struct Scale
- {
- scaleX:float;
- scaleY:float;
- }
- struct AnchorPoint
- {
- scaleX:float;
- scaleY:float;
- }
- struct Color
- {
- a:ubyte;
- r:ubyte;
- g:ubyte;
- b:ubyte;
- }
- struct ColorVector
- {
- vectorX:float;
- vectorY:float;
- }
- struct FlatSize
- {
- width:float;
- height:float;
- }
- struct CapInsets
- {
- x:float;
- y:float;
- width:float;
- height:float;
- }
- struct BlendFunc
- {
- src:int;
- dst:int;
- }
- table ResourceData
- {
- path:string;
- plistFile:string;
- resourceType:int;
- }
- // BlendFrame
- table BlendFrame
- {
- frameIndex:int;
- tween:bool = true;
- blendFunc:BlendFunc;
- easingData:EasingData;
- }
|