Einlander
-
Posts
778 -
Joined
-
Last visited
Content Type
Blogs
Forums
Store
Gallery
Videos
Posts posted by Einlander
-
-
I'll post the project files when I get some time. The occlusion is set to off on all objects. All objects shadows are set to static, and the 1 directional light is set to static shadows.
-
Lol, totally forgot that was playing Aggor, its an old time radio mystery show, Nero Wolfe.
Josh that brings up another issue, my performance in leadwerks has dropped drastically since the last few updates. Also on my new graphics card its astonishingly slow. From 60 -150 on an hd7770 to 20 -58 with an r7 260x. This weekend I will check to see if my old card still outperform my new ones.
-
While testing one of my maps I found that Leadwerks was not keeping pace with the camera in certain areas. I was able to replicate the bug with a flat cube for the fps player to stand on, and a small box sized cube. Just walk away and quickly turn around and the cube will not be there for a few frames.
video https://mega.co.nz/#!8Ak1lYBR!jnuBGoRTbRhjSWc43Dw5D_vVvHTo-iWywIsRSX0JnPM
-
We should probably port the documentation to the wiki , fill in the blanks, and add some commands that are not in the documentation like the buffer class.
-
I changed from dual 7770s to dual r7 260x's and my gfx performance has suffered in leadwerks. Its fine everywhere else. Also leadwerks will tend to stutter when a light goes into the view frustum, whether or not you see it. So I can make a room of lights and be a distance from it and not looking at it. When I turn around and look at the lights, I ca see in the debug screen that the lights are then being loaded for the first time. Over the next few months I think there will be some optimizations as the feature set gets finalized.
- 1
-
Would setting the friction to 0 do anything? http://www.leadwerks.com/werkspace/page/documentation/_/command-reference/entity/entitysetfriction-r142
-
Here us a free open source procedural texture generator that has a library that does almost the same thing as Substance Engine. Only downside is its written in java.
- 1
-
Think demoscene Yougroove. They are using the engine to at runtime, generate the textures. There would be no texture files to load because it would be generated on the fly. It would save space on a players hdd and and band with for the developer because the texture only exists as instructions. It is completely possible for people who are familiar with image processing to do this now in leadwerks now with the Textures class.
-
Its especially noticeable in levels that have alot of textures. You see the screen flash once, then disappear and then watch as the script window lists all the textures its loading.
- 1
-
You can do dll binding directly from lua using the luajit library (you're going to have to google that). It's already built into Leadwerks. Its a bit round about, but its possible. My adventures with leadwerks, lua and dll's: http://www.leadwerks.com/werkspace/blog/120/entry-1182-luajit-awesome-luajit-enet-loaded/
-
You could always compile the lua code to byte code. Also you can have the password in a dll/lib and use luajit to load it. There are ways to obfuscate code in lua. It will stop the casual hacker. A determined hacker will get regardless. Plus it gives people a simple way to distribute dlc/download packs outside of steam, Ie:desura and distribute a key for the zip.
-
Can this be used from lua?
-
Just came across this youtube tutorial for tree[d] and how to get a less than 1000 polygon count tree.
-
4. is there a possibility of OnColliderEnter or OnCollisionEnter like in unity or would I have to implement that my self somehow?
You would have to Impliment them. But i just did this yesterday. http://www.leadwerks.com/werkspace/blog/120/entry-1186-ladders-are-evil-ugh/
The code is here http://www.leadwerks.com/werkspace/blog/120/entry-1186-ladders-are-evil-ugh/#comment_5104
- 1
-
There might be an option in the settings on 3ds max, I don't know where as I dont use it. I know when you export from 3dCoat, one of the first options is 'swap y for z', which essentially makes whatever you modeled look like it was lying down.
-
Or in the settings, or at save time it asks to zero the origin
-
That annoys me too. All the models packs I made I had to position them at 0,0,0 before I save a prefab. Don't get me started with using a csg as a shape mesh, they don't perfectly align when you do that.
-
The script you have, when a collision enters,exits and stays it reports an event happens. By indiscriminately I mean that it doesn't take account of which entity entered, or which entity exited. With that script, it doesn't say which entity entered, or which exited. I want the collision script to be able to affect other entities. For example, When an entity enters, set its gravity state off, then when it leaves turn it back on. That script will only know its holding something, not what or how many.
Don't worry, I wrote this post after spending an all nighter. I'm writing this post while at work as fast as possible, so I dont know if I'm communicating my idea properly.
-
True, but that one indiscriminately report when itself has been entered and exited. I need the script to report which entity has exited. I would like the on exit to be able to report the same information the collision event does. Which entity left, and optionally, position and speed
-
Can a mod move this to the programming section?
Is there a way to progamatically get a list of entities that are currently colliding with an object? I would like to be able to get a a list of all the unique entities in a collision trigger then compare it later. For example, a person walks into a room, then leaves. I want to be able to detect when a person leaves the area.
I have been partially able to solve some of my needs.
--[[ This script will make any entity act as a collision trigger. It works best when you set the entity's collision type to "Trigger". This will continuously detect collisions without causing any physical reaction. --This Has been modified to behave more like the Source Engine/Unity Collision Triggers ]]-- function Script:Start() --Create a table to keep track of all entitys that are interacting with the collision trigger self.CollisionEntites = {} end function Script:Collision(entity, position, normal, speed) --[[ We are going to keep track of 3 things: [Done] When an entity ENTERS the collision trigger [Done] When an entity is IN the collision trigger [] When an entity EXITS the collision trigger ]]-- --When an entity ENTERS the collision trigger if (self.CollisionEntites[entity] )== nil then -- Check table, is the entity already in it? -- No? --check if its in the list local matchfound = false if matchfound == false then for itemnum,value in ipairs(self.CollisionEntites) do if entity == value then matchfound=true end end table.insert(self.CollisionEntites,entity) --add entity to list of objects currenty in the collision trigger if matchfound == false then self:CollisionOnEnter(entity, position, normal, speed) -- Raise CollisionOnEnter event end end -- yes? Call the CollisionOnStay Event self:CollisionOnStay(entity, position, normal, speed) end end function Script:CollisionOnEnter(entity, position, normal, speed) self.component:CallOutputs("CollisionOnEnter") end function Script:CollisionOnStay(entity, position, normal, speed) self.component:CallOutputs("CollisionOnStay") end
I can tell when an entity enters, and stays inside. But not when it leaves.
-
My question is why so many polygons? The picture of the building with the fire escape has 11k tris, and your scenes are rendering in excess of 40k polys, and if you used 3dcoat which likes to turn everything to quads, it reveals your models are pushing almost double to triple the polycount reported by leadwerks.
In that one scene of yours, you can fit 4 of those ENTIRE buildings or 1 20 story building with polygons to spare.
Now we can do 2 things, 1 would be to lower the poly count, or 2 aggressive occlusion culling. There is no reason to be pushing that many polygons for 2 buildings.
-
I just wrote a blog post about this topic: http://www.leadwerks.com/werkspace/blog/120/entry-1184-key-configs-and-tedium/
Example: http://www.leadwerks.com/werkspace/files/file/515-key-config-host/
-
Some free tree generators:
tree[D]: http://www.frecle.net/?show=treed.about
arbaro: http://arbaro.sourceforge.net/
they both export to obj.
-
I have a model that has multiple parts to it. In the model editor I drag a material to model to apply the material, but there are some parts that I can not apply the material to no matter how close I zoom in.
my request is to also be able to drag the material onto the name of the object to apply it.
- 1
How to pass variables between scripts? (Lua)
in Programming
Posted · Edited by Einlander
Does thus all have to be automatic? Do the scripts have to be able to detect another scripts presence is, does the collision script need to find the text script? Or do you want to be able use the editor to attach the scripts together? Or do you want to use the flow graph? There are at least 3 different ways to pass values to other scripts.EDIT:On my phone so didn't see the second page, ignore the above text if you want. I'll give it a try when I get home in a few hours.