Jump to content


Photo

Game Maker 3D Terrain Editor (GMTE)


  • Please log in to reply
60 replies to this topic

#1 Master Xilo

Master Xilo

    GMC Member

  • GMC Member
  • 393 posts
  • Version:GM8

Posted 21 November 2009 - 11:27 PM

For the latest version, please visit GameMaker Terrain Editor 2 (GMTE 2)

Old projects - reposted

This is one of the main projects (it is actually the main project) I made with Game Maker a long time ago (this project is from 2006).
I decided to follow some requests and reworked some of my old projects (I had some fun working with the GameMaker once again) and now I'm reposting them here.

This is a free 3D terrain engine and editor.
Some longtime members might still have seen one or the other of these old posts of earlier versions the very same terrain (and RTS) engine:



This project is related to the Game Maker 3D Rts Engine And Editor project. It is an updated and optimized version of that engine's terrain system.

Because of the limitations of this board (only 3 images..., pictures are worth thousands of words, why no have more of them?)
I put pictures, the download link (fully working, vista compatible, compiled exe,
completely reworked version of the "3D RTS terrain engine" as found in the first topic referred to (source now included))
and more info and a video on a website:

Game Maker 3D Terrain Editor Website

 

Game Maker 3D Terrain Editor Direct Download

 

 


The source code/gmk-file is also included.

This program and terrain engine feature for example:


  • Very good use of gm 3d's limited speed
  • The terrain can have an unlimited amount of textures
  • etc.

Extensions/Uses/Applications of this Engine
See v2 topic...

Video
See under "Videos" on the GameMaker 3D Terrain Editor Website.



Screenshots
gmte1.jpg
gmte3.th.jpggmte1.th.jpg

I'm open to any comments and suggestions. I hope you'll like it.
Thanks for your time
- Paul


Edited by Master Xilo, 17 March 2014 - 06:50 PM.

  • 1

#2 D1g1talAli3n

D1g1talAli3n

    BoyGenius

  • GMC Member
  • 965 posts
  • Version:GM8

Posted 21 November 2009 - 11:46 PM

You've gotta be kidding me! That's f****** amazing! :whistle: Well done!

EDIT: Maybe implement different brushes like the DGDK one?

Edited by D1g1talAli3n, 22 November 2009 - 03:10 AM.

  • 0

#3 antome

antome

    GMC Member

  • New Member
  • 305 posts

Posted 22 November 2009 - 12:00 AM

Excellent work on this, I'll look at trying this in a bit.

also, any chance for say, an export script function?

Edited by antome, 22 November 2009 - 12:47 AM.

  • 0

#4 GMkizzle

GMkizzle

    GMC Member

  • GMC Member
  • 380 posts

Posted 22 November 2009 - 12:40 AM

omfg!!
lol you wuld not beleive me if i told you this.
i seen your terrain editor (the first link) just 2 days ago.
and i sent a pm to every single still active member that posted in that topic
to see if they still had the source!!!!!!

then today i got a pm back saying sorry man got a new computer and etc.
then i goto 3d game techniques and i see Master Xilo.
OMFG!!! i cant beleive it.

btw you are a GM god

Edited by GMkizzle, 22 November 2009 - 12:45 AM.

  • 0

#5 Master Xilo

Master Xilo

    GMC Member

  • GMC Member
  • 393 posts
  • Version:GM8

Posted 22 November 2009 - 03:08 AM

also, any chance for say, an export script function?

What do you mean? To export the terrains?
  • 0

#6 IQbrew

IQbrew

    Pro-Grammar

  • Banned Users
  • 2607 posts
  • Version:Unknown

Posted 22 November 2009 - 03:42 AM

Yes, this would be quite a tool if you allowed us to export the terrain in code form.

#7 D1g1talAli3n

D1g1talAli3n

    BoyGenius

  • GMC Member
  • 965 posts
  • Version:GM8

Posted 22 November 2009 - 03:47 AM

Yes, this would be quite a tool if you allowed us to export the terrain in code form.

Or he could have a function to export it as a .d3d (or sometimes called .mod) model and texture, which would be quite a bit faster when loading in-game.
  • 0

#8 antome

antome

    GMC Member

  • New Member
  • 305 posts

Posted 22 November 2009 - 08:51 AM

Yes, this would be quite a tool if you allowed us to export the terrain in code form.

Or he could have a function to export it as a .d3d (or sometimes called .mod) model and texture, which would be quite a bit faster when loading in-game.

for means of security and other purposes, I for one would rather have a script, even if it slows down the loading.

But having said that, marzipan could probably turn it into code if there was an export as OBJ function.

But still..

Edited by antome, 22 November 2009 - 08:52 AM.

  • 0

#9 frankpiet

frankpiet

    ^destroyed evil chicken^

  • New Member
  • 760 posts

Posted 22 November 2009 - 09:20 AM

Looks very good!

cant wait til its open source, see what I can learn from your code for my editor

Maybe get this to examples?
  • 0

#10 michael pw

michael pw

    GMC Member

  • GMC Member
  • 1488 posts
  • Version:GM8.1

Posted 22 November 2009 - 10:52 AM

is that Age of Mythology, the graphics sure look good!

Edit: all i would suggest is an export of the model along with the texture and heightmap scripts that work with that particular model.

also do you still have the Aom rts thing you made? cos it looks good and i want to try it but there's a broken link :D

Good luck with it all!
Michael.

Edited by michael pw, 22 November 2009 - 11:11 AM.

  • 0

#11 2DLuis

2DLuis

    Graphic Designer

  • GMC Member
  • 2526 posts
  • Version:GM8

Posted 22 November 2009 - 04:20 PM

Glad you recoded it, I remember the other one to be very laggy... :D
But this one is real fast, and easier to use, the other one's controls looked like you were driving a spacecraft...
  • 0

#12 BR Games

BR Games

    GMC Member

  • New Member
  • 3 posts

Posted 25 November 2009 - 03:15 PM

is that Age of Mythology, the graphics sure look good!


I thought Age of Mythology too.

Haha, it looks just like it.
  • 0

#13 Endorel

Endorel

    GMC Member

  • Banned Users
  • 191 posts

Posted 25 November 2009 - 05:01 PM

I think he ripped the textures from AOM. But anyway, this is a really cool program!

#14 Universal_X

Universal_X

    GMC Member

  • New Member
  • 126 posts

Posted 29 November 2009 - 12:40 PM

hmmm.. I cant download this :S I see no clickable link on the filehost.
edit: oh heh sorry.. found teh link

But it sure looks good! :)

Edited by Universal_X, 29 November 2009 - 12:43 PM.

  • 0

#15 Endorel

Endorel

    GMC Member

  • Banned Users
  • 191 posts

Posted 29 November 2009 - 01:41 PM

@ Master Xilo
Would you care to share the techniques on how this works? How did you do the hi-resolution texture splatting? I can't wait till you release the open-source.

EDIT: and please change your file-host. I think it gave me a virus. Try host-a.net

Edited by SnowCream, 29 November 2009 - 02:50 PM.


#16 Universal_X

Universal_X

    GMC Member

  • New Member
  • 126 posts

Posted 30 November 2009 - 04:59 PM

btw. A cool feature would be export options. Options would be like Code, .obj, .mod and so..

Really awesome engine again! :(
  • 0

#17 slayer 64

slayer 64

    Slayer of gingers

  • GMC Member
  • 3857 posts
  • Version:GM8.1

Posted 30 November 2009 - 06:29 PM

lags my computer alot, lower resolution would be good(800x600) because the window is higher than my screen. i like the texture painting. this is pretty nice.
  • 0

#18 Master Xilo

Master Xilo

    GMC Member

  • GMC Member
  • 393 posts
  • Version:GM8

Posted 30 November 2009 - 07:17 PM

Very nice it would be nice to speed up it up a little though. Parts of the terrain dissapear off the camera I hope your using a terrain split code and for sure not something like objects to render it.

What's that?

It would also be nice to turn lighting on/off. The textures look like they are from Command & Conquer Generals World Editor.

Would be easy to add. The textures are from AoM.
  • 0

#19 theg721

theg721

    G Dawg

  • GMC Member
  • 1959 posts
  • Version:GM8

Posted 02 April 2010 - 11:34 AM

Video looked stunning... downloading now...
  • 0

#20 jrpmeme

jrpmeme

    GMC Member

  • New Member
  • 4 posts

Posted 04 April 2010 - 06:30 PM

is there another download link?
when i use that one this a "Win a wii quiz" pops up
  • 0

#21 Master Xilo

Master Xilo

    GMC Member

  • GMC Member
  • 393 posts
  • Version:GM8

Posted 19 April 2010 - 04:51 PM

I had finally time to upload a slightly updated version to another host.
I also included the source code/gmk file.

See first post.

Maybe this thread could be moved to "3D Editable Examples" or something now.
  • 0

#22 Master Xilo

Master Xilo

    GMC Member

  • GMC Member
  • 393 posts
  • Version:GM8

Posted 01 May 2010 - 06:40 PM

Replace the "if(var_doHeightChange) {...}" part in the second script in the Begin Step event of obj_controller with
if(var_doHeightChange)
{
	var mousePatchPosX, iRadius, icx, icy, changespeed;
	iRadius = ceil(var_circlesize/TER_PATCHSIZE);
	changespeed = var_changespeed * TER_CHANGESPEED * global.APPSPEED;
	icx = round(global.x_mouse/TER_PATCHSIZE);
	icy = round(global.y_mouse/TER_PATCHSIZE);
	
	var beginx, beginy, endx, endy;
	beginx = icx - iRadius; beginy = icy - iRadius;
	endx = icx + iRadius; endy = icy + iRadius;
	// Height editing with cubic falloff.
	// f(r) = MAX_VALUE*((2 * r - 3) * r * r + 1)
	// Source http://daz.med.upenn.edu/~rob/povray3/htdocs/pov30028.html
	for (_x = beginx; _x < endx; _x += 1)
	{
		for (_y = beginy; _y < endy; _y += 1)
		{  
			if (_x < 0 || _y < 0 || _x > obj_ground.var_terwidth || _y > obj_ground.var_terheight)
				continue;
				
			var dist, r, changeval;
			dist = sqrt(sqr(_x - icx) + sqr(_y - icy)); 
			r  = max(min(1, dist/iRadius),0); // reldist, relative (0-1) radius
			changeval = changespeed * ((2 * r - 3) * r * r + 1) * dir;
			
			//if (reldist > 1 ||reldist < 0)show_error("reldist > 1 ||reldist < 0: reldist = "+string(reldist),false);
			
			ds_grid_set(obj_ground.terrain_grid, _x, _y, ds_grid_get(obj_ground.terrain_grid,_x,_y) + changeval);
		}
	}
	
	obj_ground.change_pos[0,0] = beginx - 1;
	obj_ground.change_pos[0,1] = beginy - 1;
	obj_ground.change_pos[1,0] = endx   + 1;
	obj_ground.change_pos[1,1] = endy   + 1;
}
to get smoother hills (with real cubic interpolation/falloff).

Edited by Master Xilo, 01 May 2010 - 06:41 PM.

  • 0

#23 Koratanu

Koratanu

    GMC Member

  • New Member
  • 27 posts

Posted 07 May 2010 - 08:07 AM

Hey masterxilo,

I have fallen in love with your editor after only having it for less than a week, and have already begun to add to it. So far I added saving terrains, loading terrains(limited), loading .obj models, and a nice effect to where if you lower the terrain past point 0, you get ditches/lakes/ocean filled with water. I am interested in using this to build levels for a game (slash have fun pretending to be God haha), but I'm having 2 roadblocks so far:

1. Creating new objects to be rendered isnt working, even using the d3d_3d_setting() script you provided and use for the terrain model. Any d3d drawing functions I use in the draw event of obj_ground work, but all other objects draw functions just appear on the screen as 2-dimensional objects. I was hoping, for better logistics with objects, to use d3d in other object's draw event. Is this just a tricky camera/view setup that I havent figured out or something more?

2. With my loading function, how would I refresh the terrain to update from terrain_grid? Currently, I must use a terrain brush on a light setting to bring everything slowly to the loaded grid z values. What I need help understanding is just what calls the model to update.

I am terribly sorry if these are noob questions, as I am vastly more experienced with Xtreme3D, and your math/coding is quite elegant. I will continue to tinker with this, but it would be nice to have direction from the maker, rather than continue to reverse engineer.

Thanks in advance

PS sorry if this is wordy or verbose.
  • 0

#24 Master Xilo

Master Xilo

    GMC Member

  • GMC Member
  • 393 posts
  • Version:GM8

Posted 07 May 2010 - 06:15 PM

Hi, I'm glad you like my work!

1. This should just work. Have a look at obj_ground or obj_controller, they both draw 3d stuff in their drawing methods just fine. Make sure your object has depth=0.

2.
The terrain updates at every "end step" event it's grid points from (change_pos[0,0]|change_pos[0,1]=0) to (change_pos[1,0]|change_pos[1,1]).
To update the whole terrain, do what obj_ground does in it's create event:
change_pos[0,0]=0;
change_pos[0,1]=0;
change_pos[1,0]=var_terwidth+1;
change_pos[1,1]=var_terheight+1;

I'm actually currently working on making this even more efficient, especially the texture painting by using surfaces instead of create_sprite_from_screen.
I'm also trying to make the code even more understandable.
  • 0

#25 gadgetkk

gadgetkk

    GMC Member

  • GMC Member
  • 247 posts
  • Version:Unknown

Posted 16 June 2010 - 07:19 AM

So can you actually use this with GM for making maps and such?
  • 0

#26 rade134

rade134

    GMC Member

  • GMC Member
  • 212 posts

Posted 16 June 2010 - 09:37 AM

Hey masterxilo,

I have fallen in love with your editor after only having it for less than a week, and have already begun to add to it. So far I added saving terrains, loading terrains(limited), loading .obj models, and a nice effect to where if you lower the terrain past point 0, you get ditches/lakes/ocean filled with water. I am interested in using this to build levels for a game (slash have fun pretending to be God haha), but I'm having 2 roadblocks so far:

1. Creating new objects to be rendered isnt working, even using the d3d_3d_setting() script you provided and use for the terrain model. Any d3d drawing functions I use in the draw event of obj_ground work, but all other objects draw functions just appear on the screen as 2-dimensional objects. I was hoping, for better logistics with objects, to use d3d in other object's draw event. Is this just a tricky camera/view setup that I havent figured out or something more?

2. With my loading function, how would I refresh the terrain to update from terrain_grid? Currently, I must use a terrain brush on a light setting to bring everything slowly to the loaded grid z values. What I need help understanding is just what calls the model to update.

I am terribly sorry if these are noob questions, as I am vastly more experienced with Xtreme3D, and your math/coding is quite elegant. I will continue to tinker with this, but it would be nice to have direction from the maker, rather than continue to reverse engineer.

Thanks in advance

PS sorry if this is wordy or verbose.


I would love to have your version of the map maker with saving functions. Can you you upload it so I can download it?
  • 0

#27 MasterOfKings

MasterOfKings

    The True Master

  • GMC Member
  • 4888 posts
  • Version:GM8

Posted 17 July 2010 - 02:58 PM

I liked how it worked, but how can we use the terrain we make? All I can see is how to create a map, but not how to produce any file or script to draw it on a game...

-MoK
  • 0

#28 freko

freko

    The Professional

  • GMC Member
  • 504 posts
  • Version:GM8

Posted 19 July 2010 - 05:09 PM

Sweet. Finally I get to learn from the source itself.

Edited by freko, 19 July 2010 - 05:30 PM.

  • 0

#29 Master Xilo

Master Xilo

    GMC Member

  • GMC Member
  • 393 posts
  • Version:GM8

Posted 17 August 2010 - 10:13 AM

I'll upload an improved version of this soon, featuring much faster texture painting using surfaces (working by using the surface fix extension).
  • 0

#30 Izaak

Izaak

    GMC Member

  • New Member
  • 11 posts

Posted 17 August 2010 - 02:00 PM

this tool is by far the best i found on this website execpt for the saving part

could you put in a load and save map function?
i have tried it for 8 hours in a row to get it in but im new to game maker
i did get it in but it didnt save the edits i made in the map , only the blank map

i hope you can fix this so i can start making terain for my game.

greetings izaak
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users