• LuaCraft | Minecraft with a taste of Lua
    383 replies, posted
[QUOTE=thomasfn;35978616]There is no way to make Bukkit work alongside LuaCraft in the same server binary. There's also no way to install standard minecraft mods (such as modloader etc) into the LuaCraft client. This is because LuaCraft overrides many of the same classes that Bukkit and modloader do, and there would be conflicts. I wonder how viable it would be to use Lua to "emulate" a java environment and load in existing Bukkit or modloader plugins though...[/QUOTE] [QUOTE=BlackAwps;35941617]You have to remember that this is lua emulated in pure java.. :v: Some things are missing. I will look and see if I can do it, however.[/QUOTE] wait, java emulated in lua emulated in java? how about we all just wait until the official mod support arrives for minecraft and we see what's possible and what isn't
No, Lua emulated in Java.
I'm pointing out the ridiculousness of what was said - I even fucking quoted everything relevant. I miss bad reading.
Well gmod has a binary module system, what's to stop LuaCraft from having a similar system but loading java classes instead? You could fake a Bukkit interface.
The require function will load a java class.
[QUOTE=BlackAwps;35985747]The require function will load a java class.[/QUOTE] Tbh it's not even necessary, as you can get access to all the java classes using the [url=http://www.keplerproject.org/luajava/manual.html#luareference]LuaJava[/url] library included into LuaJ [editline]16th May 2012[/editline] but I can go ahead and add class loading support.
ConsoleCommand function dosen't work. Tried something like this : ConsoleCommand("say Hello") It said Console:1: attempt to call nil.
Hey here's a suggestion: add a function to check what special effects are currently affecting the player (like poison, swiftness,...) maybe make it return a table of strings or a table of numbers EDIT: i meant table, not list
[QUOTE=Fleskhjerta;35989667]ConsoleCommand function dosen't work. Tried something like this : ConsoleCommand("say Hello") It said Console:1: attempt to call nil.[/QUOTE] ConsoleCommand is currently server only.
Any plans for some kind of script enforcer?
The problem with script enforcement on an open source client is that cheaters can just compile their own version with it disabled.
[QUOTE=LuaStoned;35824528][img]http://img.luastoned.com/dev_3D_moar.png[/img][/QUOTE] How does one use this functionality? I can't figure it out and the wiki is rather outdated (With the whole summer holiday ahead, I'm willing to help get it up-to-speed)
[QUOTE=somescripter;36001640]Any plans for some kind of script enforcer?[/QUOTE] No.
[QUOTE=Lexic;36001669]The problem with script enforcement on an open source client is that cheaters can just compile their own version with it disabled.[/QUOTE] I'm not sure how that's a problem. The client shouldn't be able to touch other clients, if the server doesn't let them. If someone compiles a server that's "bad", then people should just stay away from it. Or you should be able to turn it off.
[QUOTE=T3hGamerDK;36005607]I'm not sure how that's a problem. The client shouldn't be able to touch other clients, if the server doesn't let them. If someone compiles a server that's "bad", then people should just stay away from it. Or you should be able to turn it off.[/QUOTE] I don't think you understand what he's asking for. He wants it so only authorized scripts are allowed on his server. Which ain't gonna happen, since Java.
[QUOTE=Matt-;36006625]I don't think you understand what he's asking for. He wants it so only authorized scripts are allowed on his server. Which ain't gonna happen, since Java.[/QUOTE] I'm not quite following up here.. How does Java prevent this?
[QUOTE=T3hGamerDK;36007583]I'm not quite following up here.. How does Java prevent this?[/QUOTE] You could easily disable the checks. I might add it as like in gmod, Script Enforcer is easy to bypass but stops most people.
[QUOTE=origamiguy;36003389]How does one use this functionality? I can't figure it out and the wiki is rather outdated (With the whole summer holiday ahead, I'm willing to help get it up-to-speed)[/QUOTE] Hopefully this will help you. [lua]BLOCK_SIZE = Vector(1,1,1) vector_up = Vector(0,0,1) local font = surface.GetFont() hook.Add( "render.world", "Draw 3D Shits", function() local tr = LocalPlayer():Trace() surface.SetDrawColor( 255, 0, 0, 255 ) surface.DrawLine( tr.HitPos, tr.HitPos + BLOCK_SIZE, 3 ) -- Pos 1, Pos 2, thickness surface.SetDrawColor( 0, 255, 0, 255 ) surface.DrawBoundingBox( tr.HitPos, tr.HitPos + BLOCK_SIZE, 2 ) -- Pos 1, Pos 2, thickness surface.SetDrawColor( 0, 0, 255, 150 ) surface.DrawSphere( tr.HitPos + BLOCK_SIZE * 0.5, 0.25, 15 ) -- Pos, radius, slices surface.SetDrawColor( 255, 0, 255, 255 ) surface.DrawCylinder( tr.HitPos + Vector(1,1,0) * 0.5, 0.5, 0.25 ) -- Pos, length, radius surface.SetDrawColor( 255, 255, 0, 255 ) surface.DrawCircle( tr.HitPos + BLOCK_SIZE * 0.5 + vector_up * 0.5, 0.5, 0, Angle( 0, 0, 0 ) ) -- Pos, outer radius, inner radius, Angle surface.SetDrawColor( 255, 255, 255, 255 ) font:DrawTextShadow( "3D Text", tr.HitPos + vector_up * 1, Angle(0,0,0), 0.2 ) -- Text, Pos, angle, scale end )[/lua] Will result in [img]http://puu.sh/vsce[/img]
I need to learn Lua for real. So this would work as an easier way to mod, right? You could add anything and more?
Another question. Why are Y/Z axes swapped over in LuaCraft? I'm very used to Minecraft using Y as the 'up' axis; LuaCraft's Z-up system messed my head a tad.
Z is the height in almost every game, No idea why notch made it Y T_T
[QUOTE=Crashty;36011291]Z is the height in almost every game, No idea why notch made it Y T_T[/QUOTE] No it isn't. Y is up most of the time. But this is for glua-like-syntax, so thats why Z is up and down in this. [editline]18th May 2012[/editline] Source engine isn't almost every game btw
[QUOTE=Map in a box;36011592]No it isn't. Y is up most of the time. But this is for glua-like-syntax, so thats why Z is up and down in this. [editline]18th May 2012[/editline] Source engine isn't almost every game btw[/QUOTE] Well that's weird, In both SAMP and MTA (GTA:SA Multiplayer) and some more games its that way :\
There are much less games that are X, Z, Y. It's the ~norm~ with OpenGL and I believe DirectX.
As far as I'm concerned, x,y,z is the logical one.
Only when thinking in terms of moving game assets about in the world. In terms of rendering x & y are x and y on your screen and z is depth into the screen. That said, I personally use map orientated coordinates and just transform them in the renderer but hey, it's Notch.
[QUOTE=Lexic;36013172]Only when thinking in terms of moving game assets about in the world. In terms of rendering x & y are x and y on your screen and z is depth into the screen. That said, I personally use map orientated coordinates and just transform them in the renderer but hey, it's Notch.[/QUOTE] Huh, I never thought about it that way.
Don't get me wrong, I'm very used to the concept of Z being up; Quake engine does this, Source (which is derived from quake) does, as does just about every game I've had the pleasure of reverse-engineering the map files for. It was simply the idea that a Minecraft modding platform would use a differing co-ordinate system that messed up my head.
The norm is still X Z Y for OpenGL though IIRC
[QUOTE=Lexic;36001669]The problem with script enforcement on an open source client is that cheaters can just compile their own version with it disabled.[/QUOTE] You can't compile LuaCraft on your own so we could implement it.. Anyway, I am back from 5 days of no internet, so prepare for updates! :D
Sorry, you need to Log In to post a reply to this thread.