Skip to content

Instantly share code, notes, and snippets.

View PizzaConsole's full-sized avatar
🍕
Exploring awesome new code

PizzaConsole PizzaConsole

🍕
Exploring awesome new code
View GitHub Profile
@PizzaConsole
PizzaConsole / Additional.cs
Created November 13, 2023 22:05
Dependency Injection in Godot
public class ConstrainedRequestPostProcessor<TRequest, TResponse>
: IRequestPostProcessor<TRequest, TResponse>
where TRequest : class
{
public ConstrainedRequestPostProcessor()
{
}
public Task Process(TRequest request, TResponse response, CancellationToken cancellationToken)
{
@PizzaConsole
PizzaConsole / debug.bat
Created February 21, 2021 22:59
Bat file to run Godot dedicated server game
@echo OFF
cd Game.Auth
echo starting auth server
start godot -d --no-window
cd ..
cd Game.Gateway
echo starting gateway
start godot -d --no-window
@PizzaConsole
PizzaConsole / IRepository.cs
Created August 22, 2020 00:15
Generic Repository
using System;
using System.Collections.Generic;
namespace Project.Repository
{
public interface IRepository<TEntity> where TEntity : class
{
IEnumerable<TEntity> GetAll();
IEnumerable<TEntity> GetAllByExpression(Func<TEntity, bool> expression);
@PizzaConsole
PizzaConsole / CustomResultFilterAttribute.cs
Created August 7, 2020 20:59
Use Custom Json Serialization Setting per Controller in ASP.NET Core 3.0+
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Filters;
using Microsoft.AspNetCore.Mvc.Formatters;
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using System;
using System.Buffers;
namespace MyProject.Filters
{