Skip to content

Instantly share code, notes, and snippets.

View Konctantin's full-sized avatar
🎯
Focusing

Konctantin Konctantin

🎯
Focusing
View GitHub Profile
@Konctantin
Konctantin / LDAsm.cs
Last active March 26, 2024 10:11
Instruction length disassembler in C#
using System;
namespace IlDasm_CSharp
{
public class ILDasm
{
#region defines
[Flags]
enum RFlag : byte

VCDS opcodes

Engine

Opcode DEscription
007 Common engine temperature
093 Chain (Phase position)

AKP

|Opcode|DEscription|

@Konctantin
Konctantin / ProcessMemory
Created March 28, 2014 16:21
ProcessMemory
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
namespace NetCallerFunc

WSL Preparation

Install go

wget https://dl.google.com/go/go1.20.linux-amd64.tar.gz
sudo tar -xvf go1.20.linux-amd64.tar.gz
sudo mv go /usr/local

Config

-- insert at after line: 345
if Auctionator and Auctionator.Database then
local key = "p:" .. tostring(petInfo.speciesID)
local price = Auctionator.Database:GetPrice(key)
if price ~= nil then
local priceStr = Auctionator.Utilities.CreatePaddedMoneyString(price);
card:AddStat(priceStr,"",0,0.5,0,0.5,"","")
end
end
use kcmod
Declare
@OtchMes smalldatetime='20210401',
@IdSpis int=null,
@Client int=null,
@Vrp int=null
declare @VRP_INT Table (Vrp int)
unit DirectoryMonitor;
interface
uses SysUtils, Classes, Windows, Messages;
const WMUSER_DIRECTORYCHANGED = WM_USER + 1;
type
TActionToWatch = (awChangeFileName, awChangeDirName, awChangeAttributes, awChangeSize, awChangeLastWrite, awChangeLastAccess, awChangeCreation, awChangeSecurity);
use kcmod
go
select ISTK.Nom_Vag,
case
when ISTK.PoluchOKPO>0
then coalesce(
(select top 1 '' from dbo.nsDoroga)
, 'ОКПО грузополучателя - '+cast(ISTK.PoluchOKPO as varchar(123))
, ''
declare @fldList table(nm varchar(128));
select drv.IdZap
, drv.dorogaid
, dor.MNKD as DorName
, Depo_Rem
, fosv.SNAME as Depo_RemName
, vag_GR
, Or_Pr
, Prich_Otkl
select count(*)
-- delete
from kcmod.dbo.THP_SpisHead where
Create_dt < '20150101' or (
Create_dt < '20200101' and (
ISNUMERIC([name]) = 1 -- число как имя списка
or Kol < 5 -- количетво вагонов меньше 5
or len([name]) < 5 -- имя списка короче 5 символов
or [name] like '%ааа%'
or [name] like '%ббб%'