Skip to content

Instantly share code, notes, and snippets.

@larsiusprime
larsiusprime / AABB.as
Created April 21, 2016 16:59
collision
package simulation.collision
{
import math.vec2;
public class AABB
{
public var min:vec2;
public var max:vec2;
public function AABB(xmin:Number, ymin:Number, xmax:Number, ymax:Number)

How do I get string content from Haxe to an untyped cpp block?

static public function haxeFunction(inputString:String)
{
  untyped __cpp__ ('
  
      myStruct myFoo;       
      myFoo.data = ???;   //Should be the string contents of Haxe String inputString (1st 16 characters, ASCII only is fine)
 
package tiles
{
import simulation.collision.Segment;
//this defines tile geometry and generates it on command
//
//++TODO: this seems like some sort of factory; it also seems like there's probably a much smarter way to go about doing all of this crap
public interface TileEdgeArchetype
{
@larsiusprime
larsiusprime / PakLibrary.hx
Last active October 25, 2021 07:25
Pak & Unpack system
package;
import haxe.io.Bytes;
import lime.utils.UInt8Array;
import lime.graphics.Image;
import lime.graphics.ImageBuffer;
import openfl.Assets.AssetLibrary;
import openfl.Assets;
import openfl.Lib;
import openfl.utils.ByteArray;
@larsiusprime
larsiusprime / StoreChart.md
Last active January 23, 2019 02:57
Store comparison chart
Feature Steam Epic Discord Kartridge
Redemption keys Yes Yes Yes Yes
Friends list Yes Yes Yes Yes
Chat Yes Yes Yes Yes
In-game purchases (mtx) Yes Yes Yes Yes
Refunds within 2 weeks Yes Yes Yes Yes
Windows Yes Yes Yes Yes
Mac Yes Yes No Yes
Linux Yes No No No
@larsiusprime
larsiusprime / AABB.hx
Last active May 24, 2018 21:01
Defender's Quest Performance Profiling References
package com.leveluplabs.tdrpg.qtree;
import com.leveluplabs.tdrpg.Popup_OverworldMenu;
import flixel.util.FlxDestroyUtil.IFlxDestroyable;
import flixel.util.FlxPool;
/**
* ...
* @author larsiusprime
*/
class AABB implements IFlxDestroyable
/**
sys_create_dir : string -> mode:int -> void
<doc>Create a directory with the specified rights</doc>
**/
bool _hx_std_sys_create_dir( String path, int mode )
{
printf("_hx_std_sys_create_dir()\n");
#ifdef EPPC
return true;
#else

Addressed:

  • Established developers should be able to get app IDs more easily (Steam Direct)
  • Create a developer support ticket system (TomG claims this is addressed)
  • Allow selling “unlisted” apps on Steam with no public store page (TomG claims this is addressed)

Unaddressed:

  • Players should be able to “follow” developers on Steam
  • Add embeddable "add to Steam wishlist" buttons for the web
char* text = GetSomeTextInUTF8Format();
std::wstring* result = new std::wstring (text, text + strlen (text));

So say I have a function like this:

int doSomeStuff(
   const SomeStruct *myStruct
)

And SomeStruct is defined like this: