Skip to content

Instantly share code, notes, and snippets.

@Rallymen007
Rallymen007 / run.js
Last active October 17, 2021 19:31
replace bot names in CSS botprofile.db with female names from excel
// npm i csv-parser
// list of girl names from https://catalogue.data.gov.bc.ca/dataset/most-popular-girl-names-for-the-past-100-years
// original botprofile.db from steamapps\common\css\cstrike
// node run.js
// output is botprofile_fem.db
// create new folder, eg custom_bot_names
// put botprofile_fem.db renamed to botprofile.db inside
// drag and drop custom_bot_names folder on vpk.exe located inside steamapps\common\css\bin
// copy created custom_bot_names.vpk to cstrike\custom
const csv = require('csv-parser')
public void GenerateCSharpCode(CodeCompileUnit ccu, string filename)
{
// Generate the code with the custom C# code provider
Modified.Mono.CSharp.CSharpCodeCompiler compiler = new Modified.Mono.CSharp.CSharpCodeCompiler();
// Setup the compilation settings, write a DLL inside the Temp folder
CompilerParameters compileOptions = new CompilerParameters();
compileOptions.GenerateInMemory = false;
compileOptions.GenerateExecutable = false;
compileOptions.CompilerOptions = "/target:library";
//
// Mono.CSharp CSharpCodeProvider Class implementation
//
// Author:
// Daniel Stodden (stodden@in.tum.de)
// Marek Safar (marek.safar@seznam.cz)
// Ilker Cetinkaya (mail@ilker.de)
//
// (C) 2002 Ximian, Inc.
//