changing tides

changing tides

Discuss maps & map creation - from concept to execution to the ever elusive release.

Moderator: Moderators

Post Reply
User avatar
oksnoop2
Posts: 1207
Joined: 29 Aug 2009, 20:12

changing tides

Post by oksnoop2 »

Is there any way to raise and lower the water level during a game?
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10450
Joined: 24 Jan 2006, 21:12

Re: changing tides

Post by PicassoCT »

There is a LUA-Script to change the Maps- heightmap in game by zwzsg for a KP-Map, if you would use this, you could simulate the effect.
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: changing tides

Post by Beherith »

Short answer is no. Long answer is yes, but its not worth the trouble.
User avatar
oksnoop2
Posts: 1207
Joined: 29 Aug 2009, 20:12

Re: changing tides

Post by oksnoop2 »

Hmm it would be cool to see the terrain change. what KP map is it?
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: changing tides

Post by Beherith »

Palladium
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7049
Joined: 16 Nov 2004, 13:08

Re: changing tides

Post by zwzsg »

Changing the water level would mean changing the height of the whole map, and for some unclear reason that is slow.
User avatar
hunterw
Posts: 1838
Joined: 14 May 2006, 12:22

Re: changing tides

Post by hunterw »

zwzsg wrote:Changing the water level would mean changing the height of the whole map, and for some unclear reason that is slow.
the reason is clear, pathing has to be reapplied to the entire map. takes a few seconds, like it does when pathing a map for the first time.
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7049
Joined: 16 Nov 2004, 13:08

Re: changing tides

Post by zwzsg »

Google_Frog
Moderator
Posts: 2464
Joined: 12 Oct 2007, 09:24

Re: changing tides

Post by Google_Frog »

Code: Select all

local function RaiseWater( raiseAmount)
	spAdjustHeightMap(0, 0, Game.mapSizeX, Game.mapSizeZ, -raiseAmount)	
end
It's not really that slow. Make your map 12x12 or smaller and the slowdown isn't noticeable.
trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

Re: changing tides

Post by trepan »

As I mentioned in the initial post that demo'ed the Lua
heightmap alteration routines, you can spread out the
processing by adjusting the map in segments. As an
example, you could split the map into 8x8 segments,
and process one segment every X number of game frames.
Tides don't move that quickly (even where I live, next to
the highest tidal variations in the world.)

http://springrts.com/phpbb/viewtopic.ph ... 00#p172300
trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

Re: changing tides

Post by trepan »

Something that I didn't mention in the initial post is that
you can mitigate the slope changes between segments by
running a smoothing pass along the segment seams after
it has been adjusted. The width of the smoothing segment
would be determined by the slope adjustment that you can
tolerate, and the amount of shift done in the adjustment.

A large area shift + seam smoothing passes is probably the
fastest way to go. The other thing that you might want to
look into is whether or not the water rendering state would
need to be updated for large heightmap changes (ask jk).
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10450
Joined: 24 Jan 2006, 21:12

Re: changing tides

Post by PicassoCT »

trepan wrote: (even where I live, next to
the highest tidal variations in the world.)

Wrong, wrong, the highest tidal variations occur where you live good Sir, and that is not just a coincedence. You create your own gravity field, that attracts all the water, now my company is willing to bid against every other bidder adding up +2000$ on the highest, just to have you near our tidal powerplants. This is a standing offer!
User avatar
Das Bruce
Posts: 3544
Joined: 23 Nov 2005, 06:16

Re: changing tides

Post by Das Bruce »

Was that a fat joke?
User avatar
Neddie
Community Lead
Posts: 9406
Joined: 10 Apr 2006, 05:05

Re: changing tides

Post by Neddie »

Either way it made me laugh.
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14673
Joined: 17 Nov 2005, 02:43

Re: changing tides

Post by Forboding Angel »

Neddie wrote:Either way it made me laugh.
+1 :lol:
User avatar
hunterw
Posts: 1838
Joined: 14 May 2006, 12:22

Re: changing tides

Post by hunterw »

PicassoCT wrote:
trepan wrote: (even where I live, next to
the highest tidal variations in the world.)

Wrong, wrong, the highest tidal variations occur where you live good Sir, and that is not just a coincedence. You create your own gravity field, that attracts all the water, now my company is willing to bid against every other bidder adding up +2000$ on the highest, just to have you near our tidal powerplants. This is a standing offer!
PicassoCT's first foray in to trolling and jokes? :regret:
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Re: changing tides

Post by AF »

hunterw wrote:
PicassoCT's first foray in to trolling and jokes? :regret:
Trolling? Seemed factually accurate...
Post Reply

Return to “Map Creation”