リソースのダウンロード先を変更
This commit is contained in:
@@ -241,7 +241,7 @@ class PetitComputer
|
|||||||
GraphicPage createGRPF(string file)
|
GraphicPage createGRPF(string file)
|
||||||
{
|
{
|
||||||
SDL_RWops* stream = SDL_RWFromFile(toStringz(file), toStringz("rb"));
|
SDL_RWops* stream = SDL_RWFromFile(toStringz(file), toStringz("rb"));
|
||||||
auto src = IMG_LoadPNG_RW(stream);
|
auto src = IMG_Load_RW(stream, 0);
|
||||||
SDL_Surface* surface = SDL_CreateRGBSurface(0, src.w, src.h, 32, 0x00ff0000, 0x0000ff00, 0x000000ff, 0xff000000);//0xff000000, 0x00ff0000, 0x0000ff00, 0xFF);
|
SDL_Surface* surface = SDL_CreateRGBSurface(0, src.w, src.h, 32, 0x00ff0000, 0x0000ff00, 0x000000ff, 0xff000000);//0xff000000, 0x00ff0000, 0x0000ff00, 0xFF);
|
||||||
SDL_Rect rect;
|
SDL_Rect rect;
|
||||||
rect.x = 0;
|
rect.x = 0;
|
||||||
@@ -381,19 +381,19 @@ class PetitComputer
|
|||||||
if(!exists(fontFile))
|
if(!exists(fontFile))
|
||||||
{
|
{
|
||||||
writeln("download font");
|
writeln("download font");
|
||||||
download("http://smileboom.com/special/ptcm3/download/unicode/image/res_font_table-320.png",
|
download("http://smilebasic.com/wordpress/wp-content/themes/smilebasic/publishimage/appendix/res_font_table-320.png",
|
||||||
fontFile);
|
fontFile);
|
||||||
}
|
}
|
||||||
if(!exists(spriteFile))
|
if(!exists(spriteFile))
|
||||||
{
|
{
|
||||||
writeln("download sprite");
|
writeln("download sprite");
|
||||||
download("http://smileboom.com/special/ptcm3/image/ss-story-attachment-1.png",
|
download("http://dengekionline.com/elem/000/000/927/927124/petitcom_16_cs1w1_512x512.jpg",
|
||||||
spriteFile);
|
spriteFile);
|
||||||
}
|
}
|
||||||
if(!exists(BGFile))
|
if(!exists(BGFile))
|
||||||
{
|
{
|
||||||
writeln("download BG");
|
writeln("download BG");
|
||||||
download("http://smileboom.com/special/ptcm3/image/ss-story-attachment-2.png",
|
download("http://dengekionline.com/elem/000/000/927/927125/petitcom_17_cs1w1_512x512.jpg",
|
||||||
BGFile);
|
BGFile);
|
||||||
}
|
}
|
||||||
if(!exists(fontTableFile))
|
if(!exists(fontTableFile))
|
||||||
@@ -832,6 +832,8 @@ class PetitComputer
|
|||||||
protected BG[4] bg;
|
protected BG[4] bg;
|
||||||
bool quit;
|
bool quit;
|
||||||
void render()
|
void render()
|
||||||
|
{
|
||||||
|
try
|
||||||
{
|
{
|
||||||
paint.buffer = new uint[512 * 512];
|
paint.buffer = new uint[512 * 512];
|
||||||
DerelictSDL2.load();
|
DerelictSDL2.load();
|
||||||
@@ -850,6 +852,11 @@ class PetitComputer
|
|||||||
|
|
||||||
DerelictGL.load();
|
DerelictGL.load();
|
||||||
DerelictGL3.load();
|
DerelictGL3.load();
|
||||||
|
}
|
||||||
|
catch(Throwable t)
|
||||||
|
{
|
||||||
|
writeln(t);
|
||||||
|
}
|
||||||
bool renderprofile;// = true;
|
bool renderprofile;// = true;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user