Replace something found in alot of scripts.

Fredrik

Member
Is it an easy way to replace something within all scripts in the game?
Been working on a game project for years now, and I've had to set fog alot, and I've used:

Code:
d3d_set_fog(1,player.c_fog,0,350);
which now can be found everywhere in the codes. However I'd like to change it to

Code:
d3d_set_fog(global.e_enable,global.c_fog,global.s_fog,global.e_fog);
in other worlds change all the values to globals so I can easly turn on / off / change fog.
I could just go over all scipts in the game and change it manually, but it would take forever.
So is there an easy way in game maker to just find and replace, lets say "player.c_fog" in all scripts?
 
P

ph101

Guest
Yes, In GM2 press ctrl+shift+f and search replace across whole project. Can't remember if 1.4 has the same functionality.
 

Fredrik

Member
It doesn't seem like 1.4 have it. ctrl+shift+f only brings up the option to search for something in all scripts.
 

FrostyCat

Redemption Seeker
1.4 does not have a global search and replace function so unless you upgrade you're **** out of luck sorry.
Just because the IDE doesn't have it, it doesn't mean you can't use something else. You can use Notepad++, Sublime, Atom, or any other text editor with a competent project-wide find+replace. You can use GMEdit. There are just too many viable options for a statement like yours to make any sense.
 
Top