• Home
  • Index
  • Search
  • Download
  • Server Rules
  • House Roleplay Laws
  • Player Utilities
  • Player Help
  • Forum Utilities
  • Returning Player?
  • Toggle Sidebar
Interactive Nav-Map
Interactive DarkMap
Tutorials
New Wiki
ID reference
Restart reference
Players Online
Player Activity
Faction Activity
Player Base Status
Discord Help Channel
DarkStat
Server public configs
POB Administration
Missing Powerplant
Stuck in Connecticut
Account Banned
Lost Ship/Account
POB Restoration
Disconnected
Member List
Forum Stats
Show Team
View New Posts
View Today's Posts
Calendar
Help
Archive Mode




Hi there Guest,  
Existing user?   Sign in    Create account
Login
Username:
Password: Lost Password?
 
  Discovery Gaming Community The Community Real Life Discussion
« Previous 1 … 11 12 13 14 15 … 246 Next »
Took me two weeks to get asteroid field to work

Server Time (24h)

Players Online

Active Events - Scoreboard

Latest activity

Took me two weeks to get asteroid field to work
Offline Rotorist
09-21-2018, 06:11 PM,
#1
Member
Posts: 26
Threads: 6
Joined: Jan 2018

We are all pretty used to the way asteroids work in Freelancer and we took for granted how smooth they are!

I haven't realized what a challenge it is to make an asteroid field that spreads out long distances without stuffing GPU's memory with millions of objects. I had to figure out a way to dynamically place asteroids around the player as the player moves around in the field, and also to ease out the eye sore when asteroid pop out of nowhere, I had to write a shader that makes the asteroid transparent when they are far away and solidify as player gets closer.

On top of that, if the asteroid field is foggy, the sun has to look more gloomy, and lighting has to adjust along with it. It was truly a lot of work to do simple asteroids. But I finally achieved something that looks half decent:

https://www.youtube.com/watch?v=IbnHG7XO...e=youtu.be

You may occasionally see distant asteroids popping out, but usually it doesn't bother my eyes that much.

Actually the real challenge was how to render the asteroid field when the player is some distance away from it. I made a very stupid algorithm to line the asteroid "cells" (each cell is pre-loaded with randomly placed asteroid objects) along the edge of the field, increased the transparency threshold in the shader, and actually it didn't look too bad from a distance.
Reply  


Messages In This Thread
Took me two weeks to get asteroid field to work - by Rotorist - 09-21-2018, 06:11 PM
RE: Took me two weeks to get asteroid field to work - by Nerva Regis - 09-21-2018, 08:40 PM
RE: Took me two weeks to get asteroid field to work - by Enkidu - 09-21-2018, 08:42 PM
RE: Took me two weeks to get asteroid field to work - by Laz - 09-21-2018, 08:46 PM
RE: Took me two weeks to get asteroid field to work - by Alley - 09-21-2018, 08:54 PM
RE: Took me two weeks to get asteroid field to work - by Durandal - 09-21-2018, 09:15 PM

  • View a Printable Version
  • Subscribe to this thread


Users browsing this thread:
1 Guest(s)



Powered By MyBB, © 2002-2026 MyBB Group. Theme © 2014 iAndrew & DiscoveryGC
  • Contact Us
  •  Lite mode
Linear Mode
Threaded Mode