-
Posts
174 -
Joined
-
Last visited
Content Type
Blogs
Forums
Store
Gallery
Videos
Posts posted by ChrisMAN
-
-
I am a compiling newb how do you compile against the leadwerks built in lua?
-
I have wanted to do the same but from what i saw only a small portion of the lua bindings are exposed in the engine. It would be very helpful for leadwerks to expose its internal c++ lua binding library and the native c one that ships with lua.
-
I would suggest using the c language, not c++.A good few people on the forum claim to be using c++ but when you look at their code its actually c. The wiki examples are mostly in c not c++. Its easy to learn and you can turn to c++ when you are ready.
EDIT: I would reccomend Code::blocks with Mingw compiler for an easy aproach.
This is good advise. If you learn c++ without learning c first you will not understand some of the stuff that is going on.
Learn C the hard way is pretty tight. http://c.learncodeth...ay.org/book/ C is a lot less bull****; simple and effective. I love linus torvolds rant on c++.
I hope that Josh exposes the rest of the lua bindings in the engine header file for leadwerks 3. We could see some really cool C + lua stuff.
-
Working on it this weekend.
You mean your Intel graphics chip actually runs Leadwerks Engine 2?
It runs on my laptop which has an intel hd 4000 and an nvidia 620. The intel hd 4000 worked until i upgraded to windows 8. The intel hd 4000 runs about 50% perf as the 620. If I don't run in 1920x1080 it is very tolerable. 800x600 usually gets me 60fps for my crappy game.
-
Error messages are nice but...
I feel the exact opposite about c++ being good for beginners. C++ is nothing but syntax sugar for blocks of memory. A beginner should be able to get results while building a foundation in problem solving without having to take on the the problems of compilers, pointers, templates. I don't know why all c++ devs decided they had to abbreviate variables and template names but it is pretty stupid. Try finding beginner information on c++ iterators. The documentation styles for c++ are arcane and ineffective. Some of the new c++11 stuff really breathes fresh air into it but if you are coding in visual studio you won't see those features for a while.
To make matters worse a lot of developers get stuck in structural programming languages like c++ before they learn object oriented ones, or functional styles of programming.
To contrast it is a foundational language that is great for making video games. It teaches algorithmic thinking and performance. It is undergoing a bit of a renaissance and will be a fantastic environment once the right people get involved. Most importantly its rise will hearken the end of the dark ages of programming, the framework languages (.NET, Java) as c++ is becoming a viable substitute.
This is coming from a bitter man who has spent way too much time trying to get mingw to work on a microsoft ecosystem and praying to the gods for binaries to drop from the sky.
- 1
-
If you want to hook into a setter for a table you will have to use a metatable __index/__newindex function.
- 1
-
Writing code is sort of a minigame... Most passionate coders do this.
-
i run my game from the terminal instead of checking the logs, but yes that is my workflow. I have considered writing blender -> scene exporter. I wouldn't mind an excuse to learn python.
-
I don't code in the editor because it is so frustrating to deal with the crashes.
-
I don't quite understand what you are asking. If i understand this is a straight forward way about it.
local settings = db:nrows("Select * from settings")[1] or CreateSettings() -- singleton row function SetSetting(field, value) db:exec("UPDATE settings SET " .. field .. " = " value") settings[field] = value end
-
I am writing a database wrapper and migration library atm. So boring.
-
Are you using Rick's sql package?
http://www.leadwerks.com/werkspace/files/file/302-sqlite-for-les-lua/
I have successfully used it.
Have you created the table? http://www.w3schools.com/sql/sql_create_table.asp
-
-
-
The reason events are so powerful is because they reverse the flow of dependencies. It might be kind of obvious to say such but there might be people who don't know why they are awesome.
-
I might be due for another pass through the scripts folder. All of that stuff is there. The class script is probably the most important. The code reads really well. I have wondered how much of a perf boost could be gained on the lua side by doing proper prototypical inheritance instead of creating extra functions everywhere.
-
My wife has completely redesigned our kitchen virtually. Not going to be cheap.
-
I would just take a normal skybox and apply a hue/saturation in photoshop with the colorize option on. You could even use a post process. It is like the grey scale but yellower.
I am going to be hand painting a skybox in a couple weeks. I am very intimidated.
This looks awesome havn't played with it yet.
http://mouaif.wordpress.com/2009/01/05/photoshop-math-with-glsl-shaders/
-
Entity:SetColor(Vec4) or EntityColor(Entity, Vec4)
http://www.leadwerks...ies#EntityColor
I have never tried it but SetEntityKey might work as well.
- 1
-
A little example of using buffers: http://www.leadwerks...ces/#entry41584
It's not a postprocess filter, but may be usefull for undestanding buffers.
I have looked that this post a bunch of times. It was very helpful. Rendering to buffers seems to be ok every frame as long as you aren't creating buffers but rather reusing a buffer and clearing it.
-
Buffers are a chunk of memory on the video card. You can perform commands such as drawing that will modify buffer. You can render a buffer to the screen or save it as a texture. It is a pretty abstract concept.
- 1
-
You should be able to use PaintEntity http://www.leadwerks.com/wiki/index.php?title=PaintEntity
-
I really like designing interfaces. I think that it is one of the easiest ways to get good usability in games that is often overlooked.
-
LE does support alpha. You have to set blend mode to 1. http://www.leadwerks...?title=SetBlend
I have been using the 2d drawing commands to do my interfaces. http://www.leadwerks...itle=2D_Drawing
I have a library that i have written that is about 85% to release an alpha. le_gui is sadly very complex. I am very happy with it but it sits around 1600 lines of code. It supports event propagation, stylesheets, a rich styles inheritence system, z sorting/index, control parenting, render caching, clipping, a good positioning system via top, left, bottom, right and most importantly a nice api. It is not documented and there are no examples so it might not even be worth your time to look at it. If you need an example of some code that will be able to handle complex interactions, it could be inspiring.
Exposing Lua functions in C++ code
in Programming
Posted
Is there a way to add lua.h against the engine.dll?