본문 바로가기

분류 전체보기159

Google Play 데이터 보안 설정 안내 https://help.dfinery.io/hc/ko/articles/4408886613401--%EC%A4%91%EC%9A%94-Google-Play-%EB%8D%B0%EC%9D%B4%ED%84%B0-%EB%B3%B4%EC%95%88-%EC%84%A4%EC%A0%95-%EC%95%88%EB%82%B4 2024. 7. 3.
애드몹 광고 연동하기 Google 모바일 광고 Unity 플러그인 https://github.com/googleads/googleads-mobile-unity/releases/tag/v9.1.0  Release Google Mobile Ads Unity Plugin v9.1.0 · googleads/googleads-mobile-unityPlugin : Removed the app measurement feature as Android/iOS SDKs no longer initialize App measurement. Fixed [#3290] by calling static putPublisherFirstPartyIdEnabled with boolean return type. Fix...github.com   https://.. 2024. 6. 27.
Google Play 게임 서비스 설정하기 구글 서비스 연동하기   https://github.com/playgameservices/play-games-plugin-for-unity GitHub - playgameservices/play-games-plugin-for-unity: Google Play Games plugin for UnityGoogle Play Games plugin for Unity. Contribute to playgameservices/play-games-plugin-for-unity development by creating an account on GitHub.github.com          using System.Collections;using System.Collections.Generic;using UnityEn.. 2024. 6. 21.
요요 using DG.Tweening; // DOTween 네임스페이스를 사용합니다.using UnityEngine;public class TileMovement : MonoBehaviour{    private Vector2 originalPosition;    void OnMouseDown()    {        // 오브젝트를 클릭했을 때 원래 위치를 저장합니다.        originalPosition = transform.position;    }    void OnMouseDrag()    {        // 드래그 로직을 구현합니다. 여기서는 마우스 위치를 따라가도록 설정합니다.        Vector2 mousePosition = Camera.main.ScreenToWorldPoint(I.. 2024. 5. 20.
같은 모양의 블럭 삭제하기 -  가로 세로  연속된 같은 이름의  블럭을 수를 센다.-  가로 세로 3개 이상의 연속된 블럭을 삭제한다.  private void FindsameBlock() { // 각 열과 행을 검색해서 같은 이름의 블록을 찾는다 for (int row = 0; row ().sprite.name; // 가로 방향으로 연속된 같은 블록 수를 센다 int horizontalCount = CountSameBlocks(row, col, spriteName, true,false); // 세로 방향으로 연속된 같은 블록 수를 센다 int verticalCount = CountSam.. 2024. 5. 13.
블럭 드래그 해서 이동하기 러프를 사용해서 부드럽게 이동하기  // 블록 이동 private void MoveBlock(int currentRow, int currentCol, int newRow, int newCol) { isdragging = true; // 두 지점의 블록 가져오기 GameObject currentBlock = blocks[currentRow, currentCol]; GameObject newBlock = blocks[newRow, newCol]; // 블록 위치 갱신 Vector3 currentCellPosition = cells[currentRow, currentCol].transform.. 2024. 5. 13.
블럭 클릭해서 드래그하면 블럭의 좌표, 이동방향 표시하기 private void ClickBlock() { // 클릭한 위치의 셀 인덱스를 디버그로 출력 / 블록이름 보여주기 if (Input.GetMouseButtonDown(0)) { isdragging = true; this.StartDrag = Camera.main.ScreenToWorldPoint(Input.mousePosition); int col = Mathf.RoundToInt(StartDrag.x); int row = Mathf.RoundToInt(StartDrag.y); if (col >= 0 && col = 0 && row (); .. 2024. 5. 13.
블럭 랜덤 생성하기 블럭 컨트롤러- 블럭에 랜덤 스프라이트 적용using System.Collections;using System.Collections.Generic;using UnityEngine;using UnityEngine.UI;using static Unity.Collections.AllocatorManager;public enum BlockName{ Chick, Bear,Cat,Monkey, Mouse, Pig, Rabbit}public class BlockController : MonoBehaviour{ BlockName blockName; SpriteRenderer spriteRenderer; public Sprite[] sprites; // 열거형 BlockName에 포함된 .. 2024. 5. 13.
Firebase 데이터 서버에 저장하기 / 랭킹 만들기 https://firebase.google.com/?hl=ko Firebase | Google’s Mobile and Web App Development Platform개발자가 사용자가 좋아할 만한 앱과 게임을 빌드하도록 지원하는 Google의 모바일 및 웹 앱 개발 플랫폼인 Firebase에 대해 알아보세요.firebase.google.com  using System.Collections;using System.Collections.Generic;using UnityEngine;public class UserInfo{ public string userId; public int score; //생성자 public UserInfo(string userId, int score) .. 2024. 5. 2.