3D Rad - Free 3D game maker - Forum

This forum is now archived!

This forum is locked, and is a read-only version. A new community-ran forum can be found at classdev.net

News:

The 3DRad community can be found at classdev.net.

Pages: 1 2 [3] 4

Author Topic: Little Useful Projects  (Read 27718 times)

jestermon

« Reply #30 on: September 24, 2010, 06:20:36 AM »
Or you can use x number of maps, each with a different scale, and each scale in a frame. Then using some logic, "zoom" into the particular sprite frame.. Ok, a lot of work to put it together, but at least it's still only 1 resource :)
« Reply #31 on: September 24, 2010, 01:14:34 PM »
OK but.. if the map is a sprite & attached to a separate cam, then scaling the sprite wont matter cause the new cam can have a smaller limited on screen display area..  just like a rear view mirror, but square..

hi TinSoldier... thanks for interest... I was thinking about that before making the minimap resource, with no luck... the main problem is that we can't use sprites as masks so we must have the complete map always visible... if you zoom in to the map, the sprite will be scaled... I'm pretty sure you don't want this...

however, maybe this can be solved with shaders, but unfortunately I can't help you on this... surely shadmar have an answer for us
« Last Edit: September 24, 2010, 01:16:24 PM by TinSoldier »

psikotropico

« Reply #32 on: September 24, 2010, 01:49:44 PM »
well... I'm thinking on a circle with soft edges... with a moving map into the circle, zooming relatively to the speed... all that is posible except the masking... I don't like the idea of a square map but if you can integrate it well in your HUD, you got it... the it's definitely is possible...

@jess... that solves the scaling but not the movement or masking...

ahhh!!!... that remembers me the need of sprite masks!!!...

jestermon

« Reply #33 on: September 24, 2010, 02:30:08 PM »
The other option is a dedicated camera way off somewhere in space, so it has it's own "display area", then you use:

1.. Camera for map .. Can't be round, but it's a start (Layout as in rearview mirror)
2.. Billboard background
3.. Imposters for dots or icons.
4.. Can move and zoom the camera as you wish
5.. Equals 1 cam + 1 billboard map + 1-2 master billboard for imposter icons = 3-4 resources .. oops almost forgot + 1 script.

« Reply #34 on: September 25, 2010, 01:32:40 AM »
however, maybe this can be solved with shaders, but unfortunately I can't help you on this... surely shadmar have an answer for us

You should be able to this with all the current _user_ shaders, but it needs abit of scripting.

To control texture zoom you can use
iShaderFloatSet(OBJ_X, "TileCount", float);  //the lesser float the more texture get zoomed

For moving texture around you could use :
iShaderFloat2Set(OBJ_X, "UVW", floatX, floatZ);   // X and Z texture offset.

Also TileCount doesn't zoom texture center, so when you zoom texture I'd guess it needs to be a combination of the two functions to make it work. (I haven't tried)
« Last Edit: September 25, 2010, 01:41:27 AM by shadmar »
« Reply #35 on: September 26, 2010, 08:38:05 AM »
well this sounds good, a square map moving around would be ok mostly because it would depend on the map / ground  design, could be round or square .

Just need some code to play with now..

well... I'm thinking on a circle with soft edges... with a moving map into the circle, zooming relatively to the speed... all that is posible except the masking... I don't like the idea of a square map but if you can integrate it well in your HUD, you got it... the it's definitely is possible...

@jess... that solves the scaling but not the movement or masking...

ahhh!!!... that remembers me the need of sprite masks!!!...
« Reply #36 on: September 26, 2010, 10:27:03 AM »
Playing around iv found that i can use 2 sprites and setting the "priority" to 0 & the second to 1 to adjust rendering order.

the second sprite is the "HeadingIndicator.3dr" project. ( set -90 to 90 so the sprite rotates in the opposite direction).

This gives a basic radar as a beginning.

Whats needed now is a scaled movement process for the ground map sprite to keep the radar host position located on the map properly.

And a zoom for the sprite. ( maybe starting with a large sprite ( the maximum zoom level)) then setting a zoom default as maybe %50 percent as a start point.

also there would need to be a input control for the zooming, so we would could add the "configurecontrol" to allow user customizing of the controls.

Also maybe a user settable transparency or just a default of %50 ? . 
 
« Reply #37 on: September 26, 2010, 11:38:30 AM »
Ok played around some more & this is what i have..

It two projects combined and pretty much gives a basic radar that im looking for.

the map alignment/rotations are a little out of wack, but its a good start.

Check out the included project, using 3drad v6.50 if it matters.

this is a combination of the "HeadingIndicator.3dr" project &
the "minimapdemo.3dr" projects (found elsewhere on the forum, but included here for ease of use.

Iv included path info for the files so unzip it with paths to install it properly, or manually extract files to their respective folders, your choice)

jestermon

« Reply #38 on: November 19, 2011, 11:44:28 PM »
There is often a need to center a model to the world 0,0,0 coordinates. Sketchup does not have this feature built in, so I searched the web for a solution. I found this little gem of a ruby script that almost does the job.
The plugin Center_Group_Bottom was found on a forum, made by someone named Dick.. Thanks Dick.

The original script centers the model in world, but places the model on the "floor", which is great for buildings and such. I changed the script a little, so the model is centered along the Z axis (up-down) as well. This change is needed for most models used in a game engine, such as balls, guns etc.
There are 2 scripts. Center_Group_Bottom, and Center_Group (my little change)

Unzip the little file, and place both scripts in your Sketchup plugin directory.
Once you model is ready, select everything and make it into a group or a component.

From the plugin drop-down menu, select the desired plugin, and it will do it's job for you.

Enjoy.




« Last Edit: November 19, 2011, 11:49:14 PM by jestermon »
« Reply #39 on: November 20, 2011, 04:04:31 AM »
*Screaming like a little girl getting a huge ice scream.*

Thank you soooo much Jestermon! This is just what I needed! Thank you!

Will this post be deleted to keep this topic clean?
Rocket Rumble, a 3D Rad puzzle game:
http://www.3drad.com/forum/index.php?topic=9896.0

jestermon

« Reply #40 on: November 20, 2011, 04:16:21 AM »
This is the useful goodies thread - All the ice cream and chocolates can be found here. You will notice that this thread is full of comments and feedback, so yours will also stay. But don't worry, No one can hear you scream in cyberspace.

secondry2

« Reply #41 on: January 13, 2012, 07:45:30 PM »
thanks so much guys, everything has helped me out!
« Reply #42 on: January 16, 2012, 01:51:15 PM »
how come i can't download minimap.rar
love making games....
« Reply #43 on: March 21, 2012, 07:29:11 AM »
Is it because you can't open .rar files? If that is the problem, then download Winrar to extract them.
« Reply #44 on: July 19, 2012, 05:59:30 AM »
MINIMAP

Simple but powerful thingee: get the car's location (x,y) and transfer it to the sprite location (x,z).
Read the script's code to get more info.

HOW TO INSTALL

Download and extract the .rar file to your desktop. Just add the two sprites to your sprite/data folder and run the project.

Files:
- MiniMapDemo.3dr
- MAPdemo_Terrain.tga
- MAPdemo_Vehicle.tga


WOULD IT BE POSSIBLE TO UPLOAD A ZIPPED VERSION, COZ I CANT EXTRACT .RAR FILES! ???
Pages: 1 2 [3] 4