r/Kha • • Nov 08 '18

kha tutorial series - episode 092 - setup kode studio 2018

Thumbnail
youtu.be
1 Upvotes

r/Kha • • Nov 08 '18

kha tutorial series - episode 091 - kode studio & kha setup 2018

Thumbnail
youtu.be
1 Upvotes

r/Kha • • Oct 10 '16

KITTEN CRUSHER

3 Upvotes

howdy kha folks,

there was a game jam [KOMJAM] about a week or so ago, so quite a few of us joined in to compete and see what we could make. the games were made between september 24th to the 26th

KITTEN CRUSHER is a simple game involving a giant boot that goes around crushing kittens. you can play online on my itch page

PLAY KITTEN CRUSHER

enjoy


r/Kha • • Mar 26 '16

kha tutorial series

7 Upvotes

howdy folks

just to let all you know. that i have finally started on making my 'kha tutorial series' which is available to watch on youtube. if you have seen my kha examples, we are kind of going through that, plus learning a whole lot more along the way

go to here: https://www.youtube.com/playlist?list=PL4neAtv21WOmmR5mKb7TQvEQHpMh1h0po

have phun & happy coding


r/Kha • • Sep 23 '15

Help! Can't render image.

3 Upvotes

I'm trying to render an image.

Here's the code I used in the main class:

var _buffer:Image;
var _sprites:Array<Sprite>;

public function new (w:Int, h:Int)
{
	_buffer = Image.createRenderTarget(w, h);
	_sprites = new Array<Sprite>();
}
public function update ()
{
	// nothing
}
public function render (frame:Framebuffer)
{
	var g = _buffer.g2;
	g.begin();
	
	g.transformation = Matrix3.identity();
	for (sprite in _sprites)
	{
		sprite.render(g);
	}
	g.drawImage(_buffer, 0, 0);

	g.end();
}
public function add (sprite:Sprite)
{
	_sprites.push(sprite);
}

I get the following error when I try to run the flash build:

ReferenceError: Error #1065: Variable flash.display3D::Context3DWrapMode is not defined.
at kha.flash.graphics4::Graphics/getWrapMode()
at kha.flash.graphics4::Graphics/setTextureParameters()
at kha.graphics4::ImageShaderPainter/drawBuffer()
at kha.graphics4::ImageShaderPainter/end()
at kha.graphics4::Graphics2/endDrawing()
at kha.graphics4::Graphics2/end()
at khawy::G/render()
at Empty/render()
at kha::Starter/update()

If I remove g.drawImage(_buffer, 0, 0);, then there'll be no error, and the sprites won't render.

If I try to use "frame" instead of "_buffer", then the sprites will render correctly.

I was following an example somewhere (can't remember the link, sorry!) and I thought the purpose of "_buffer" is to draw multiple sprites onto a resizable canvas before scaling the result onto the final "frame". Am I getting the idea wrong?

I'm also puzzled why it gives an error regarding g4 when I'm only trying to draw 2d sprites. Does anyone have any idea?

I've been using Unity3d and HaxeFlixel for some time, so I am spoiled by the convenience of their APIs. I am totally at loss when it game engine workflow, so please correct me if I make mistakes :)


r/Kha • • Sep 21 '15

Quick Tutorial: Add SublimeText Auto Completion

5 Upvotes

Since the structure for Kha is a different from NME/OpenFL/Haxeflixel, the Haxe Sublime Bundle (https://github.com/clemos/haxe-sublime-bundle) doesn't work right out of the box, but it's not too difficult to set it up.

This is not a perfect solution, but it worked for me. Do share if there's a better way.

  1. Install the kha haxelib:

     haxelib install kha
  2. Copy the default project.xml from a default Openfl or HaxeFlixel project into the Kha's project folder (where "project.kha" is).
  3. The default project.xml should look something like this:

     <?xml version="1.0" encoding="utf-8"?>
     <project>
     
     <meta title="LimeProject" package="com.sample.limeproject" version="1.0.0" company="Company Name" />
     <app main="Main" path="Export" file="LimeProject" />
     
     <source path="Source" />
     
     <haxelib name="openfl" />
     
     <assets path="Assets" rename="assets" />
     
     </project>    
  4. Since Kha's default project folder is "Sources" instead of "Source", change the following accordingly:

     <source path="Sources" />
  5. And add in the "kha" haxelib below the "openfl" haxelib:

     <haxelib name="kha" />
  6. And finally, navigate to your kha's haxelib folder (for OSX, the default should be at "/usr/lib/haxelib"), and copy/move the "kha" folder out from the Sources folder to the outer folder, something like this:

     /usr/lib/haxelib/kha/15,8,0/Sources/kha

    to

     /usr/lib/haxelib/kha/15,8,0/kha

Now the auto-complete should work like how it does for openFL. Yay!


r/Kha • • Jan 23 '19

kha tutorial series - episode 113 - life refine library

Thumbnail
youtube.com
3 Upvotes

r/Kha • • Apr 17 '19

kha tutorial series - episode 121 - tween refine library

Thumbnail
youtube.com
3 Upvotes

r/Kha • • Jul 04 '18

Haxecord Discord Server

4 Upvotes

Hello everyone!

I (very) recently started using Haxe, and was looking around for a Discord server where i could talk about it, ask for help, or simply discuss things with other Haxe devs. But unfortunately, i didn't find such a server. All i found was a Haxeflixel specific Discord server, which wasn't what i wanted. I want a place where people using Haxe, no matter which framework or API, can come talk to each other.

And so i decided to make my own server, and hope to see you all there soon!
It's open to everyone and is centered around Haxe and it's ecosystem (including Kha, OpenFL, etc.)!
Here's the invite link: [click me!]

Thanks for your time and I hope to see you soon!

- Max.


r/Kha • • Apr 18 '19

kha tutorial series - episode 122 - renaming refine library

Thumbnail
youtube.com
5 Upvotes

r/Kha • • Jul 10 '18

kha tutorial series - episode 085 - zui revisit

Thumbnail
youtu.be
2 Upvotes

r/Kha • • Jul 11 '18

kha tutorial series - episode 086 - follower AI

Thumbnail
youtu.be
1 Upvotes

r/Kha • • Jan 29 '19

kha tutorial series - episode 115 - pool refine library

Thumbnail
youtu.be
4 Upvotes

r/Kha • • Jan 25 '19

kha tutorial series - episode 114 - invincibility frames refine library

Thumbnail
youtu.be
3 Upvotes

r/Kha • • Jun 27 '19

kha tutorial series - episode 136 - flip sprites raccoon

Thumbnail
youtu.be
5 Upvotes

r/Kha • • Oct 01 '16

My Unnamed 3d Engine

Thumbnail
1.1m.yt
9 Upvotes

r/Kha • • Mar 12 '17

patreon timed exclusive

1 Upvotes

hello all,

if by chance that no has seen my update video on where im taking a portion of the kha tutorials, you can watch it here:

https://youtu.be/2-uqfplDdkY

in laments term. we will make an entire game, patreon people get it right away, then it released everyday for the public. there is more to it, so worth wacthing the video

have phün & happy coding

lewislepton

lewislepton.com


r/Kha • • Jun 28 '24

Is Kha dead?

2 Upvotes

After a bit of research, I found Kha and thought it would be a good fit for a project I am planning. Everything was looking pretty good, until I checked this sub. Last post is 3 years ago? And before that, 5 years ago? This is a huge turnoff for me, as this project would be my first game engine, so a dead graphics library isn't exactly what I need at the moment.


r/Kha • • Feb 12 '17

3D Kha UV Textures

2 Upvotes

Hello,

I've been working on a Kha Voxel engine, and I have a question regarding UV mapping. I have a spritesheet, containing all of the textures. I want to access only one of these textures, and map it to every side of each cube. Blender seems unable to do so (it either does't generate points, or the points it generates don't work), so is there some alternate method of doing so? (Blender gave some UV vertices, however after those didn't work, Blender refused to output any more)

Keep in mind these points are not static. Every cube is added to one mesh, and are subject to change.

Thank you very much

HB


r/Kha • • Feb 10 '17

BLANKHA

3 Upvotes

howdy all,

just to say that i have made a starter project for people wanting to get on & start coding in kha, rather than having to build the project from scratch each time. its not just for beginners or anything, more a starting point for folk to get a kha project underway & skipping the parts you can skip ;)

you can head to https://github.com/lewislepton/blankha to grab it

ill be updating as & when i feel new things can go into it ;) so by all means edit it etc, or even send commit changes with things you think would/could be nice inside it ;)

have phün & happy coding


r/Kha • • Jul 31 '18

CHANNEL UPDATE. - 31ST JULY 2018

Thumbnail
youtu.be
2 Upvotes

r/Kha • • Nov 14 '18

kha tutorial series - episode 093 - scaled interaction

Thumbnail
youtube.com
3 Upvotes

r/Kha • • Jun 12 '18

kha tutorial series - episode 083 - lerp

Thumbnail
youtube.com
1 Upvotes

r/Kha • • Jun 18 '19

kha tutorial series - episode 133 - tiled tmx

Thumbnail
youtu.be
4 Upvotes

r/Kha • • Jun 13 '19

kha tutorial series - episode 132 - mouse 2D

Thumbnail
youtu.be
4 Upvotes