Magnificent Ornk nikki. Posted March 18, 2006 Share Posted March 18, 2006 Is there any way to get rid of them in-game? I looked through the appendices for a call to do this, but no cigar. What I want is for a terrain script to be usable up until a flag is switched to 1. After that point, the terrain script should go, or at least be invisible. I've made a kinda remedy by altering specobj.txt so that if a given flag is over one it isn't searchable, or if it is, it displays no message or whatever, but the text description still says that it's there. So, any ideas? Link to comment Share on other sites More sharing options...
Well-Actually War Trall Niemand Posted March 18, 2006 Share Posted March 18, 2006 No, you can't dynamically remove scripts. Instead, modify the script so that it checks the flag in question. and does stuff only if is not 1: Code: if(get_flag(get_memory_cell(0),get_memory_cell(1)) == 1) end();//do whatever should be done if flag is not 1 This code will check a flag that is determined by the value of two memory cells, and if the flag is 1, stop the script from doing anything else. Link to comment Share on other sites More sharing options...
Magnificent Ornk nikki. Posted March 18, 2006 Author Share Posted March 18, 2006 Quote: Originally written by Niemand:No, you can't dynamically remove scripts. Instead, modify the script so that it checks the flag in question. and does stuff only if is not 1: The code will check a flag that is determined by the value of two memory cells, and if the flag is 1, stop the script from doing anything else. I already did this. My initial post wasn't very good, but I altered specobj.txt to do this very thing. The problem is, the terrain script is still searchable - pressing "l" in-game highlights it as something of interest. I guess I just wanted to get rid of this. Link to comment Share on other sites More sharing options...
Magnificent Ornk Kelandon Posted March 18, 2006 Share Posted March 18, 2006 The "searchable" feature isn't terribly editable. I wouldn't worry about it if I were you. Link to comment Share on other sites More sharing options...
Magnificent Ornk Swimmin' Salmon Posted March 18, 2006 Share Posted March 18, 2006 Couldn't you just swap the terrain with an identical looking terrain that isn't searchable?? Edit - And would have a different default script?? (Stupid Tab key...) Link to comment Share on other sites More sharing options...
Well-Actually War Trall Fort Posted March 19, 2006 Share Posted March 19, 2006 It should work because I think that this is the principle behind a simple door script, but I could be wrong. Link to comment Share on other sites More sharing options...
Magnificent Ornk Kelandon Posted March 19, 2006 Share Posted March 19, 2006 The set_terrain call doesn't change the terrain script already on a space, so I don't think that will work. Link to comment Share on other sites More sharing options...
Magnificent Ornk Swimmin' Salmon Posted March 19, 2006 Share Posted March 19, 2006 flip_terrain does work. In testing, it switched from doorlever.txt to specobj.txt when the graphic changed. Of course I'm assuming this is for within a town script, as it should be. Link to comment Share on other sites More sharing options...
Magnificent Ornk nikki. Posted March 19, 2006 Author Share Posted March 19, 2006 Interesting premise Salmon. So I edit the floor, and make te_switch_to (or whatever is is) to a blank florr with no terrain script? I'll see if it's worth the effort. But thanks for that anyway - it might come in useful later. Link to comment Share on other sites More sharing options...
Recommended Posts