Nighthawk
Registered:1406641081 Posts: 141
Posted 1408005459
Reply with quote
#1
I'v been trying to get planets into the mission script, and figured the only way to do it was to add a Planet definition in vesseldata.xml what do you guys think? I believe it's something this game is seriously lacking.
janx
Registered:1375293499 Posts: 464
Posted 1408023115
Reply with quote
#2
take a look at the BSG mod for how they did planets. I believe they used the Black Hole and modified it to display a planet.
Nighthawk
Registered:1406641081 Posts: 141
Posted 1408025152
Reply with quote
#3
which is what I'm pointing out: a separate definition for a planet. I could bring planets to a mission using the generic mesh block..... but they don't show up as planets in the consoles, just markers.
ryleyra
Registered:1399599588 Posts: 3,214
Posted 1408035441
Reply with quote
#4
Well, I guess the question is, what does a planet need to do? If a planet doesn't need to do anything but mark a location, then you should be able to use a generic mesh. If you want a planet to be solid, set the pushRadius on the generic mesh. If you want a planet to have a gravity well, then you'll have to modify the Black Hole. (Or place a Black Hole at the center of the mesh) Do you want planets to be selectable? Note that asteroids and nebulas aren't selectable. I'll also add that there may be some concern about the size of a planet. If a sector really is 100,000 meters to a side, as the Artemis wiki states, a planet the size of Earth would completely fill the sector and then some...
Nighthawk
Registered:1406641081 Posts: 141
Posted 1408039459
Reply with quote
#5
Quote:
Originally Posted by ryleyra Do you want planets to be selectable? Note that asteroids and nebulas aren't selectable.
one of the reasons.... also, it would mean a non-lethal gravity well, still an obstacle for navigation, but not a threat. (that, and if you use the sandbox plugin, or a scripted mission, you get a nice view of a planetary system whenever you're supposed to enter one.... it's SPACE after all, it's bound to have big celestial bodies.)
janx
Registered:1375293499 Posts: 464
Posted 1408039546
Reply with quote
#6
Quote:
Originally Posted by ryleyra Well, I guess the question is, what does a planet need to do? If a planet doesn't need to do anything but mark a location, then you should be able to use a generic mesh. If you want a planet to be solid, set the pushRadius on the generic mesh. If you want a planet to have a gravity well, then you'll have to modify the Black Hole. (Or place a Black Hole at the center of the mesh) Do you want planets to be selectable? Note that asteroids and nebulas aren't selectable. I'll also add that there may be some concern about the size of a planet. If a sector really is 100,000 meters to a side, as the Artemis wiki states, a planet the size of Earth would completely fill the sector and then some...
If we consider the game map scale is off for a planet, then it's also really off for a blackhole, which should easily cover a larger area with its effect. Personally, I think re-using the black holes as planets was a brilliant idea. I know BSG quartered the ship sizes, which in effect, made the game map 4 times as big. I think the core lesson is to not think of the game map being measured in Meters, but in M, which is some unit of space measure that covers a big enough area to fit some planets, asteroid fields, and space stations.
ryleyra
Registered:1399599588 Posts: 3,214
Posted 1408047254
Reply with quote
#7
Quote:
Originally Posted by Nighthawk one of the reasons.... also, it would mean a non-lethal gravity well, still an obstacle for navigation, but not a threat. (that, and if you use the sandbox plugin, or a scripted mission, you get a nice view of a planetary system whenever you're supposed to enter one.... it's SPACE after all, it's bound to have big celestial bodies.)
Non-lethal gravity well... you could probably make that, with a nested Black Hole inside a genericMesh planet with a push radius. The planet would then pull you into "orbit". Hm. I'll have to try that. I'm not entirely sure how the BSG mod does it's tricks, I will have to look it up to see what they do. I know they use a Black Hole as a star, but I don't know if they do the same thing with planets. The sandbox has two planets, in your two start sectors. They're a bit unimpressive, but they could be upgraded with a bigger artScale and some custom meshes. You could certainly make a system with multiple planets, if you assume the sector is big enough. See also this thread: http://artemis.forumchitchat.com/post/how-to-make-planets-6645089
ryleyra
Registered:1399599588 Posts: 3,214
Posted 1408048110
Reply with quote
#8
Quote:
Originally Posted by janx If we consider the game map scale is off for a planet, then it's also really off for a blackhole, which should easily cover a larger area with its effect. Personally, I think re-using the black holes as planets was a brilliant idea. I know BSG quartered the ship sizes, which in effect, made the game map 4 times as big. I think the core lesson is to not think of the game map being measured in Meters, but in M, which is some unit of space measure that covers a big enough area to fit some planets, asteroid fields, and space stations.
Should I start a new thread to talk about sector scale? I've given a LOT of thought to this, but don't know if anyone else wants to talk about the question in any detail. (And believe me, I WILL go into detail ) In short, I see two possibilities. If you make a sector about 2 AU in diameter, then it could represent a solar system, like ours. You'd then have planets and stations scattered about in orbit around the sun, like in the BSG mod. Planets would be fairly big balls, but still small enough to be placed in the sector and flown to (and presumably orbited) by both friendly and enemy ships. On the other hand, if you make a sector about the size of a planetary neighborhood, like about from the Earth to the Lagrange Point, then there is still plenty of room for bases and space debris (asteroids and nebulae) but a planet would be too big to appear in the sector. In such a case, though, I would suggest placing a big ball, or even better the shieldHalf mesh, along one corner or edge of the sector, and then use artScale to make it around 1000 M across. (The height of the Y axis of a sector) You can then maneuver around while "in orbit" around a planet. Since I've been playing around with the shieldHalf mesh lately, setting it's artScale to around 0.5 to 1.0 will easily fill the screen with it, as long as you are within viewing distance. The only problem with shieldHalf is that you'll have to manually rotate it to a specific angle unless you want it to be along the bottom half of the sector, and you don't want to make it automatically rotate. (You'll see the blank "inside" of the shield) The asteroid mesh will make a better ball, but it is scaled smaller. (So you'll need an artScale greater than 2.0) Now that I think about it, if 1000 M is the biggest you can make any planet (there seems to be a maximum size at which a mesh will not render) then you can easily fit that into a sector of 100,000 M by 100,000 M. At least ten planets can be fit along a straight line. So there's room for a solar system in that. On the other hand, what about a skybox that has a planetary surface as one side? That could be used to render a ship in orbit around a sufficiently big planet. Take a screencap of the Earth from space, with the edges curving off around the edges, and use that in a skybox. You could use this for gas giants or even stars.
ryleyra
Registered:1399599588 Posts: 3,214
Posted 1408076831
Reply with quote
#9
I went ahead and checked out the BSG mod once I got home. Planets and even the system's sun are created as generic meshes, which are designed custom for the mod. A black hole is nested in the center of the sun mesh, but the black hole itself has not been modified in any way. I do note that the mesh does not have a push radius set, as if it did, it would probably push the black hole outside of its diameter. But then, the point of the black hole is to destroy any ship that enters the star anyway. While there's nothing special about the implementation, it's just a generic mesh, I'm actually quite impressed by it. The custom mesh used for planets includes an outer surface which contains clouds. If you fly into the cloud cover, you can see the planet's true surface nested inside the outer surface, and your ship appears in the atmosphere under the clouds. (There's a picture of this in the other thread) Planets are all huge, and totally fill the screen underneath you. They seem to be positioned so you will fly over the planet's north pole if you are at the 0.0 Y coordinate. I don't know if diving will allow you to pass the planet to the side. (The planet does have a pushradius, so I'm guessing you can't collide with the planet) The only drawback I see to the implementation is they do seem to appear quite suddenly. You have to get fairly close (within 5000 m, the usual sighting distance) before you can see them, and even at that range they're huge. While I can see why it isn't done this way (it would take forever to render the screen if the game had to consider EVERY OBJECT in the sector) maybe generic meshes could be rendered at greater distances. (Or the size of an object could be taken into account, with something over 500 m being on a "draw at any distance" list) I have to say that if you need anything more than that, I think you're trying too hard. If you want to select something, though, the BSG mod does offer an alternative. There are cities on the planets, which are created as a neutral object in the vesselData file.
ryleyra
Registered:1399599588 Posts: 3,214
Posted 1408119608
Reply with quote
#10
I built a simple Planetary System mission, using only the meshes and textures included with the game. There are three planets in this system, one a half planet, using the halfSheild mesh mentioned above. I don't think this works very well, as you can see the "invisible" half if you approach it from the side. The other two are asteroids retextured. The "Round Planet" to the right is just a planet, and even though it's not as big as the half planet, I think there is still room to scale it bigger like the Half Planet. The "Orbit Planet" tests my idea about putting a black hole inside a planet. It works perfectly, once you got close to the planet, it's gravity pulls you in, and if you apply thrust, and a little manuevering, you can orbit the planet. Most importantly, you CANNOT leave orbit without applying Warp power. I think this is the largest the planet can be and still apply that effect. The mission is included as an attachment. (change the .txt to .xml)
Attached Files
MISS_PlanetarySystem.txt
(2.07 KB, 17 views)
ryleyra
Registered:1399599588 Posts: 3,214
Posted 1408151113
Reply with quote
#11
I've improved on my initial attempt. I pitched the Half Planet so that it curves up towards the top of the screen, and made it much bigger. It can now be used to represent a star or a gas giant or something. If you want to experiment with it, you can make it bigger or smaller, but I positioned it (on the Y axis) so that its non-visible half cannot be seen. It turns out that you can position an object lower than -500 on the Y axis and it will be seen. (Although anything smaller than this probably couldn't be) The artScale and pushRadius are set so that the planet just occupies the space in the sector above it, and if you fly over it, you will be pushed upwards. If you increase the artScale, you should increase the pushRadius proportionally. The ratio of artScale to pushRadius doesn't seem to be the same as for the asteroid mesh, this may be because the pushRadius is measured from the center point instead of the bottom of the mesh. The Round Planet I made bigger, and set it spinning. The Orbit Planet should be spinning, too, but maybe the texture is too symmetical. I tried making the Orbit Planet bigger and at an artScale of 4.0 it JUST held the ship in orbit if it was touching the planet. However, it could escape the planet's gravity if it was any distance outside the pushRadius. I decided to stick with the original radius for the planet because it makes it easier to orbit. The Helmsman can keep a stable orbit around the planet with 100% thrust and just a little adjustment to the heading every now and then. You might try reducing thrust to see if you can get a stable orbit. Note that if you turn off thrust, you will stop, and be drawn straight into the planet instead of orbiting it. Because the ship only thrusts in the direction it is facing, a small change in the facing is needed to keep the orbit going. Some other interesting facts I gathered from my testing: You first you see an object is 7000 m away from it. The outer ring of a Black Hole is at about 2500m, the inner ring is at 1500 m. At about 2000 m you have to engage Warp Drive to escape from it. As above, the mission is attached. You should be able to take it and adjust the artScale and pushRadius to make planets as big as you want, and custom textures to make it look more like a planet. The gridlike texture I used for the Half Planet would probably look good if changed to a orange or yellow color.
Attached Files
MISS_PlanetarySystem.txt
(2.15 KB, 13 views)
Arrew
Registered:1393602597 Posts: 2,750
Posted 1408175251
Reply with quote
#12
This is great stuff. Can't wait to take a look.
When I first started making scripts I called sectors quadrants because I thought there would be 4 to a solar system, with say the sun in the joining corner.
I think a thread about scale is a good idea. I just want to put in the comment about planets, I don't think people should be too hung up about scale. It's a game and I think it's more of a story telling adventure medium. So the content and fun aspect is more important than true realism and scale.I know on other planet threads people have gotten upset about scale and realism, we'll just look at black holes and no one complains about them.
ryleyra
Registered:1399599588 Posts: 3,214
Posted 1408233466
Reply with quote
#13
I think the issue of scale isn't a problem. You can create a planet of a sufficient size to make you think of it as a realistic planet. I think the bigger problem is the way generic objects appear out of nowhere at 7000 m. THAT'S the problem, I think. The OP doesn't want planets as objects in the game, he wants to make objects in the game be visible even if they're on the other side of the sector. Like he said, he wants to see the whole system from anywhere in the system. I don't think planets should be visible like that, from the Earth, the other planets in the solar system disappear into the backdrop of stars. But the sun at the center of the system SHOULD be visible. And as you approach a planet, you should be able to see it as a gradually growing ball, instead of just appearing out of nowhere. Maybe a generic object could be given a new property called visibleRadius. If greater than 7000, the object will appear at that distance, scaled proportionally for that distance. That would take some extra processing power, but with only a few objects being rendered in such a way it shouldn't load down the game too much. Alternately, outside of 7000 m the object could be displayed as some generic image, maybe even a flat "sticker". This image could be provided by the mission designer, and would shrink or grow depending on distance. So the image could be of a star, which would be seen even at a distance, and would grow until the rendered object takes its place. I think I'll go ahead and start that new thread in the Artemis Universe forum. But I may not be able to get to it today, I'll probably post tomorrow.
cxfAtheus
Registered:1400462879 Posts: 334
Posted 1408236540
Reply with quote
#14
We originally wanted to use planets in our script, but had the same issue with planets popping in and it looking strange. So, we used Space Engine to get skyboxes with planets on them. Believe me, you feel like you're in the shadow of the planet when one entire side of the map is a nice looking planet.