Skip to content

Instantly share code, notes, and snippets.

View fu-sen's full-sized avatar
🎈
🎈😍

BALLOON | FU-SEN fu-sen

🎈
🎈😍
View GitHub Profile
@fu-sen
fu-sen / balloon.c
Created July 1, 2019 02:47
z88dk sprite sample 8x8
char sprite[] = { 8, 8,
0x0e /* ....###. */,
0x1d /* ...###.# */,
0x1f /* ...##### */,
0x1f /* ...##### */,
0x0e /* ....###. */,
0x08 /* ....#... */,
0x10 /* ...#.... */,
0xe0 /* ###..... */
};
@fu-sen
fu-sen / 5x5.c
Created July 1, 2019 02:55
z88dk sprite sample 5x5
char sprite[] = { 5, 5,
0x70 /* .###.... */,
0xe8 /* ###.#... */,
0xf8 /* #####... */,
0xf8 /* #####... */,
0x70 /* .###.... */
};
@fu-sen
fu-sen / sprite.c
Last active July 1, 2019 04:26
z88dk sprite sample
#include <graphics.h>
#include <games.h>
#include <stdio.h>
char balloon[] = { 8, 8,
0x0e, 0x1d, 0x1f, 0x1f, 0x0e, 0x08, 0x10, 0xe0
};
void main(){
clg();
@fu-sen
fu-sen / test.c
Last active December 4, 2019 03:39
z88dk PC-E200/G text test
#include <graphics.h>
#include <conio.h>
#include <stdio.h>
main(){
clg();
gotoxy(1,1);
printf("test\n");
@fu-sen
fu-sen / text.c
Last active December 4, 2019 03:38
text sample | z88dk
#include <stdio.h>
void main() {
for (int y=1; y<=6; y++) {
for (int x=1; x<=24; x++) {
printf("%c[%u;%uH ", 27, y, x);
}
}
printf("%c[%u;%uH",27,2,2); // locate
@fu-sen
fu-sen / sin.c
Last active April 19, 2025 02:20
Sine curve | z88dk mono graphics
/*
Sine curve | z88dk mono graphics
Copyright (c) 2019 BALLOON | FU-SEN
The MIT License (MIT) - https://mit.balloon.net.eu.org/#2019
Colecovision:
zcc +coleco -lm -create-app -bn sin sin.c (generate sin.rom)
MSX (-pragma-define:CLIB_DEFAULT_SCREEN_MODE=3 also works):
zcc +msx -lm -pragma-define:CLIB_DEFAULT_SCREEN_MODE=2 -create-app -bn sin sin.c (Cassette tape image, generate sin.cas)
' Sine curve | MSX-BASIC
' Copyright (c) 2019 BALLOON | FU-SEN
' The MIT License (MIT) - https://mit.balloon.net.eu.org/#2019
10 COLOR 15,4,7:SCREEN 2
20 LINE(0,96)-(255,96),14
30 FOR X=0 TO 255
40 Y=96*(1-3.1415927*2*X/192)
50 PSET(X,Y),15
60 NEXT X
70 I$=INPUT$(1)
# Balloons | ruby4ij
# Copyright (c) 2019 BALLOON | FU-SEN
# The MIT License (MIT) - https://mit.balloon.net.eu.org/#2019
cls
while inkey()==-1
x=rnd 31
lc x,23
p 232
@fu-sen
fu-sen / Dockerfile
Last active January 28, 2020 03:40
Caddy v2 (Officical Docker Image) with Google Cloud Run https://caddy.community/t/caddy-works-with-google-cloud-run/6898
FROM caddy/caddy:alpine
COPY ./ /usr/share/caddy/
USER root
RUN sed -i 's/:8080/:{$PORT}/' /etc/caddy/Caddyfile
@fu-sen
fu-sen / Caddyfile
Last active October 17, 2024 21:49
Caddy v2 (Officical Docker Image) with Google Cloud Run (Freely editable Caddyfile) https://caddy.community/t/caddy-works-with-google-cloud-run/6898
:{$PORT}
root * /srv
# Do not rewrite up to this point!
file_server
templates