Jump to content

macklebee

Members
  • Posts

    3,946
  • Joined

  • Last visited

Everything posted by macklebee

  1. i think they are just referring to the fact that the ambient light inside should be different than the ambient light needed outside...
  2. glad to help... agree that the grass should work without a basemap or with one... i personally like using a basemap with the blend adjusted on each of the terrain textures as it gives the terrain a more interesting texture...
  3. The framework source is open to everyone with the SDK... look inside the SDK's BMX/framework folder for the files in question...
  4. The Vegetation option in the Terrain settings has a dropdown list for picking whether or not you want shadows with your vegetation... this has nothing to do with the model having a script or not. My guess is that you need to make the Editor window larger by grabbing the lower right hand and dragging down because the default size will cut some of the features off...
  5. for the trees' shadow select 'Always' from the Cast Shadows drop-down list... and for the grass, select a basemap texture...
  6. when you run the code, do you get the effect that you are wanting? just curious, because that is not the frag shader used with the inherent DOF command? But in any case, I would assume the warnings are from when you load the shader, those uniforms at that moment are not presently set.
  7. then i would guess you need to copy the oak tree over to the sdk folder...
  8. huh? i do not follow... everything looks the same to me...
  9. yeah i cannot speak for c++... but in any case, a 5 minute search for GetMeshModel led me to find it in two places for c++. One is gamelib and the other is Chris Paulson's code that he submitted in the download section... Here is Chris' usage as found here http://www.leadwerks.com/werkspace/topic/1162-why-a-bullet-object/page__view__findpost__p__10810: void Bullet::builtHitForce( TPick& pick ) { TBody body; body = GetMeshModel( pick.entity ); if(body) { AddBodyForceAtPoint( body, Vec3(m_direction.X * m_force, m_direction.Y*m_force, m_direction.Z*m_force), Vec3(pick.X,pick.Y,pick.Z) ); // SendEntityMessage( topParent(pick.entity), "bullethit", body, 0 ); TEntity e = pick.entity; BulletHit *hit = new BulletHit; hit->m_direction = m_direction; hit->m_force = m_force; hit->m_origin = m_origin; hit->m_speed = m_speed; hit->m_pick = pick; while (e) { SendEntityMessage( e, "bullethit", (byte*)hit, 0 ); e = GetParent(e); } } } and here is his GetMeshModel code: TBody GetMeshModel(TEntity entity) { std::string classname; while (entity!=0) { classname=GetEntityKey(entity,"class"); if (classname=="Model") { return entity; } entity=GetParent(entity); } return 0; }
  10. if that is an animated character you must use the skin shader and not just on the shadow shader: Animation Material try this: texture0="abstract::zombie0.dds" shader="abstract::mesh_skin.vert","abstract::mesh_diffuse.frag" shadowshader="abstract::mesh_shadow_skin.vert"
  11. a model is nothing more than a container for the body and the child mesh and possibly an included script... but look at these links for examples: Entity Pick and Entity/Body conversion problem
  12. well you should be able to get the body/model of a picked mesh by finding the parent of that mesh...
  13. Look at the sections concerning blending and split animations: Introduction to Animation
  14. nevermind... need to use the new LOD command... require("scripts/class") local class=CreateClass(...) function class:CreateObject(model) local object=self.super:CreateObject(model) local lodCount = CountModelLODEntities(model) for lod = 0, lodCount-1 do sequence = LoadAnimation(GetModelLODEntity(model, lod),"abstract::run.gmf") Print("Length of animation: "..AnimationLength(GetModelLODEntity(model,lod),sequence)) end end
  15. What am I not understanding here? The animation loads and I can animate the character with it, but i am unable to pull the length of the animation. i assume I am missing some fine detail in its usage? require("scripts/class") local class=CreateClass(...) function class:CreateObject(model) local object=self.super:CreateObject(model) local lodCount = CountModelLODEntities(model) for LODEntity = 0, lodCount-1 do sequence = LoadAnimation(GetModelLODEntity(model, LODEntity),"abstract::run.gmf") Print("Length of animation: "..AnimationLength(model,sequence)) end end Always prints the length as zero...
  16. this was supposedly a bug fix... granted I really do not see a change on my end... http://www.leadwerks.com/werkspace/tracker/issue-190-terrain-basemap-not-correctly-effecting-vegetaion-color/
  17. Also, for those who want to see the new commands in action - I have updated Masterxilo's soldier script to include the change from 'object:Render()' to 'object:Draw()' and the new LE2.5 LOD commands shown above. The soldier.lua script is the only thing changed. The soldierGame.lua gamescript still is the same. soldier.lua
  18. If you are just looking to retrieve the object model's assigned name, then you have to wait for it to be set after creation of the object. This template object script will show basically the order in which the automatic object functions get called: test_template.zip Note that the GetKey function is called repeatedly while the model is selected, so just place the model into the scene then click off of it to unselect it, then look at the console log to see the order of the functions. As for retrieving the object model's assigned name, try this: require("scripts/class") local class=CreateClass(...) function class:CreateObject(model) local object=self.super:CreateObject(model) function object:UnlockKeys() AppLog("name of object: "..self.model:GetKey("name")) end function object:Free() self.super:Free() end end Also, just to point it out, but you are posting in the Leadwerks3D forum, an engine that has not been released yet. Your lua programming topics should be posted here: LE2 Lua
  19. do you own blitzmax? or is it just a trial version because i do not know if the trial version of bmax allows you to use 3rd party modules... other than that the only thing i can think of is that the modules are not in the correct place? no there is no initialize.
  20. post the code you are trying to use... because framewErk no longer exists... there is only framewOrk.
  21. LE2: COLLISION_NONE=0 COLLISION_PROP=1 COLLISION_SCENE=2 COLLISION_CHARACTER=3 COLLISION_TRIGGER=4 COLLISION_AILINEOFSIGHT=5 ok understand about debris... but does that mean we can expect breakable objects inherent within LE? As for the PROP, isn't it missing a collision response for scene and other props?
  22. what would you consider the difference between a PROP and DEBRIS? in LE2.X, a PROP is anything basically other than a scene or character and would collide with a scene or character or another prop... here you are showing the default for a PROP only collides with a character but not a scene or prop? Has DEBRIS replaced PROP? but yet DEBRIS will not collide with other DEBRIS? ugh... you changed the constant values... thats going to get me a couple of times in the future i just know it!
  23. if an entity has no parent, then local = global... fyi...
  24. you need to check the value of FrameBegin5 at the beginning of the function... is it sometimes already greater than the FrameEnd5 variable? a simple Print statement should help you troubleshoot.
×
×
  • Create New...