(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
Здоровье в качестве валюты как в некоторых комнатах Isaac'а или пули за здоровье в Bloodborne | |
Туман войны, он есть во многих стратегиях | |
Отсутствие меню, или меню вписанное в игровой мир, например в Antichamber | |
Красные бочки - наверное одна из самых шаблонных механик - но зато это делает её понятной всем игрокам | |
Такая широкая идея как редактирование мира, как в терарии и майнкрафте, или в astroneer, в котором она выглядит красивее засчёт отсутствия блоков | |
Гибкое создание кастомных заклинаний или оружия, как было в тех же Worms | |
Сохранение в кровати или в доме игрового персонажа | |
Bullet hell, и не обязательно как жанр, можно создать такого босса или уровень во многих 2D играх со стрельбой | |
Сложные взаимоотношения между нпс, когда мутанты сражаются с рейдерами, или система нпс в Streets Of Rouge | |
Изменение цвета уровня как в shift |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
using TMPro; | |
using UnityEngine; | |
[RequireComponent(typeof(TextMeshProUGUI))] | |
public class BuildDisplayer : MonoBehaviour | |
{ | |
private TextMeshProUGUI Text; | |
private void Awake() | |
{ |
Репозиторий - это слой абстракции, инкапсулирующий в себе всё, что относится к способу хранения данных. Назначение: Разделение бизнес-логики от деталей реализации слоя доступа к данным.
Паттерн Репозиторий стал популярным благодаря DDD (Domain Driven Design). В противоположность к Database Driven Design в DDD разработка начинается с проектирования бизнес логики, принимая во внимание только особенности предметной области и игнорируя все, что связано с особенностями базы данных или других способов хранения данных. Способ хранения бизнес объектов реализуется во вторую очередь.
Применение данного паттерна не предполагает создание только одного объекта репозитория во всем приложении. Хорошей практикой считается создание отдельных репозиториев для каждого бизнес-объекта или контекста, например: OrdersRepository, UsersRepository, AdminRepository.
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class MeshDestroy : MonoBehaviour | |
{ | |
private bool edgeSet = false; | |
private Vector3 edgeVertex = Vector3.zero; | |
private Vector2 edgeUV = Vector2.zero; |
Unity shows the following warning on mobile devices up to Unity 2019.4: "Please note that Unity WebGL is not currently supported on mobiles. Press OK if you wish to continue anyway." This script helps you remove this warning
To see live examples see Unity Web GL Loading Test
The script will run after the build has completed and replace the checks from all generated javascript files.
# Git LFS tracking file types | |
# IronSource | |
*.a filter=lfs diff=lfs merge=lfs -text | |
IS*Adapter filter=lfs diff=lfs merge=lfs -text | |
GoogleMobileAds filter=lfs diff=lfs merge=lfs -text | |
# Image | |
*.jpg filter=lfs diff=lfs merge=lfs -text | |
*.jpeg filter=lfs diff=lfs merge=lfs -text |
using UnityEngine; | |
using UnityEditor; | |
using System.IO; | |
public static class CustomInspectorCreator | |
{ | |
[MenuItem("Assets/Create/Custom Inspector", priority = 81)] | |
static void CreateInsptorEditorClass() | |
{ | |
foreach (var script in Selection.objects) |
using UnityEngine; | |
using UnityEditor; | |
using UnityEditor.SceneManagement; | |
// Adds a "Edit Prefab" option in the Assets menu (or right clicking an asset in the project browser). | |
// This opens an empty scene with your prefab where you can edit it. | |
// Put this script in your project as Assets/Editor/EditPrefab.cs | |
public class EditPrefab { | |
static Object getPrefab(Object selection) { |
#!/bin/bash | |
for i in *psd | |
do | |
name=${i%.psd} | |
convert "$name.psd[0]" -resize 100% "$name.png" | |
done |