This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using LiteNetLibManager; | |
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
namespace MultiplayerARPG | |
{ | |
public partial class PlayerCharacterEntity | |
{ | |
[DevExtMethods("Start")] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add soft currency (coin) | |
var increaseSoftCurrency = 100; // Adding 100 coins | |
var softCurrency = GetCurrency(playerId, GameInstance.GameDatabase.softCurrency.id); | |
softCurrency.Amount += increaseSoftCurrency; | |
colPlayerCurrency.Update(softCurrency); | |
// Add hard currency (gem) | |
var increaseHardCurrency = 50; // Adding 50 gems | |
var hardCurrency = GetCurrency(playerId, GameInstance.GameDatabase.hardCurrency.id); | |
hardCurrency.Amount += increaseHardCurrency; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-startMapSpawnServer | |
-spawnExePath "Path of your execution file such as C:\Game\Game.exe" | |
-startCentralServer | |
-startChatServer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-machineAddress "Address to your machine" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
D:\MMO\MMO.exe -startMapSpawnServer -spawnExePath "D:\MMO\MMO.exe" -startCentralServer -startChatServer -machineAddress "192.168.1.102" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ./Game.app -startMapSpawnServer -spawnExePath "Path of your execution file such as /Game/Game.app" -startCentralServer -startChatServer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
minValue + Mathf.CeilToInt((maxValue - minValue) * Mathf.Pow((float)(currentLevel - 1) / (float)(maxLevel - 1), growth)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'newpassword'; | |
composer install | |
php artisan migrate | |
chmod -R 0777 storage/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.EventSystems; | |
public class DraggableWindow : MonoBehaviour, IBeginDragHandler, IDragHandler | |
{ | |
private float mouseOffsetY; | |
private float mouseOffsetX; | |
public void OnBeginDrag(PointerEventData eventData) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using UnityEngine.Events; | |
using LiteNetLib; | |
using LiteNetLibManager; | |
namespace MultiplayerARPG.MMO | |
{ | |
public class EnterMMOServer : MonoBehviour |