-
Posts
70 -
Joined
-
Last visited
Content Type
Blogs
Forums
Store
Gallery
Videos
Downloads
Everything posted by holschuh
-
Ahh found something Prefab.NoStartCall http://www.leadwerks.com/werkspace/topic/12523-load-prefab-pass-entity/page__hl__prefab cu Volker
-
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
-
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
-
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
-
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
-
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
-
Hi, is there a way to put this filetypes in an Workshop ZIP without blocking from the Uploader? cu Volker
-
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
-
3rd person camera :rotate an model part to mousepos in Lua
holschuh replied to holschuh's topic in Programming
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 -
3rd person camera :rotate an model part to mousepos in Lua
holschuh replied to holschuh's topic in Programming
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 -
3rd person camera :rotate an model part to mousepos in Lua
holschuh replied to holschuh's topic in Programming
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 -
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
-
Hi, cant Import faces with more than 4 Corners ís the message in sculptris. cu Volker
-
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
-
Hi, how do you paint your 3D models. I tryed some tools but all is pain and consuming much time. cu Volker
-
3rd person camera :rotate an model part to mousepos in Lua
holschuh replied to holschuh's topic in Programming
sounds both nice i try that thanks -
3rd person camera :rotate an model part to mousepos in Lua
holschuh replied to holschuh's topic in Programming
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 -
3rd person camera :rotate an model part to mousepos in Lua
holschuh replied to holschuh's topic in Programming
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 -
3rd person camera :rotate an model part to mousepos in Lua
holschuh replied to holschuh's topic in Programming
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 -
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
-
Hi, maybe same i run in. http://www.leadwerks.com/werkspace/topic/12255-fbx-imported-animation-working-as-intended/
- 1 reply
-
- Import Model
- 3Ds Max
-
(and 1 more)
Tagged with:
-
Hexagon If you can handle the frozen development and the less stability it can do hell things for around 20 bucks. (https://www.daz3d.com/hexagon-2-5-download-version) I thing it is an good entrance in 3d because all options reachable by mouse :*)
-
Hi, that is the Video i mean... Thanks i try around implementing yor code. cu Volker