Jump to content

Beam Class

Recommended Posts

It's nice, but couldn't you just as easily use one function that positions a sprite between two end points and aligns it to a vector?

Share this post

Link to post

I guess an additional function of the sprite class would be better. The goal is to not have the user manually do the math to make a beam or cable. You're suggestion is much better than mine, but I can't easily add functions to existing classes so I was stuck making a new class. :)

Share this post

Link to post

Agree, this can make Leadwerks better for beginners who want to create a beam from their start

I think, even beginners dont have any gamedev experience but when finding their first game engine, they will look for what that engine can offer, the easiest ways to solve their needs

"I want to build a gun with laser beam" / "I want to make a starwar game with a jedi running around swinging his light-beam saber"

..googling.. 5 minutes later

"Wow Leadwerks can solve this in 1 line of code, amazing, lets buy it!"


Share this post

Link to post

Your cutoff for features seems somewhat arbitrary.

  • Why not have the beam project until it hits a surface, and use that to define the length?
  • Why not add a particle emitter onto the end of it?
  • Why not add a collision shape that is automatically created?

The list could go on and on, which is why I feel this is best done with a script.

  • Like 1

Share this post

Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...