Jump to content

acd009

Members
  • Posts

    12
  • Joined

  • Last visited

Posts posted by acd009

  1. I have edited the gun and player script to aim down sight and have gotten it to work.

    Now the next thing to do is to make the scatter decrease. i have created a partial code which i want to set the scatter to what i set it to be.

    Here is the Code

    function Script:UpdateWorld()
       if self.ADSmode == false then
       self.camera:SetFOV(70)
    
       self.weapons[self.currentweaponindex].offset = self.weapons[self.currentweaponindex].offsetNor
    end
    if self.ADSmode == true then
       [u]self.scatter = self.scatterADS[/u]
       self.weapons[self.currentweaponindex].offset = self.weapons[self.currentweaponindex].offsetADS
       self.camera:SetFOV(30)
    end
    

    ScatterADS is a copy of Scatter that is setable(to change the scatter when aim down sights)

    this code is not working. I just uploaded a version of the code without the scatterADS. Link-http://www.leadwerks.com/werkspace/files/file/576-aim-down-sights/

    Why does this not work

  2. In my game I have logs (are collected from trees) and I have the same script that allows you to pick up barrels in the tutorial maps attached that makes them able to be picked up and I need that script so you can build shelters.

    How could I make the logs have two scripts. I tried using pivots but it doesnt work.

  3. I have have been trying make a object in my game switch its mass to 0 when i hit a button.

    I am very new to leadwerks and dont know much about scripting but the very basics.

    I found a script for doing this on one of aggor/ricks forums and for some reason it redirects me to a page that says sorry can not find that file. Did he remove the file or is there just something wrong with the page?

×
×
  • Create New...