본문 바로가기
728x90
SMALL

분류 전체보기153

[ChatGPT][Processing 프로세싱][2D RPG게임] Processing 프로그래밍 언어를 사용하는 간단한 2D RPG 스프라이트(캐릭터) 시트 애니메이션의 예제 샘플 Processing 프로그래밍 언어를 사용하는 간단한 2D RPG 스프라이트(캐릭터) 시트 애니메이션의 예제 샘플 PImage spriteSheet; int spriteSize = 32; int spriteX = 0; int spriteY = 0; int frame = 0; int animationSpeed = 12; void setup() { size(512, 512); spriteSheet = loadImage("sprites.png"); } void draw() { frame++; if (frame % animationSpeed == 0) { spriteX++; if (spriteX > 3) { spriteX = 0; spriteY++; if (spriteY > 3) { spriteY = 0; } .. 2023. 1. 23.
[ChatGPT][Processing 프로세싱][2D RPG게임] Processing 프로그래밍 언어를 사용하는 간단한 2D RPG 타일맵의 예제 샘플 Processing 프로그래밍 언어를 사용하는 간단한 2D RPG 타일맵의 예제 샘플 // Here is an example of a simple 2D RPG tilemap using the Processing programming language PImage tileSheet; int tileSize = 32; int[][] map = { {1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1}, {1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1}, {1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1}, {1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1}, {1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1}, {1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.. 2023. 1. 23.
[ChatGPT][Scala.js] Scala.js / Three.js 3D 게임 프로그래밍 샘플 코드 Scala.js / Three.js 3D 게임 프로그래밍 샘플 코드 /*Here is an example of a simple 3D game program written in Scala.js using the Three.js library*/ import org.scalajs.dom._ import scala.scalajs.js.annotation.JSExport import org.scalajs.dom.html.Canvas import scala.scalajs.js.timers._ import scala.scalajs.js import org.scalajs.dom.raw.WebGLRenderingContext._ import org.scalajs.dom.html.Element import org.sca.. 2023. 1. 22.
[ChatGPT][Scala.js] Scala.js 2D 게임 프로그래밍 샘플 코드 Scala.js 2D 게임 프로그래밍 샘플 코드 /*Here is an example of a simple 2D game program written in Scala.js */ import org.scalajs.dom.{document, window} import scala.scalajs.js.annotation.JSExport import scala.scalajs.js.timers._ @JSExport object Game { val canvas = document.createElement("canvas") val ctx = canvas.getContext("2d") document.body.appendChild(canvas) var x = 0 var y = 0 @JSExport def main(): .. 2023. 1. 22.
728x90
LIST