Codename LogoCodename Logo

funkin.editors.charter.Charter

APIWiki

Static variables

static__song:String

View in GitHub

@:value(0)staticautoSaveTimer:Float = 0

staticread onlyinstance:Charter

View in GitHub

@:value(false)staticstartHere:Bool = false

View in GitHub

@:value(0)staticstartTime:Float = 0

Constructor

View in GitHub

@:value({ reload : true })new(song:String, diff:String, reload:Bool = true)

Variables

@:value(0)__endStep:Float = 0

charterCamera:FlxCamera

@:value(new FlxPoint())dragStartPos:FlxPoint = new FlxPoint()

@:value(new CharterEventGroup())eventsGroup:CharterEventGroup = new CharterEventGroup()

@:value(NONE)gridActionType:CharterGridActionType = NONE

NOTE AND CHARTER GRID LOGIC HERE

hitsound:FlxSound

metronome:FlxSound

@:value(new FlxPoint())mousePos:FlxPoint = new FlxPoint()

@:value(0)noteType:Int = 0

@:value([])noteTypes:Array<String> = []

@:value(new CharterNoteGroup())notesGroup:CharterNoteGroup = new CharterNoteGroup()

@:value(16)quant:Int = 16

@:value([])quantButtons:Array<CharterQuantButton> = []

@:value([4, 8, 12, 16, 20, 24, 32, 48, 64, 192])quants:Array<Int> = [4, 8, 12, 16, 20, 24, 32, 48, 64, 192]

@:value(false)selectionDragging:Bool = false

@:value(new CharterStrumLineGroup())strumLines:CharterStrumLineGroup = new CharterStrumLineGroup()

strumlineInfoBG:FlxSprite

uiCamera:FlxCamera

@:value(new FlxTypedGroup&lt;FlxSprite&gt;())uiGroup:FlxTypedGroup<FlxSprite> = new FlxTypedGroup<FlxSprite>()

vocals:FlxSound

Methods

View in GitHub

@:value({ checkSelection : true })inlinechangeNoteType(?newID:Int, checkSelection:Bool = true):Void

View in GitHub

@:value({ addToUndo : true })createSelection(selection:Selection, addToUndo:Bool = true):Array<Unknown>

View in GitHub

@:value({ __createNotes : true, addToUndo : true })createStrumline(strumLineID:Int, strL:ChartStrumLine, addToUndo:Bool = true, __createNotes:Bool = true):Void

View in GitHub

@:value({ addToUndo : true })deleteSelection(selection:Selection, addToUndo:Bool = true):Array<ICharterSelectable>

View in GitHub

@:value({ addToUndo : true })deleteSingleSelection(selected:ICharterSelectable, addToUndo:Bool = true):Null<ICharterSelectable>

View in GitHub

@:value({ addToUndo : true })deleteStrumline(strumLineID:Int, addToUndo:Bool = true):Void

View in GitHub

@:value({ here : false, opponentMode : false, time : 0 })playtestChart(time:Float = 0, opponentMode:Bool = false, here:Bool = false):Void

View in GitHub

quantStep(step:Float):Float

View in GitHub

@:value({ roundRatio : 0.5 })quantStepRounded(step:Float, roundRatio:Float = 0.5):Float

View in GitHub

ratioRound(val:Float, ratio:Float):Int

View in GitHub

updateNoteLogic(elapsed:Float):Void

Inherited Variables

Defined by UIState

@:value(null)buttonHandler:() ‑> Void = null

@:value(null)curContextMenu:UIContextMenu = null

@:value(ARROW)currentCursor:MouseCursor = ARROW

@:value(null)currentFocus:IUIFocusable = null

@:value(null)hoveredSprite:UISprite = null

Defined by MusicBeatState

@:value(false)cancelConductorUpdate:Bool = false

Whenever the Conductor auto update should be enabled or not.

read onlycontrols:Controls

Game Controls. (All players / Solo)

read onlycontrolsP1:Controls

Game Controls (Player 1 only)

read onlycontrolsP2:Controls

Game Controls (Player 2 only)

read onlycurBeat:Int

Current beat

read onlycurBeatFloat:Float

Current beat, as a Float (ex: 1.24, instead of 1)

read onlycurMeasure:Int

Current beat

read onlycurMeasureFloat:Float

Current beat, as a Float (ex: 1.24, instead of 1)

read onlycurStep:Int

Current step

read onlycurStepFloat:Float

Current step, as a Float (ex: 4.94, instead of 4)

@:value(new GraphicCacheSprite())graphicCache:GraphicCacheSprite = new GraphicCacheSprite()

Dummy sprite used to cache graphics to GPU.

@:value(null)scriptName:String = null

@:value(true)scriptsAllowed:Bool = true

read onlysongPos:Float

Current song position (in milliseconds).

stateScripts:ScriptPack

Current injected script attached to the state. To add one, create a file at path "data/states/stateName" (ex: data/states/FreeplayState)

Inherited Methods

Defined by UIState

View in GitHub

isOverlapping(spr:UISprite, rect:FlxRect):Bool

View in GitHub

openContextMenu(options:Array<UIContextMenuOption>, ?callback:Null<UIContextMenuCallback>, ?x:Float, ?y:Float):UIContextMenu

View in GitHub

updateButtonHandler(spr:UISprite, buttonHandler:() ‑> Void):Void

View in GitHub

updateRectButtonHandler(spr:UISprite, rect:FlxRect, buttonHandler:() ‑> Void):Void

Defined by MusicBeatState

View in GitHub

call(name:String, ?args:Array<Dynamic>, ?defaultVal:Dynamic):Dynamic

View in GitHub

event<T>(name:String, event:T):T

View in GitHub

@:value({ fpsSensitive : false })lerp(v1:Float, v2:Float, ratio:Float, fpsSensitive:Bool = false):Float

Shortcut to FlxMath.lerp or CoolUtil.lerp, depending on fpsSensitive

Parameters:

v1

Value 1

v2

Value 2

ratio

Ratio

fpsSensitive

Whenever the ratio should not be adjusted to run at the same speed independent of framerate.

View in GitHub

openSubState(subState:FlxSubState):Void

SCRIPTING STUFF