Jump to content

mdgunn

Members
  • Posts

    626
  • Joined

  • Last visited

Everything posted by mdgunn

  1. Does anybody know how to tweak the cloud direction? THey are coming towards and right to left in my standard setup and I really want them to come left to right ( and probably towards a little bit). I see how you can change the way the sky moves and the speed but the clouds themselves seem separate and I'd like to control them so they match the way I'm making the wind blow in the level (puffs of dust etc.). It seems a bit odd when the sky doesn't match the direction the ground wind seems to be blowwing. I COULD change my level so my wind effects match the the sky but matching the SKY to the LEVEL seems the logical way to me. I've had a look through the related lua and shader files and tried changing various values (guessing incorrectly every time) and I've never worked out which one I need to change. SO, anybody worked out how to change the cloud direction?
  2. I had the firepit working a couple of days ago and it seemed fine. Are you maybe trying to import it from a folder that is in a different project? I'm not sure if that actually is a problem but I've got a feeling I might have had an issue where i saw something similar. I would check the steam workshop dialog in the editor and see if it says Install or Uninstall. If it says installed I would still do an uninstall and install again and see if that sorts it.
  3. Yeah the CSG 'trigger' cubes and manual intervention in the movement is the direction I was heading when I wondered if I was heading the right way, so it's reassuring that you seem to think it's a doable solution. Thanks for the extra pointers. I felt sure someone had probably done a 'cube pusher' but so far someone that has completed such an implementation doesn't seem to have passed by yet. Thanks for the help.
  4. The animation shader works on a tree OK though in my test movement was very small. Do we need to use the specific shadow shader? If I select the vegetation shadow shader in the download then it doesn't seem to respect alpha but if I use the standard shadow shader that includes alpha then the leaf shadows don't seem to move at all (at leat to me). Do others see shadows moving? If yes what did you get to make the shadows move AND use alpha mask? Just checked again and the veg shader doesn't seem to have the nice appearance of the diffuse+normal+specular+alphamask. Have others got it looking great? Thanks
  5. I've hacked away at the sliding door script to create a script that moves the attatched object away as you bump into it (well you actually bump into a trigger collider currently) Problem is, it will only do it twice then stop. I think maybe the slider joint is not actually resetting when I am trying to reset it and has reached it's limit so not resetting properly. I am trying to reset it each time a move completes but I think I don't understand either how the slider works, or the vector information it needs to alter it's position or something. Can anyone take a look at the associated map and script and point out the probably obvious error? NOTE: The script is a real hack job and not meant to be complete so please forgive the mess! Here is a Dropbox link which I hope works OK. Unsure if I can link a file to this post. https://www.dropbox.com/s/3ctogtsxjf239qh/PushAwayJoint.zip?dl=0 (contains map, script and screenshot) If there's a better way to supply a package then please let me know. Maybe I should try another way altogether? Thanks, Michael
  6. Thanks Josh, I had considered a joint slider. I checked out the docs and can see it is designed to limit movement in 1 direction but I wasn't sure if it was the best way to go for controlling crate movement in more than one axis. Sounds like I would still need to detect which way I'm trying to push and then setup (or disable) slider joints to allow me to push only in the direction I'm trying. I will take a deeper look. Cheers
  7. Q: What's the best way to push objects (like a crate) around and have them lock to fixed directions? E.g Push a 'crate' an undetermined distance along a path/paths but only allow it to move in fixed directions either 1 axis as if on a track or 2 axis ( e.g. 'crate' pushing puzzle). I have something working (see below) but I don't think it's the best way to go. Are there any example maps/code of pushing a crate around fixed tracks on a level. It seems like the sort of thing someone must have done but I've yet to see any examples. The problem seems to break down like this: 1) Have an object to apply forces to (the 'crate') with a script to detect collision. 2) Detect the direction of push - currently faking this with 'trigger boxes' on the side. Maybe I need some trigonometry or something to work out the side of impact between the bodies? 3) Apply a force to the object limiting it's effect to a single axis (perhaps something in PhysicsUpdate?) At the minute I have a working example where I can push a box in 1 direction using an invisible trigger box sticking out of it on the side I want the player to push from but I think this is probably not the best way to do it and am looking for someone who knows better! function Script:Collision(entity, position, normal, speed) -- System:Print("Collision speed = "..speed) -- Speed will be zero if 'trigger box' is a trigger as it needs mass 0 to avoid dropping down through floor/level. -- if speed>self.threshhold then if self.entity:GetParent() ~= nil then local parent = self.entity:GetParent() parent:AddForce(0,0,200,true) end -- end end Thanks, Michael
  8. Sorry for the late replay guys, I didn't see these updates. These suggestions could both help me out so thanks for the input.
  9. I think you've probably just become Josh's new best friend!
  10. Thanks for the response Einlander. I think that informaiton will save me a lot of time. Can implementing your own controller be done fully from Lua? Do you say implement new one because the amount of changes needed in FPSPlayer would not be worth messing about with and better to build up from scratch as exactly what needed for my specifics? Thanks, Michael
  11. Thanks for the response.... OK, well I tried rotating the camera to sort of fake it, and got that to hold values OK but the controls were the wrong way round (as you'd expect). I considered flipping them but at this point it felt like faking it might throw up more problems than just getting the player to rotate properly so I pursued (without success) what seemed the more sensible option of trying to rotate the player instead. Maybe I can get some answers from Josh on this. I'll see what happens, Thanks, Michael
  12. This seemed like it would be essentially a fairly simple thing to do but I can't get it to work yet. Maybe someone can tell me this is just a non-starter idea and to stop right now! I considered rotating the whole map and plonking the player back down again (hiding the transition) but ideally I'd like the player to do it for real. Anyway in pursuing the normal option of not rotating the map I have so far got gravity reversing OK but I can't get the player to turn around so they are actually upside down. I tried to set a rotation on the player entity Z axis but is seems to get wiped out after I set it. I guess it is later computed by something else in the normal course of things and my changes are lost. Here is my function which when called seems to set a rotation but then later lose it when I print out player rotation values in UpdateWorld() of FPSPlayer. Can anyone tell me what I need to do instead? function Script:FlipPlayer()--in if self.entity:GetKeyValue("inverted","false") == "false" then -- Get Current rotation playerRotation = self.entity:GetRotation() if playerRotation ~= nil then local rotx = playerRotation.x local roty = playerRotation.y -- rotate the player to be upside down local rotz = playerRotation.z + 180 self.entity:SetRotation(Vec3(rotx, roty, rotz)) -- Check our update held by printing it out again local newRot = self.entity:GetRotation(true) System:Print("-new playerRotation rotx="..newRot.x) System:Print("-new playerRotation roty="..newRot.y) System:Print("-new playerRotation rotz="..newRot.z) self.entity:SetKeyValue("inverted","true") self.component:CallOutputs("OnFlip") end end end
  13. This is the bit I don't yet understand so can someone please supply the syntax for what the function signature looks like when in Main.lua and also the specific syntax to call it from an entity. Thanks, Michael
  14. Thanks for the warning macklebee. Luckily I am triggering in game and I seem to have got it working OK, though as I mentioned I went with globals though I'd prefer to call a function (on Main.lua) but I think I don't have clear understanding of if I can do this on Main.lua. Anyway working for now. Thanks, Michael
  15. @Genebris I went with using a global. Personally GLOBALS make me a bit scared. I'd prefer to call a function but I still undertand how you call a function on Main.lua from an entity (or if you can). Anyone know if you can, of are you supposed to go back to the App.lua way to do it? If anyone stumbles accross this later this is how I got gravity change trigger working I added this into Main.lua --Handle Y Gravity change if changeYGravity~=nil then --System:Print("changegravity = "..tostring(changeYGravity)) world:SetGravity(0,changeYGravity,0) changeYGravity = nil end And I created a script called TriggerGravityChange.lua like this (modified from map change one - you may need to change it to your needs). --[[ This script will act as a trigger to change the gravity. This is currently triggered by a collision but you may want to have it triggered by some other means. ]]-- -- positive number for Y gravity are UP! Script.YGravity=10--int "Y Gravity" Script.gravityChanged = false function Script:Start() self.enabled=true end function Script:Collision(entity, position, normal, speed) if self.gravityChanged~= true then --System:Print("Change Gravity - new value = "..self.YGravity) changeYGravity=self.YGravity self.gravityChanged= true end end function Script:Enable()--in if self.enabled==false then self.enabled=true self:CallOutputs("Enable") end end function Script:Disable()--in if self.enabled then self.enabled=false self:CallOutputs("Disable") end end
  16. But that would not allow be triggering it in game would it (unless I'm missing what you mean)?
  17. I want to change gravity for the world (SetGravity(x,y,x)) by triggering it from an object entity but how do I access the world object created in Main.lua? Or is there a different way to do this? Can you add functions to Main.lua that you then call from other entities? I'm confused about the change to Main.lua and how it compares to how things used to be with App.lua. Is there a post somewhere that went through the change to Main.lua? Thanks, Michael Gunn
  18. Well I seem to have left it till the last minute again and found only a single day to get this game done. Turned out to be more of a prototype than a full game. Modification of the Leadwerks marble game sample. http://www.leadwerks.com/werkspace/page/games/_/u-rev-r103 Single level. Collect the 10 energy spheres in the shortest time. Needs more work, but out of time.
  19. mdgunn

    3.4 Recap and Beyond

    Would agree a store is probably necessary (see FPS Creator Reloaded/Construct 2/Game maker as well as Unity etc.). For beginners I found Jorn's YouTube tutorials were essential for me to get up to speed in an applied but modular fashion. I think construct 2 and their web site get a lot of things right for getting started and building community and resources. (You're probably not meant to mention other software but this is 2D and it seems relevant to point it out specifically). An easy way for LW to help new users is a nice attractive splash/start page like construct 2 has. It isn't a splash as such because it doesn't go away and is actually useful. The page actually stays open all the time in a tab (which fits their tabbed interface fine). You can disable it in configuration. There's loads of useful stuff on there. - 2 'full' game projects (with tuts to follow) - Many real world useful skeleton templates (endless runner etc.). - Links to manual, tutorials, forums and store - You Tube FB etc. - Friendly 'Plain English' *sentence* re-iterating same info above it. Importantly the graphic and presentation are nice enough and readable enough that I don't feel compelled to turn this of and it is still a convenient place to do whatever task you want to do on program start (new/open/recent projects). If a program is aimed at beginners or users that want approachable software then the start UI can probably be more inviting than a traditional and typical windows software. They also provide a resource pack (as LW does) which isn't mentioned in here but seems well signposted on the web site I think . I get a strong impression from construct (Scirra) that they have done usability testing, and acted upon it.
  20. Looking good. Like the minimal look.
  21. Haven't yet worked out how to modify my listing for my game so here are a few images so you can see what it looks like.... I'm thinking it probably looks better when it is moving.... EDIT: I worked out how to get edit my game listing..yipeeee!
  22. A few days ago (last minute as usual) I thought I'd try and do an entry for the Leadwerks Winter Game Competition Entry. I hadn't created ANY games up to that point having just bought the software so didn't initially think I'd get anything playable done but I had a few ideas and the result is.... 'Crazy Auto Present Dash' !!!! Yeah. I'm not too pleased with the name but it'll do. I'm still trying to get it uploaded to the site while I write this. A number of issues to resolve so it's more of a Beta (maybe Alpha ), but the basic game is there. My aim was just to complete a game that could be played (at all) - by me, so I think so far I've achieved my goal!
  23. I tried again and it seemed to go better this time. I seem to be able to export cycles based UV mapped image materials and the PNGs appear now. No idea why I had the problem before yet. Probably some material setting that I'm not spotting. Thanks, Michael
  24. So do you mean that any materials defined as cycles materials should be baked and then re-created as old-style Blender texture OR should the exporter export a cycles material if it is correctly baked? My simple example was just a UV map image (png). It exported the material but it lacked a path to the image and I don't know if this is because it was not defined right as a cycles material or because cycles materials CAN'T be exported even if they are just a PNG texture (which seems to me similar to a baked texture?). I was in Blender 2.72 BTW to try to make sure 2.73 RC was not an issue. I'm by no means an expert Blender user so I find it easy to get confused in the pipeline necessary here. If the plug-in needs old-style Blender render then I think that point is important enough to be in the docs. Thanks for responding. Hopefully someone can clarify a little more on if I HAVE to always bring everything back to a old-style Blender material to work. Cheers, Michael
  25. Can anyone explain how to get a texture out with cycles renderer? I can get the png files generating if I use Blenders old Render but when I try to use cycles the image file doesn't appear but the mat file does (with no image file reference). I don't know if it is because I don't know how to do it, or if you have to use the old render materials? Materials look fine with cycles in the viewport (as far as I can tell). Can anyone explain using export with cycles materials? Thanks, Michael
×
×
  • Create New...