 |
|  |
| Author |
Message |
Klope3
|
Well, coming back to one of the original topics, why couldn't the movement and rendering maths take care of the appearance of movement in 4D from, say, inside a building just as well as out in space? Wouldn't the existing math figure it out for us, instead of leaving us guessing as to what it would look like? Or was the movement and rendering in Adanaxis specially engineered for the purpose of space visuals?
|
|
|
|
|
|
Guest
|
Klope3 wrote ( View Post): › Well, coming back to one of the original topics, why couldn't the movement and rendering maths take care of the appearance of movement in 4D from, say, inside a building just as well as out in space? Wouldn't the existing math figure it out for us, instead of leaving us guessing as to what it would look like? Or was the movement and rendering in Adanaxis specially engineered for the purpose of space visuals? |
It can, but the screen will look very cluttered. There are other ways to project and to portray 4D, it's just that the method used in Adanaxis is not very well equipped for indoor scenes.
|
|
|
|
|
|
Klope3
|
Is there any way to insert a 3D structure/room into an existing Adanaxis level, just to see what it would look like?
|
|
|
|
|
|
admin Site Admin
|
Theoretically yes, as mesh creation is scripted. You would need to find the file AdanaxisMeshLibrary.rb, and modify one of the meshes there. You could create a new one, but then you would need to create a new Texture, use that Texture in a new Material, use the mesh in a Piece, and add that Piece to the level.
It's been a while, but my best guess would be to find mItemsCreate in that file and add:
mesh.mBaseDisplacementAdd(MushDisplacement.new(:scale => MushVector.new(1, 1, 1, 0.00001)))
after the mBaseAdd line. Items are the ammunition boxes you collect, and that will squash them by scaling by 0.00001 in one direction. Zero might work, but it also might lead to some zero-width textures and crash things. I haven't tried this BTW  so good luck!
|
|
|
|
|
|
Klope3
|
You'll have to forgive me--I flounder a little when it comes to editing code like this. I'm going to have a few questions about those instructions.
Will entering that line of code add a new...weapon pickup to a level?
If so, what level?
If this is adding a new object to a level, why doesn't it involve the input of, for instance, coordinates of where to spawn?
|
|
|
|
|
|
loki_clock
|
Klope3 wrote ( View Post): › You'll have to forgive me--I flounder a little when it comes to editing code like this. I'm going to have a few questions about those instructions.
Will entering that line of code add a new...weapon pickup to a level?
If so, what level?
If this is adding a new object to a level, why doesn't it involve the input of, for instance, coordinates of where to spawn? |
No, it's just reusing the 4D model that the items use as a template for the new mesh. You first have to create the mesh for the new object, then go to a level and edit it in. I've made custom levels and meshes before, so if I can remember where everything goes I could help you out.
|
|
|
|
|
|
admin Site Admin
|
As it turns out that edit is just changing the mesh used for all ammo boxes. Pick any level with an ammo box in it and it should be squashed.
|
|
|
|
|
|
loki_clock
|
The documentation in each .rb file will help you quite a bit. If you change the object in the menu level to the one you made you'll be able to see the mesh right when the program opens, which is useful for testing. Not only because you can get a quick preview of the mesh easily, but also because the program will crash on opening if you did something wrong.
I'll try and copy some information regarding the modification I did. It might not apply to the full version, because I did these modifications in the demo.
I was using an object called "Dummy." Under mPrecacheListBuild there's the line:
Code: › mPrecacheListAdd(mPieceLibrary.mDummyTex('red')) |
And then under mInitialPiecesCreate where the existing piece is, I have:
Code: › mPieceLibrary.mDummyCreate(
:colour => 'red',
:post => MushPost.new(
:position => MushVector.new(0,0,0,-18),
:angular_position => MushTools.cRandomOrientation,
:angular_velocity => angVel
),
:patrol_points => [MushVector.new(0,0,0,0)]
) |
Then in AdanaxisMeshLibrary.rb I have this code defining the Dummy mesh. I've added some notes on what I THINK each part of the code does, but I'm pretty much guessing from vague memory. Take grainy salt to the tongue.
Code: › #
# Dummy mesh
#
def mDummyCreate(inName)
mesh = MushMesh.new(inName)
# Initial mesh creates an order-order duoprism.
# Dummy's order, 4, would create a 4-4 duoprism, i.e. a tesseract.
base1 = MushBasePrism.new(:order => 4)
# Second theory:
# As the initial baseDisplacement is required, the MushBasePrism
# might create a regular prism, which is then extruded by baseDisplac.
baseDisplacement1 = MushDisplacement.new(
:offset => MushVector.new(0,0,0,0),
:scale => MushVector.new(Math.sqrt(2),Math.sqrt(2),1,1)
)
# Regardless, after you have your base mesh, you model it by
# successive extrusions.
extruder1 = MushExtruder.new(
# Selected cell for extrusion. I didn't understand the math
# used to calculate the source faces when I first made this, so I
# learned to predict what face would go to which face newly created from
# extrusion and calculated the source face by hand.
:sourceface => 2,
:displacement => MushDisplacement.new(
# Local X, Y, Z, W extrusion vector
:offset => MushVector.new(0,0,-1,0),
# Rotation of local vector in radians.
# ex. With hallways, you'll probably use PI/2.
:rotation => MushTools.cRotationInZWPlane(Math::PI/8),
:scale => 0.8),
# No need to copy and paste an extruder. This will repeat
# the extrusion on the new cells from the previous extrusion.
:num_iterations => 3
)
extruder2 = MushExtruder.new(
:sourceface => 3,
:displacement => MushDisplacement.new(
:offset => MushVector.new(0,0,1,0),
:rotation => MushTools.cRotationInZWPlane(-Math::PI/8),
:scale => 0.8),
:num_iterations => 3
)
extruder3 = MushExtruder.new(
:sourceface => 0,
:displacement => MushDisplacement.new(
:offset => MushVector.new(0,0,0,-1),
:scale => 0.6),
:num_iterations => 3
)
extruder4 = MushExtruder.new(
:sourceface => 1,
:displacement => MushDisplacement.new(
:offset => MushVector.new(0,0,0,0.2),
:scale => 1.1),
:num_iterations => 2
)
extruder5 = MushExtruder.new(
:sourceface => 23,
:displacement => MushDisplacement.new(
:offset => MushVector.new(0,0,0,-1),
:rotation => MushTools.cRotationInXWPlane(Math::PI/8),
:scale => 0.4),
:num_iterations => 3
)
extruder6 = MushExtruder.new(
:sourceface => 24,
:displacement => MushDisplacement.new(
:offset => MushVector.new(0,0,0,1),
:rotation => MushTools.cRotationInXWPlane(-Math::PI/8),
:scale => 0.4),
:num_iterations => 3
)
extruder7 = MushExtruder.new(
:sourceface => 43,
:displacement => MushDisplacement.new(
:offset => MushVector.new(0,0,0,-1),
:rotation => MushTools.cRotationInXWPlane(Math::PI/8),
:scale => 0.4),
:num_iterations => 3
)
extruder8 = MushExtruder.new(
:sourceface => 44,
:displacement => MushDisplacement.new(
:offset => MushVector.new(0,0,0,1),
:rotation => MushTools.cRotationInXWPlane(-Math::PI/8),
:scale => 0.4),
:num_iterations => 3
)
mesh.mBaseAdd(base1)
mesh.mBaseDisplacementAdd(baseDisplacement1)
mesh.mExtruderAdd(extruder1)
mesh.mExtruderAdd(extruder2)
mesh.mExtruderAdd(extruder3)
mesh.mExtruderAdd(extruder4)
mesh.mExtruderAdd(extruder5)
mesh.mExtruderAdd(extruder6)
mesh.mExtruderAdd(extruder7)
mesh.mExtruderAdd(extruder8)
mesh.mMaterialAdd('player-mat')
mesh.mMake
end |
You also need to add code to AdanaxisPieceLibrary.rb. I can't remember if player-mat and player-tex were custom, but they're found in AdanaxisMaterialLibrary.rb and AdanaxisTextureLibrary.rb, and like the others their novelty can be pretty easily worked out by taking a close look at the other objects in the libraries.
|
|
|
|
|
|
|
|
|
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum |
|
|  |
| Screenshots |
 |
Pic Title: Adanaxis 0.7.0 Screenshot
Poster: southa Posted: Thu Apr 19, 2007 3:46 pm
View: 45149 Rating: 10 Comments: 0
|
|
 |
Pic Title: Adanaxis 0.7.0 Screenshot
Poster: southa Posted: Thu Apr 19, 2007 3:35 pm
View: 27698 Rating: 10 Comments: 0
|
|
| [ Album ] |
|
| Recent Topics |
» Miegakure - 4D puzzle game
by loki_clock on Mon Aug 02, 2010 6:33 am
» Mousewheel
by on Mon Jul 26, 2010 3:49 pm
» Invert Up/ Down Mouse
by Andy on Tue Jul 20, 2010 9:17 am
» 64-bit Mac support?
by admin on Wed Apr 21, 2010 4:22 am
» adanaxisgpl segfaults in gravity waves
by Quim Nuss on Tue Feb 23, 2010 1:12 pm
» Enemies do not need to aim in 4D!? ¬_¬
by loki_clock on Sat Jan 23, 2010 6:44 am
» An "Actual" First-Person Shooter?
by loki_clock on Fri Dec 04, 2009 8:21 pm
» Is the 4th dimension 'real'?
by loki_clock on Mon Nov 23, 2009 4:55 am
» 4D Fundamentals
by loki_clock on Mon Nov 23, 2009 4:51 am
» Is it possible to reach the Fourth Dimension?
by loki_clock on Mon Nov 23, 2009 4:41 am
|
|
| Statistics |
We have 506 registered users
The newest registered user is LoSt
Our users have posted a total of 299 articles within 83 topics
|
|
| Visit Counter |
| This site has 7647217 page views in total since Sun Feb 27, 2005 12:27 pm |
|
| Who is Online |
|
In total there are 9 users online :: 0 Registered, 9 Guests
Registered Users: None
[ View complete list ]
|
|
|  |