follows latest dlang changes
This commit is contained in:
parent
c2a4e4af97
commit
a18c020652
@ -3,7 +3,8 @@ module sjscript.Token;
|
|||||||
|
|
||||||
import std.algorithm,
|
import std.algorithm,
|
||||||
std.array,
|
std.array,
|
||||||
std.ascii;
|
std.ascii,
|
||||||
|
std.conv;
|
||||||
|
|
||||||
import dast.tokenize;
|
import dast.tokenize;
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@ import std.algorithm,
|
|||||||
|
|
||||||
import gl4d;
|
import gl4d;
|
||||||
|
|
||||||
static import sjplayer;
|
import sjplayer;
|
||||||
|
|
||||||
import sj.AbstractGame,
|
import sj.AbstractGame,
|
||||||
sj.Args,
|
sj.Args,
|
||||||
@ -38,10 +38,10 @@ class Game : AbstractGame {
|
|||||||
// To prevent working GC, all objects should be created at here.
|
// To prevent working GC, all objects should be created at here.
|
||||||
|
|
||||||
fonts_ = new FontSet;
|
fonts_ = new FontSet;
|
||||||
programs_ = new ProgramSet;
|
programs_ = new sj.ProgramSet.ProgramSet;
|
||||||
|
|
||||||
posteffect_ = new sjplayer.PostEffect(
|
posteffect_ = new PostEffect(
|
||||||
programs_.Get!(sjplayer.PostEffectProgram),
|
programs_.Get!PostEffectProgram,
|
||||||
vec2i(args.window_size, args.window_size));
|
vec2i(args.window_size, args.window_size));
|
||||||
|
|
||||||
lobby_ = new LobbyWorld(programs_);
|
lobby_ = new LobbyWorld(programs_);
|
||||||
@ -108,11 +108,11 @@ class Game : AbstractGame {
|
|||||||
private:
|
private:
|
||||||
Music[] music_list_;
|
Music[] music_list_;
|
||||||
|
|
||||||
FontSet fonts_;
|
FontSet fonts_;
|
||||||
ProgramSet programs_;
|
sj.ProgramSet.ProgramSet programs_;
|
||||||
|
|
||||||
sjplayer.PostEffect posteffect_;
|
PostEffect posteffect_;
|
||||||
LobbyWorld lobby_;
|
LobbyWorld lobby_;
|
||||||
|
|
||||||
TitleScene title_;
|
TitleScene title_;
|
||||||
SelectScene select_;
|
SelectScene select_;
|
||||||
|
@ -8,7 +8,7 @@ import std.math,
|
|||||||
|
|
||||||
import gl4d;
|
import gl4d;
|
||||||
|
|
||||||
static import sjplayer;
|
import sjplayer;
|
||||||
|
|
||||||
import sj.FontSet,
|
import sj.FontSet,
|
||||||
sj.KeyInput,
|
sj.KeyInput,
|
||||||
@ -40,10 +40,10 @@ class LoadingScene : SceneInterface {
|
|||||||
|
|
||||||
///
|
///
|
||||||
this(
|
this(
|
||||||
LobbyWorld lobby,
|
LobbyWorld lobby,
|
||||||
sjplayer.PostEffect posteffect,
|
PostEffect posteffect,
|
||||||
ProgramSet programs,
|
sj.ProgramSet.ProgramSet programs,
|
||||||
FontSet fonts) {
|
FontSet fonts) {
|
||||||
lobby_ = lobby;
|
lobby_ = lobby;
|
||||||
posteffect_ = posteffect;
|
posteffect_ = posteffect;
|
||||||
programs_ = programs;
|
programs_ = programs;
|
||||||
@ -110,9 +110,9 @@ class LoadingScene : SceneInterface {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
sjplayer.PostEffect posteffect_;
|
PostEffect posteffect_;
|
||||||
|
|
||||||
ProgramSet programs_;
|
sj.ProgramSet.ProgramSet programs_;
|
||||||
|
|
||||||
LobbyWorld lobby_;
|
LobbyWorld lobby_;
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ import derelict.sfml2.audio,
|
|||||||
|
|
||||||
import gl4d;
|
import gl4d;
|
||||||
|
|
||||||
static import sjplayer;
|
import sjplayer;
|
||||||
|
|
||||||
///
|
///
|
||||||
class Music {
|
class Music {
|
||||||
@ -82,9 +82,8 @@ class Music {
|
|||||||
}
|
}
|
||||||
|
|
||||||
///
|
///
|
||||||
sjplayer.Context CreatePlayerContext(
|
Context CreatePlayerContext(PostEffect posteffect, ProgramSet programs) const {
|
||||||
sjplayer.PostEffect posteffect, sjplayer.ProgramSet programs) const {
|
return CreateContextFromText(
|
||||||
return sjplayer.CreateContextFromText(
|
|
||||||
script_path_.readText, posteffect, programs);
|
script_path_.readText, posteffect, programs);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@ import std.conv;
|
|||||||
|
|
||||||
import gl4d;
|
import gl4d;
|
||||||
|
|
||||||
static import sjplayer;
|
import sjplayer;
|
||||||
|
|
||||||
import sj.KeyInput,
|
import sj.KeyInput,
|
||||||
sj.Music,
|
sj.Music,
|
||||||
@ -23,7 +23,7 @@ class PlayScene : SceneInterface {
|
|||||||
enum NearnessScoreRatio = 10;
|
enum NearnessScoreRatio = 10;
|
||||||
|
|
||||||
///
|
///
|
||||||
this(sjplayer.PostEffect posteffect) {
|
this(PostEffect posteffect) {
|
||||||
posteffect_ = posteffect;
|
posteffect_ = posteffect;
|
||||||
}
|
}
|
||||||
~this() {
|
~this() {
|
||||||
@ -36,7 +36,7 @@ class PlayScene : SceneInterface {
|
|||||||
}
|
}
|
||||||
|
|
||||||
///
|
///
|
||||||
void Initialize(Music music, sjplayer.Context context, float offset_beat) {
|
void Initialize(Music music, Context context, float offset_beat) {
|
||||||
music_ = music;
|
music_ = music;
|
||||||
context_ = context;
|
context_ = context;
|
||||||
|
|
||||||
@ -94,12 +94,12 @@ class PlayScene : SceneInterface {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
sjplayer.PostEffect posteffect_;
|
PostEffect posteffect_;
|
||||||
|
|
||||||
ResultScene result_scene_;
|
ResultScene result_scene_;
|
||||||
|
|
||||||
Music music_;
|
Music music_;
|
||||||
sjplayer.Context context_;
|
Context context_;
|
||||||
|
|
||||||
float beat_;
|
float beat_;
|
||||||
int score_;
|
int score_;
|
||||||
|
@ -6,7 +6,7 @@ import std.conv,
|
|||||||
|
|
||||||
import gl4d;
|
import gl4d;
|
||||||
|
|
||||||
static import sjplayer;
|
import sjplayer;
|
||||||
|
|
||||||
import sj.KeyInput,
|
import sj.KeyInput,
|
||||||
sj.LobbyWorld,
|
sj.LobbyWorld,
|
||||||
@ -40,7 +40,7 @@ class TitleScene : SceneInterface {
|
|||||||
enum Contrast = vec4(1.2, 1.2, 1.2, 1);
|
enum Contrast = vec4(1.2, 1.2, 1.2, 1);
|
||||||
|
|
||||||
///
|
///
|
||||||
this(sjplayer.PostEffect posteffect, LobbyWorld lobby, ProgramSet program) {
|
this(PostEffect posteffect, LobbyWorld lobby, sj.ProgramSet.ProgramSet program) {
|
||||||
posteffect_ = posteffect;
|
posteffect_ = posteffect;
|
||||||
lobby_ = lobby;
|
lobby_ = lobby;
|
||||||
title_ = program.Get!TitleTextProgram;
|
title_ = program.Get!TitleTextProgram;
|
||||||
@ -89,7 +89,7 @@ class TitleScene : SceneInterface {
|
|||||||
private:
|
private:
|
||||||
SelectScene select_scene_;
|
SelectScene select_scene_;
|
||||||
|
|
||||||
sjplayer.PostEffect posteffect_;
|
PostEffect posteffect_;
|
||||||
|
|
||||||
LobbyWorld lobby_;
|
LobbyWorld lobby_;
|
||||||
|
|
||||||
|
2
thirdparty/dast/src/dast/parse/itemset.d
vendored
2
thirdparty/dast/src/dast/parse/itemset.d
vendored
@ -119,7 +119,7 @@ do {
|
|||||||
|
|
||||||
T[] new_items;
|
T[] new_items;
|
||||||
foreach (item; items) {
|
foreach (item; items) {
|
||||||
const type =
|
auto type =
|
||||||
!item.canAdvance || item.next.isTerminal? null: item.next.nonTerminalType;
|
!item.canAdvance || item.next.isTerminal? null: item.next.nonTerminalType;
|
||||||
if (resolved_types[].canFind!"a is b"(type)) continue;
|
if (resolved_types[].canFind!"a is b"(type)) continue;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user