| 05-25-2006, 05:45 PM | #1 |
I have just a lil' question: If I create a crater def, and I would not remove it, it will surely leak. So, does JASS:native TerrainDeformStop takes terraindeformation deform, integer duration returns nothing JASS:native TerrainDeformStopAll takes nothing returns nothing |
| 05-25-2006, 08:20 PM | #2 |
There are no other destructors for deformations, so that must be it. |
| 05-26-2006, 12:02 PM | #3 |
Yes, it must be, but does it work? Or is it like TriggerClearActions just a dummy shit function, that doesn't do actually anything? End need some answers withe xp using it. So it is true what you said, but it was not my expected answer. Anyways, thx for reply. |
| 06-01-2006, 12:20 PM | #4 |
I've just tested it in several ways of possiblee usage, but it never worked as I supposed it to work. Sometimes it appears that the deformation returns halfways, but stops then and stays there forever. So, any ideas how to use it, or just give me an example. |
| 06-01-2006, 07:55 PM | #5 |
The duration paramter in TerrainDeformStop is in miliseconds. Never had any problems with destroying deformations with TerrainDeformStop. TerrainDeformStopAll never tried, it might be buggy. |
| 06-02-2006, 08:31 PM | #6 |
Yes, I have seen some spells, which use the deform stop thing, bu they always use 0 as duration, but I want to use it with a duration bigger tha 1000, so I can't think of it does not work with my spell. Tell me please. |
| 06-04-2006, 05:15 PM | #7 |
As nobody can give me an accurate answer to my question, here is the peace of code iI refer(ed) to: JASS:set defi=TerrainDeformCrater(x,y,radi,zi,1750,true) call TerrainDeformStop(defi,1750) set defi=null //does not work (stops half way) set defo=TerrainDeformCrater(x,y,rado,zo,1750,true) call TriggerSleepAction(3) call TerrainDeformStop(defo,1750) set defo=null //works, but only because of the damn sleep action Plx reply |
| 06-04-2006, 05:48 PM | #8 |
The duration parameter on TerrainDeformCreater might be how long it takes to get to the bottom of the crater. Try call TerrainDeformStop(defi,3500) (double the length). |
| 06-04-2006, 06:13 PM | #9 |
I have done this too, and the same lame problem occures. |
| 06-04-2006, 07:44 PM | #10 |
I did some experimenting with terrain deformations, here are my conclusions: Terrain deformations automaticaly dissapear when their duration ends; depending on if the deformation was set to permanent or not, the deformation dissapears completely or is replaced by a permanent terrain change. Either way, the "stop terrain deformation" action only works while a terrain deformation's duration is still running. So, if you create a 1000 crater deformation over 4 seconds and after 3 seconds you try to stop it over 2 seconds, then the terrain deformation will first get to 750 depth over 3 seconds, then to 375 depth over 1 second and then it will stop decreasing because the original terrain deformation's timer of 4 seconds will have run out. |
| 06-04-2006, 08:26 PM | #11 |
I wanted DefStop thing to use just a leak memory cleaner(actually I do not know if it does it sayed job), and while that many things occured, like the terrain going upwards and downwards and upwards again and then stopping there(here i used 2 def at the same place and stopping at diffrent times). What you are telling me sounds quite confusing, but even seems to be true and fits to my experiments and xp. |
