Jump to content

holschuh

Members
  • Posts

    70
  • Joined

  • Last visited

Everything posted by holschuh

  1. HI, i workaround it by code making an pivot with the noise.lua script - save this also as prefab and load both and do setparent... self.enemy=Prefab:Load("Prefabs/cow2.pfb") self.step=Prefab:Load("Prefabs/cowsteps.pfb") self.step:SetParent(self.enemy) cu Volker
  2. Hi, i have an model with an child pivot which have an noise.lua script (source sound) attached. I save the model as prefab and when i load this by code the sound no longer plays. If i attach the prefab to an map manually sound plays... Is there an solution or workaround for. self.enemy=Prefab:Load("Prefabs/cow2.pfb") cu Volker
  3. Ahh found something Prefab.NoStartCall http://www.leadwerks.com/werkspace/topic/12523-load-prefab-pass-entity/page__hl__prefab cu Volker
  4. HI, i have an prefab entity with an script attached. so i want to load by lua code and set 2 "target" entity vars. but the Script:start() is in the moment i load the prefab running and wants to access my 2 "target" vars which are nil then. must i handle this by myself with some code or is there a way to prevent an Script in Prefab from running after loading it by code? the script loading the cow.pfb self.enemy=Prefab:[b]Load("Prefabs/cow.pfb")[/b] self.enemy.script.spawnpoint1=self.entity self.enemy.script.spawnpoint2=self.spawn2 the scrip in the cow.pfb Script.spawnpoint1 = nil--Entity "SP1" Script.spawnpoint2 = nil--Entity "SP2" function Script:Start() [b] self.xplus=self.spawnpoint2:GetPosition().x[/b] self.first=true .... cu Volker
  5. yep, but he is using c/c++ parts not pure lua in the indie LE Version. I read in the forum disabling the sandbox restriction allows lua libs to use but this cancels the steam publishing. cu Volker
  6. Hi, i know networking support is asked many times. But i ask me is it not possible to do out of the box simple things like an Access to an Highscore Server in Internet or make an simple 2 Player Game with round based communication in Leadwerks using the Indie Version of LE3.x? Or maybe an simple Http Acces JSON AJAX style? Speed is not so important in this cases. Scecond question: Can i workaround this calling an external app from LE lua to do communikation there and interface via Textfile with this app? os.execute / io.open maybe? cu Volker
  7. Hi, Naughty Aliens code is the way i did it by myself but i hoped the engine save some work for me... Josh's snippet did it for me was easy to include into my other stuff. i have to learn some matrix and Vector math like the normalize length and translate ... this can save many lines i break down at the moment to single integer math with many helper variables ... thanks all for help cu Volker
  8. this is an idea but i need it for a realy simple movement along x and z axis on same y Level with no barrier in the way.
  9. Hi, is there an simple Statement to move an entity from one vec3 to an other in steps ... means smoth not in one big jump. I think this is somethin in math but i am not good in Vector math... Have you an snippet for me or an kick into the right direction <-wordplay cu Volker
  10. Hi, what ist the Leadwerks way to animate an rolling car wheel. ist this an texture job or made with bones? anyone experience with this? cu Volker
  11. Hi, is there a way to put this filetypes in an Workshop ZIP without blocking from the Uploader? cu Volker
  12. HI, mine (sorry no AMD but i think it is also available) Pavilion x360 13-a200ng 33,8 cm (13,3 Zoll) Notebook (Intel Core-i3 5010U, 2,1GHz, 8GB RAM, 500GB SSHD, Intel HD, Win 8, Touchscreen) silber Graphics works better as with my R9 290 Card (beta driver) wich flickers Surfaces in the Edges of the Gamewindow. cu Volker
  13. Hi, today i had some time to look again over this..found the problem in the new beta you can go down into model...it is new or i havent seen bevore. the orientation of the head and gun flipped against the whole model. maybe helps someone also cu volker
  14. Hi macklebee, ohah you use "math" i can copy paste this but not understand in detail now the sphere was for debugging and because "point" with no target-entitiy dont work -i think. But you are right there are 2 sub objects from "hip" - "head" and sub of the head "Gun". Head should rotate to the mousepos but dont roll or kipple and the gun schould rotate up-down to exact heigt of mousepos. head rotate around y and gun top down to exact mouse positon in 3d space. - like an tank in reallife overall i think i can also try making 3 models and do parenting in Leadwerks not in modeller..maybe that works for me. I saw an unity vid doing an tank and working with the submodel origins pos for rotation this is my try to make same in LE... thanks now i have some new ideas cu volker
  15. HI, Is there a Trick to get Point and aligntovector to work with an "child" Object of an model? point seems to invert the rotation and alighnto seems inverse but not totally the pickpos With the whole model all works fine but not with an child... I think about to make an hidden dummy entity to steal rotationfor the child of the Main Model but i hope there is an other way feeling more right? self.entity:Point(self.Psphere,2,Time:GetSpeed()*0.1) --self.entity:AlignToVector(self.Psphere.position,2) --child:Point(self.Psphere,2,Time:GetSpeed()*0.1) --child:AlignToVector(self.Psphere.position,2) Script.cam = nil--Entity "Target" Script.Speed=1.0--float Script.Sequence=0--int function Script:Draw() --local t = Time:GetCurrent() --self.entity:SetAnimationFrame(t/100.0*self.Speed,1,self.Sequence) end function Script:Start() self.currentyrotation = self.entity:GetRotation().y self.Psphere = Model:Sphere() self.Psphere:SetScale(1.04, 1.04, 1.04); self.Psphere:SetCollisionType(0); self.Psphere:SetColor(1.0,0.0,0.0) self.Psphere:SetPickMode(0) end function Script:UpdateWorld() local window = Window:GetCurrent() local mouseposition = window:GetMousePosition() local child=self.entity:FindChild("Head") local child2=self.entity:FindChild("Gun") local pickinfo = PickInfo() --local t = Time:GetCurrent() --self.entity:SetAnimationFrame(t/100.0*self.Speed,1,self.Sequence) if (self.cam:Pick(mouseposition.x,mouseposition.y,pickinfo,0.1,true)) then if window:MouseHit(1)==true then self.Psphere:SetPosition(pickinfo.position) end end self.entity:Point(self.Psphere,2,Time:GetSpeed()*0.1) --self.entity:AlignToVector(self.Psphere.position,2) --child:Point(self.Psphere,2,Time:GetSpeed()*0.1) --child:AlignToVector(self.Psphere.position,2) end function Script:UpdatePhysics() local window = Window:GetCurrent() --Detect Key hits local move = ((window:KeyDown(Key.W) and 1 or 0) - (window:KeyDown(Key.S) and 1 or 0)) local yrotation = ((window:KeyDown(Key.D)and 1 or 0) - (window:KeyDown(Key.A) and 1 or 0)) --Increment y rotation self.currentyrotation = self.currentyrotation + yrotation self.entity:SetInput(self.currentyrotation,move*8,0) end cu Volker
  16. Hi, i searched but found no post or something. the examples lua/c++ no longer available in the command reference? cu Volker
  17. Hi, i did this also in 3d coat but the autotopo makes not an realy low poly(most crashs) and manual retopo is a lot lot time consuming... so i use also silo 2, hexagon because of more control over the amount of faces the model have. painting is possible with 3d coat but most time you press ctrl-z because it make not what you want.(like blender).. i tryed substance painter indie short but the licence and the learning curve makes me not so happy. the PBR crusade is not in my focus yet because i waste my time at the moment with the color map... maybe i am an lousely painter uses someone maya, mari, carrara, bodypaint from cinema4d or some other stuff ? cu Volker
  18. Hi, cant Import faces with more than 4 Corners ís the message in sculptris. cu Volker
  19. Hi, @ Olby: Yes, but try to import some obj to paint them .... you will get most an error because of the restrictions sculptris has as an sculpting programm. @ casssius: I have serveral proggs but not tryed all in deep, my interrest is do it someone with gimp or photoshop in an productive time or is there an easy not overloaded tool doing this in one peace. I have most of the Steamstuff and use for uv'ing most uunwrap 3d Coat full, Modo indie, SubstancePainter indie, silo2, Mindtex, curvy 3d cu Volker
  20. Hi, how do you paint your 3D models. I tryed some tools but all is pain and consuming much time. cu Volker
  21. yes camera rotation always same direction - not rotating to be behind the tank if the tank rotate. and yes if i move the mouse in the upper right corner of themonitor the gun should target this position.. at the moment i modified some lines from the fps character controller but so the turret rotates not precisely and only moving mouse left ... right of the screen ignorring top--down maybe setrotation is the false decision for this problem function Script:Start() self.currentyrotation = self.entity:GetRotation().y end function Script:UpdateWorld() local rot = self.entity:GetRotation(true) local window = Window:GetCurrent() local gy = window:GetWidth()/2 local mouseposition = window:GetMousePosition() local child=self.entity:FindChild("Head") local dx = mouseposition.x-gy rot.y = rot.y + dx / 5 --look left and right child:SetRotation(0,rot.y,0,true) end function Script:UpdatePhysics() local window = Window:GetCurrent() --Detect Key hits local move = ((window:KeyDown(Key.S) and 1 or 0) - (window:KeyDown(Key.W) and 1 or 0)) local yrotation = ((window:KeyDown(Key.D)and 1 or 0) - (window:KeyDown(Key.A) and 1 or 0)) --Increment y rotation self.currentyrotation = self.currentyrotation + yrotation self.entity:SetInput(self.currentyrotation,move,0) end cu Volker
  22. hi rick, the goal is: the camera moves over the ground (with an angle) having the player as parent and following him ... the player is an tank moving around with "wasd" or something. the tank has an gun wich faces always the mousecursor position, left click firing and s.o... cu Volker
  23. hi beo6, i think Window::GetMousePosition dont give an vec3 wich is usable in Entity::AlignToVector z is the mouse wheel and x y are the 3rd person camera view 2d coordinates - these must translated to the map-ground 3d coordinates i think but i dont know how... the other functions need an entity as target - i have only the mousecursor as target of the rotation. cu Volker
  24. Hi, is there an easy way to get the rotation from an Entity to the mousecursor? (like an Tank cannon) setting the rotation is with getchild + setrotation easy but how do i get an value for the rotation to the mouse with an 3rd person camera? the yellow sphere is the mousecursor in picture... cu Volker
×
×
  • Create New...