slightly bigger scriptable hit window
This commit is contained in:
@@ -403,6 +403,12 @@ class PlayState extends MusicBeatState
|
||||
*/
|
||||
public var noteTypesArray:Array<String> = [null];
|
||||
|
||||
/**
|
||||
* Hit window, in milliseconds. Defaults to 250ms unless changed in options.
|
||||
* Base game hit window is 175ms.
|
||||
*/
|
||||
public var hitWindow:Float = Options.hitWindow; // is calculated in create(), is safeFrames in milliseconds
|
||||
|
||||
@:dox(hide)
|
||||
var __vocalOffsetViolation:Float = 0;
|
||||
|
||||
@@ -1265,10 +1271,10 @@ class PlayState extends MusicBeatState
|
||||
if (event.__updateHitWindow) {
|
||||
if (daNote.mustPress)
|
||||
{
|
||||
daNote.canBeHit = (daNote.strumTime > Conductor.songPosition - (Conductor.safeZoneOffset * daNote.latePressWindow)
|
||||
&& daNote.strumTime < Conductor.songPosition + (Conductor.safeZoneOffset * daNote.earlyPressWindow));
|
||||
daNote.canBeHit = (daNote.strumTime > Conductor.songPosition - (hitWindow * daNote.latePressWindow)
|
||||
&& daNote.strumTime < Conductor.songPosition + (hitWindow * daNote.earlyPressWindow));
|
||||
|
||||
if (daNote.strumTime < Conductor.songPosition - Conductor.safeZoneOffset && !daNote.wasGoodHit)
|
||||
if (daNote.strumTime < Conductor.songPosition - hitWindow && !daNote.wasGoodHit)
|
||||
daNote.tooLate = true;
|
||||
}
|
||||
else
|
||||
@@ -1500,19 +1506,19 @@ class PlayState extends MusicBeatState
|
||||
var score:Int = 300;
|
||||
var accuracy:Float = 1;
|
||||
|
||||
if (noteDiff > Conductor.safeZoneOffset * 0.9)
|
||||
if (noteDiff > hitWindow * 0.9)
|
||||
{
|
||||
daRating = 'shit';
|
||||
score = 50;
|
||||
accuracy = 0.25;
|
||||
}
|
||||
else if (noteDiff > Conductor.safeZoneOffset * 0.75)
|
||||
else if (noteDiff > hitWindow * 0.75)
|
||||
{
|
||||
daRating = 'bad';
|
||||
score = 100;
|
||||
accuracy = 0.45;
|
||||
}
|
||||
else if (noteDiff > Conductor.safeZoneOffset * 0.2)
|
||||
else if (noteDiff > hitWindow * 0.2)
|
||||
{
|
||||
daRating = 'good';
|
||||
score = 200;
|
||||
|
||||
@@ -24,6 +24,7 @@ class Options
|
||||
public static var volume:Float = 1;
|
||||
public static var week6PixelPerfect:Bool = true;
|
||||
public static var betaUpdates:Bool = false;
|
||||
public static var hitWindow:Float = 250;
|
||||
|
||||
/**
|
||||
* PLAYER 1 CONTROLS
|
||||
@@ -58,7 +59,7 @@ class Options
|
||||
public static var P2_RESET:Array<FlxKey> = [];
|
||||
|
||||
/**
|
||||
* SOLO GETTERS & SETTERS
|
||||
* SOLO GETTERS
|
||||
*/
|
||||
public static var SOLO_NOTE_LEFT(get, null):Array<FlxKey>;
|
||||
public static var SOLO_NOTE_DOWN(get, null):Array<FlxKey>;
|
||||
|
||||
@@ -53,7 +53,10 @@ class HScript extends Script {
|
||||
}
|
||||
|
||||
public override function onLoad() {
|
||||
if (expr != null) interp.execute(expr);
|
||||
if (expr != null) {
|
||||
interp.execute(expr);
|
||||
call("new", []);
|
||||
}
|
||||
}
|
||||
|
||||
public override function reload() {
|
||||
|
||||
@@ -79,8 +79,6 @@ class Conductor
|
||||
@:dox(hide) public static var destSpeed:Float = 0;
|
||||
@:dox(hide) public static var offset:Float = 0;
|
||||
|
||||
@:dox(hide) public static var safeZoneOffset:Float = 175; // is calculated in create(), is safeFrames in milliseconds
|
||||
|
||||
/**
|
||||
* Array of all BPM changes that have been mapped.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user