Jump to content

Search the Community

Showing results for tags 'timer'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Blogs

  • Development Blog
  • Canardian's Blog
  • Beyond Civilization Blog Ext
  • Tyler's Blog
  • macklebee's Blog
  • B-Byrnes' Blog
  • Marleys Ghost's Blog
  • omid3098's Blog
  • Richardsimpo123456's Blog
  • DJDD's Blog
  • Rick's Blog
  • --
  • xtreampb's Blog
  • Economically Disadvantaged
  • klepto2's Blog
  • Old Blog
  • Chris Paulson's Blog
  • Davaris' Blog
  • nil
  • Rekindled Phoenix's Blog
  • Flexman's Blog
  • Kattemaksu Online
  • Marcousik's Creations Blog
  • EVE LBS Studio
  • Rendering puzzles
  • Screen Size Utility
  • Niosop's Blog
  • 1299 RTS Game Project
  • Blitzbat's Blog
  • gordonramp's Blog
  • Andy Gilbert's Blog
  • Marcus' Blog
  • JornAggror Blog
  • diedir's Blog
  • wayneg's Blog
  • Masterxilo's Blog
  • Dave Lee's Blog
  • peubuy's blog
  • OD Arts -Leadwerks Blog
  • The progression......
  • Ultra Software Company Blog
  • The Progression
  • Pancake's Blog
  • Test Blog
  • BLaBZ Blog
  • Pure³d's Blog
  • dreamhead Blog
  • RVL's Blog
  • DB's Blog
  • Toxin Games Development Blog
  • CombatHelo Blog (RSS Import)
  • Foolish's Blog
  • ZioRed's Corner
  • Toxin Games Twitter
  • Shard - Third Initiative
  • Shard's Blog
  • Soamp's Blog
  • Soamp's Blog
  • Laurens' Blog
  • JT`s warehouse district
  • Kennar's Blog
  • KiteFuchs' Blog
  • KiteFuchs' Blog
  • Rachel's Dev-Blog
  • Eagle's Blog
  • zaphos' Blog
  • please delete this blog
  • Afke's Blog
  • Richard Simpson
  • knowledgegranted's Blog
  • EdzUp(GD)'s Blog
  • aGameLife's Kelasel MMORPG Blog
  • tournamentdan's Blog
  • Beyond Civilization Blog
  • smashthewindow
  • AnniXa's Blog
  • AnniXa's Blog
  • Elemental Development
  • DigitalHax Blog
  • Aria's Blog
  • Strogg76's Blog
  • Clackdor's Blog
  • Leadwerks Project Status
  • simpleprogrammer's Blog
  • Pathfinding in LE.2.x
  • Naughty Alien's Blog
  • smashthewindow's Blog
  • Ali Salehi's Blog
  • Jardar's Blog
  • Chris Vossen's Development Blog
  • Scarlet Thread Studios' Blog
  • Kronos' Blog
  • Benton's Blog
  • ChrisV's Blog
  • tjheldna's Blog
  • shadmar's Blog
  • 3D Masons, LLC
  • Andy Gilbert's Enviro Models
  • ParaToxic's Blog
  • NarkLord's Blog
  • ChrisMAN's Blog
  • ChrisMAN's Blog
  • CGMan's Blog
  • The Game
  • Chris Tutorials
  • Leadwerks 3 Experience
  • An Alien Saga
  • klepto2 & Leadwerks 3
  • Inside the mind of eternal insomniac
  • josk's Blog
  • Shader Development in Leadwerks 3.1
  • 3D Coat : Column game making of
  • Einlander's Blog
  • Ginger George's Blog
  • I have a problem
  • Michael_J's Blog
  • nasamydifol's Blog
  • Digman's Blog
  • noesisGUI
  • SavageDogg38's Blog
  • Built from Ruins
  • Remaining Days
  • test_external_blog
  • The Hunt For Food Blog
  • Crazy Minnow Studio
  • CrazyMinnowStudio
  • Guppy's Blog
  • Playing Online
  • Evayr's Blog
  • DerRidda's Blog
  • Karl's Blog
  • whiterabbit's Blog
  • Tinyboss Games
  • abendkleider's Blog
  • sacguccireplica's Blog
  • Arena
  • Imchasinyou's Blog
  • xtom's Blog
  • Lua is better than you think.
  • mdgunn's Blog
  • Crime Closer
  • lxFirebal69xl's Blog
  • Wedmer's Blog
  • Lockdown, going forward.
  • Pump-Action Captain
  • Igor's Blog
  • Dead Anyway
  • Runenrise and more
  • reepblue's Blog
  • Slippy's Corner
  • LUA Musings
  • severjack's Blog
  • mikeporter's Blog
  • miko93's Blog
  • Megalocerous' Blog
  • lxFirebal69xl's Blog
  • aiaf's Blog
  • Lostghbear's Blog
  • echo $BLOG_NAME > blog_title.tmpl
  • johnadam111's Blog
  • Dwarf Beard
  • burgelkat's Blog
  • Charrua's Blog
  • peterpaul's Blog
  • joshmathews' Blog
  • Martin Kearl's Blog
  • Brutile's blog
  • tipforeveryone's Blog
  • Glushchenko Blog
  • Express Lab Games Blog
  • Blueapples' Blog
  • DooMAGE's Blog
  • Structura devblog
  • UltraEngine - Experiences, add-ons and other Stuff
  • martyj's Blog
  • Dragonfreak's Blog
  • Brutile's Blog
  • assigmenthelp
  • Case Study Assignment Help
  • How to deal with bad grade ?
  • How to deal with bad grade ?
  • GameDev Blog
  • devcjohnson's Blog
  • devcjohnson's Blog
  • THE WHAT? Blog
  • The Demurian Scribe
  • GUI Editor
  • GUI Tutorial
  • noob_shaders
  • The Seventh World
  • Phodex Games Blog
  • Leadwerks VS Source 2
  • Work in Progress - Scifi PBR Media
  • [C++] First Player game start
  • The Blog of Yue
  • Snowboarding Development Blog
  • Ocean: Rendering in Leadwerks 4
  • Game Ready Maps
  • Ultra App Kit (Advanced Custom Widgets)
  • Poking around
  • SALVATIONLAND
  • Blender tutorials
  • Usefull Scripts & Components
  • Thirsty Panther
  • Direct Macro

Forums

  • Software
    • General Discussion
    • Programming
    • Game Artwork
    • Showcase
    • Suggestion Box
    • Bug Reports
  • Addons
    • Extensions & Plugins
    • Components
    • Addon Development
  • Platforms
    • Windows
    • Linux
    • macOS

Categories

  • Tutorials
  • Games
  • Work in Progress

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Location

Found 4 results

  1. Hello everyone. After some frustrations, I've decided to give up and open a post here in hope I could get some help. I would like to make a button which needs to stay pressed for x sec / ms before calling its output. I don't know what my problem is, the script in itself is not complicated, but it seems I can't make it work... If you don't understand what I mean I made a little video which I hope will help you see the goal. rotbuttondemo.mp4 Another video of this kind of action can be found in this video at around 57 sec: I don't really care for the rotation of the button at the moment. I know the math and could easily implement it later. What I'm really interested in is the delay before the output and the detection of the player pressing the button. I've tried using the default button script and the trigger delay script but with no success. I could give you a scrap of code I made if it can help. Script.cleaningtime = 5000 --int "Cleaning time (ms)" function Script:Start() self.enable = true cleantimeleft=0 end function Script:Use() cleantimeleft = Time:GetCurrent() + self.cleaningtime while(window:KeyDown(Key.E))do --while the player is holding its use key down if Time:GetCurrent()>cleantimeleft and self.enable then System:Print("Clean!") self.component:CallOutputs("Used") end end end I don't know what I'm missing out. Whenever I try this the game freezes until the player release the use key... Anyway, thank you very much for the help.
  2. I've been working on a script that's based on an old reepblue script he included in his old lex template. I want it to damage the player as long as he's inside the trigger box, but right now, it just kills him outright, can't get the timer to work I think, what am I doing wrong? Script.enabled=true --bool "Start Enabled" Script.entered = false Script.exited = false Script.hadCollision = false Script.RefireTime = 1.0 -- float "Refire Time" Script.Timer = 0 Script.Tipped=false Script.damage=10--int "Damage" function Script:Start() self.enabled=true end function Script:UpdatePhysics() if self.enabled then if self.entered then if self.hadCollision == false then if self.exited == false then self.component:CallOutputs("onendTouchAll") --System:Print("onendTouchAll") self.Timer = 0 self.Tipped=false self.entered = false end end end self.hadCollision = false end end function Script:Collision(entity, position, normal, speed) if self.enabled then if entity:GetKeyValue("name") == "FPSPlayer" then self.hadCollision = true entity:AddForce(0,0,0) if self.entered == false then self.component:CallOutputs("onstartTouch") --System:Print("onstartTouch") self.entered = true self.exited = false end if not self.Tipped then self:Trigger(entity) end end end end function Script:UpdateWorld() if self.enabled and self.entered then -- A negitive value will disable this. if self.Tipped and self.RefireTime >= 0 then self.Timer = self.Timer + (Time:GetSpeed()/100) if self.Timer > self.RefireTime then self.Timer = 0 end end end end function Script:Trigger(entity) self.component:CallOutputs("OnTriggerTick") --System:Print("OnTriggerTick") -- Hurt the activator! if entity.script then if self.Timer == 0 then if type(entity.script.Hurt)=="function" then entity.script:Hurt(self.damage) end end end end function Script:Enable()--in if self.enabled==false then self.enabled=true end end function Script:Disable()--in if self.enabled then self.enabled=false end end
  3. I am making a contraption that is sort of like pistons, and know how to make everything except a timer to keep them moving. I was thinking I could create a pivot to have an output (that I could manage in the FlowGraph editor), and just have it loop the output with a delay of about a second before it loops again. To quickly summarize How to program an output that will be displayed in the FlowGraph editor How to loop it with a delay between outputs How to have it not stop until I want it to. Thank you
  4. Can someone please tell me a good way to do a timer that starts when the game starts and ends if a object is touched? I tryed many things but it doesnt worked. Thanks for your Answeres!
×
×
  • Create New...