• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Question - Code d3d functions

D1Project

Member
Hello,

First, thank you for introducing this new version of GameMaker.

In a current project, I'm using d3d functions to create several dynamic animations for objects. For example:
  • d3d_transform_set_identity()
  • d3d_transform_add_translation()
  • d3d_transform_add_rotation_axis()
  • d3d_draw_floor()
They seem to be obsolete with the new version. What should be used now? If there is no replacement, would it be possible to keep them for GMS2?

Not having those functions would actually compel me to stay on GMS1.

Thank you
 

mMcFab

Member
Thee transforms have been replaced with matrix functions now! Using matrix_build in combination with matrix_set(matrix_world, matrix) for the most part.
As for drawing a floor or something, you'll eed to use vertex buffers now.
I have made a guide for getting started with 3D in GMS2 as well, perhaps it could help you out! https://forum.yoyogames.com/index.p...arted-with-3d-in-gms2-project-download.12145/

EDIT: Forgot to add, even if you use d3d transform functions in 2D, you will still need to replace them with the matrix functions now.
 

D1Project

Member
Thank you for your reply.
I am using d3d transformation functions in 2D.

Using d3d_draw_floor() was to avoid using complicated vertex functions. I hope Yoyo Games reintroduces some easier functions.
The good thing about GMS is that it's user friendly. Vertices and matrices are rather complex.
 

Nocturne

Friendly Tyrant
Forum Staff
Admin
It's worth noting that all the old functionality from d3d is translated when you import a project into GMS2... The devs have added "compatibility scripts" for these (and other) functions, so that when you import a 1.4 project it should "just work". It also means that you can open these scripts and see exactly how the old functions should be recreated with the new functions.
 

xot

GMLscripter
GMC Elder
Compatibility scripts are located here if you want to take a look:

%ProgramData%\GameMakerStudio2\Cache\runtimes\runtime-2.0.1.16\lib\compatibility.zip
 

D1Project

Member
I'm skeptical... It might be like translating your company's report with google translate (although it's a great tool).
 

Joe Ellis

Member
Thank you for your reply.
I am using d3d transformation functions in 2D.

Using d3d_draw_floor() was to avoid using complicated vertex functions. I hope Yoyo Games reintroduces some easier functions.
The good thing about GMS is that it's user friendly. Vertices and matrices are rather complex.
vertex buffers are alot faster than using draw_floor though, you'd be saving alot of memory this way,
and theyre really easy to understand once you've got past the learning curve (which is at a 75 degree angle to be fair) but a couple of hard days reading and coding you'll have everything set up
 
W

WWAZman

Guest
I was wanting to test out my old d3d code on the new one by painfully importing the 1 level I had made.. I know I should start with textures, but I can't remember and can't seem to find, the limitations of textures, scripts, etc for the beta of GMS2?
 
Top