Easy Heightmap Scripts
#21
Posted 07 July 2010 - 11:01 PM
#22
Posted 10 July 2010 - 10:27 PM
~~Brett14;
#23
Posted 10 July 2010 - 10:54 PM
Edited by kurtbliss, 10 July 2010 - 11:08 PM.
#24
Posted 11 July 2010 - 09:10 PM
#25
Posted 02 November 2010 - 11:07 AM
#26
Posted 02 November 2010 - 11:10 PM
This is probably your programming because it mathematically returns the correct Z values on the terrain based on the X,Y positionsthere is a problem sometimes the player is lower than it should and sometimes it is higher
#27
Posted 03 November 2010 - 08:28 AM
This is probably your programming because it mathematically returns the correct Z values on the terrain based on the X,Y positionsthere is a problem sometimes the player is lower than it should and sometimes it is higher
i have an object that has the get z script in the create event an is sometimes drawn below the terrain or its sometimes floating. do you know why and could you possibly run me throught the ds_grid_write. thanks
Edited by whiteshadow, 03 November 2010 - 08:38 AM.
#28
Posted 03 November 2010 - 11:02 PM
#29
Posted 06 November 2010 - 05:04 PM
and it would be better if you added shadows and multiple textures
this is awsome
and hope you can update it
#30
Posted 30 November 2010 - 12:50 PM
they all end up near the position (0;0)
first i thought that the terrain was way bigger than the room (witch it was)
and corected it by shrinking down the size of the terrain to the room size, but it still
ends up in the same position.
and when i try to make my models appear on the higher parts of the terrain by using your code
z=terrain_get_z(x,y);it creates at the moast random x values.
and lastly how do you change the z value of the player to the terrain?
#31
Posted 01 December 2010 - 12:51 AM
instance_create(terrain_get_z(x,y),y,instance);however that is a complete guess.
and lastly how do you change the z value of the player to the terrain?
z=terrain_get_z(x,y);and in you're projection code put the zfrom variable to either z or z+(how tall the player is). Put the zto variable to the same thing as zfrom +/- your zdirection
You should really use an editor MADE for 3D to do this, not the built in 2D editor for gamemaker. There have been many made (just search for some) and I too have made a couple (Editor14, Dark Region)hey i cant place any of my models in this example
Edited by brett14, 01 December 2010 - 12:54 AM.
#32
Posted 14 December 2010 - 06:18 PM
#33
Posted 15 December 2010 - 01:46 AM
#34
Posted 26 January 2011 - 11:52 PM
What is the variable in one of your script that makes it happen??
(When it goes to a 2d demention room);
Edited by dohyung97022, 27 January 2011 - 12:00 AM.
#35
Posted 27 January 2011 - 12:05 AM
Call d3d_end().When this game goes to another room, it makes all the stuff in variable y upsied down.
What is the variable in one of your script that makes it happen??
(When it goes to a 2d demention room);
As long as 3d mode is on, 2d rooms will be drawn upside down.
Edited by XtraButter, 27 January 2011 - 12:44 AM.
#36
Posted 27 January 2011 - 01:00 AM
Edited by brett14, 27 January 2011 - 01:01 AM.
#37
Posted 27 January 2011 - 09:10 AM
this was simple...
I thought this happened because of the scripts...
Have my Thanks!
#38
Posted 17 February 2012 - 05:58 PM
Edited by GS-games, 10 February 2013 - 11:51 AM.
#39
Posted 23 February 2012 - 05:49 PM
to Brett14....
I love the work here, but there is an issue. It appears that for some reason, when changing rooms, the terrain is not fully regenerated. It appears the height map array is inverted or changed with random numbers.
As an example I used your demo (which is great)... but if you add a second room that is a duplicate of the first room (except use a different texture map) and program the "F" and "B" keys to from room to room, the array is not re-generated, as you would expect. It appears corrupted (?!?).
I've noted, in GM8x, you can use the "persistence" check box to keep the terrain the same, except then the global terrain array is kept the same through all rooms. The texture doesn't change as it should.
Any Ideas ?????
nope... not using d3d_end()
I tried playing with d3d_start() in the terrain object, but that yields a flat texture map.
Maybe the question is....... How do I make the room re-load the terrain as it does on first load. Do I need to destroy the array in memory ?? ... load the height map and texture from file ??
What am I missing ????
yes, I have created a GM8 file, if needed.
Edited by aburgin, 23 February 2012 - 11:12 PM.
#40
Posted 04 November 2012 - 11:23 AM
Greetings !!
to Brett14....
I love the work here, but there is an issue. It appears that for some reason, when changing rooms, the terrain is not fully regenerated. It appears the height map array is inverted or changed with random numbers.
As an example I used your demo (which is great)... but if you add a second room that is a duplicate of the first room (except use a different texture map) and program the "F" and "B" keys to from room to room, the array is not re-generated, as you would expect. It appears corrupted (?!?).
I've noted, in GM8x, you can use the "persistence" check box to keep the terrain the same, except then the global terrain array is kept the same through all rooms. The texture doesn't change as it should.
Any Ideas ?????
nope... not using d3d_end()
I tried playing with d3d_start() in the terrain object, but that yields a flat texture map.
Maybe the question is....... How do I make the room re-load the terrain as it does on first load. Do I need to destroy the array in memory ?? ... load the height map and texture from file ??
What am I missing ????
yes, I have created a GM8 file, if needed.
Yeah I'm having the same problem, I got around it by just making the heightmap massive and just keeping it persistent. but now i need to do something that requires me to have more terrains, Did anyone figure this out?
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users











