home home

downloads files

forum forum

docs docs

wiki wiki

faq faq

Cube & Cube 2 FORUM


Destructable maps idea!

by gussak on 11/22/2008 22:03, 34 messages, last message: 07/07/2009 16:34, 26606 views, last view: 05/18/2024 14:29, closed on 10/04/2010 13:33

Hi!

The 1st thing I thought cube engine could be able to do, was to make it easier to implement destructable maps.

I mean, each shot or explosion or hack&slash, could destroy a certain ammount of the map (wall, floor etc).

That shot would leave a hole in a wall for example, and the same volume of the hole would be spawned in small debris cubes that would become dynamic and fall to the ground with physics.
And when it stops, then those debris would be reintegrated to the map structure re-becoming static again.

The problem is, I have no idea where to start coding it, but I am sure the most important thing the cube engine already have, cubes!!!

So I put this ideia to anyone willing to implement it. Unfortunately I am not being able to have time to implement it :/

   Board Index    Go to next 20 messagesGo to last 20 messages

#1: Lightmaps

by jbuk2k7s cookie has gone on 11/22/2008 22:49

This has been discussed many times before, and the main problem is that Sauerbraten uses precalculated lightmaps, and therefore any geometry changes would break the lightmap.

The only solutions are truly dynamic lights, which is incredibly resource intensive, and multiple or on-the-fly lightmap changes, which are hugely impractical.

reply to this message

#2: ..

by Forty two on 11/22/2008 23:08

A physics system would be a huge start.
Like cookie said, the lightmaps are precalculated, but perhaps if the walls are dynamic, with on-the-fly shadows, it would be more practical to use DMM-Style breakables.
Again, we would need a better physics system.

reply to this message

#3: Re: ..

by gussak on 11/23/2008 01:43, refers to #2

so the main problem is it looking good?

mmm... for a alpha capability, I wouldnt really care!!! xDDD
It is debris, could be burnt stuff stuck on floor ^^

unfortunately I have not the time, otherwise I would code it for sure! may be some day :), I dont know the internals of cube so I would have to hack a lot til I know exactly what to do :)

I mean this is a feature that we dont c anywere, and this would be a huge differential compared to other games/engines!!!
I mean concerning about gameplay, that at other engines this seem to be something absurdly hard to implement but here, this seem plain easy!

Cuz we can go from play mode to edit mode instantly, and the just edited spots instantly affect our movement limitations.

Really, the 1st time I downloaded cube, I thought it would already have some feature like that implemented :)

reply to this message

#4: Re: ..

by Quin on 11/23/2008 02:23, refers to #2

Answer: "wall" mapmodels and destructible setting (eg. barrel).

reply to this message

#5: ..

by gussak on 11/23/2008 02:27

uh.. sorry, this thought came a bit later... I cant find a message edit button here?

As a 1st attempt, I would like advice on how can I:
1) determine wich smallest cube received the last hit from my gun
2) knowing wich cube it is, now I will just delete that smallest cube

I think this would be an interesting and fun start.

I think this should be put in some kind of script or trigger, I dont know exactly how it could work, but I know it must be automatic and do not interrupt game action.

Any tips!? (long ago I tried to figure it out, but only now I thought on forum! xD)

reply to this message

#6: ..

by Forty two on 11/23/2008 03:06

For those that didn't get my message, it's what quin said in a nutshell.

reply to this message

#7: Re: ..

by kurtis84 on 11/23/2008 03:06, refers to #5

without the lightmaps being updated, the holes created probably won't be easily seen...if you can keep it from totally wrecking the lightmaps.

reply to this message

#8: Re: ..

by gussak on 11/23/2008 03:51, refers to #7

no no, lets look from another angle.

What maps are: limitations to movement and projectiles.

When you make holes into walls you can open passages and ways to shoot thru.

even if it doesnt look good in the beggining, you will still have this great tatical element.

of course, another important thing will be to be able to deploy barricades, what seems plain simple with the cube mapping facility :), just would require a script to up a short wall.

and the difficulty to create a hole could be based on texture ID, so rock/granite wall would be harder to make holes than brick wall.

reply to this message

#9: ..

by JadeMatrix on 11/23/2008 07:05

We already have destructible geometry. They're called hightmaps. All you have to do is make the cube changes according to a brush whenever a rocket or grenade 'damages' a surface.

That's easy. Done, OK?

_Now_ figure out a way to update the lightmaps in a non-intensive process, and you'll be gold.

It's all very simple, really. Except for the stuff that isn't.

reply to this message

#10: Re: ..

by tentus_ on 11/23/2008 07:08, refers to #8

There are more complications than you realize. Aside from the staggeringly exponential graphical problems, you have to consider:

1) Client updates: if used in a tactical sense, especially with physics involved, you quickly overextend beyond Sauer's current coopedit functionality. You could devise an AI system that could run on each client, independent of the network information in order to keep everyone synced up within reason, but it would still mean that each client would either have to have an excellent connection to a beefier server, or the client would have to have a costly computer. Aren't Sauer's low reqs what pulls a lot of our player in to begin with?

2) Optimization updates: like the above, you're going to exclude a lot of the playerbase with this. Sauer's geometry is optimized when the lightmaps are calculated: this calculation can hurt badly on old hardware. Without it framerate can die even on new hardware. And alterable terrain means that PVS culling is straight-up impossible, excluding some of our most loyal players completely.

3) Map quality: you think those clipping materials just place themselves? Sauer has great hit detection, but jagged surfaces don't necessarily play nice, and IMHO they're not fun to run over. All it takes is two rockets and you've already got a jagged ridge- three rockets and we're running into peaks as well. The careful clipping of mappers is completely undermined and ignored by deformable terrain.

4) Gameplay: I've played games with deformable terrain, and it can be fun. But it can also be incredibly lame and one sided. It takes planning to keep a map even remotely fun, and I really don't see a crew of people with interest in that kind of planning sitting around ready to make use of such features. We've already got a fun, reliable formula, so why make it so that griefers have an admin-approved way of being dicks?

reply to this message

#11: Re: ..

by gussak on 11/24/2008 02:26, refers to #9

thx dude, I didnt manage to figure out that is so simple ^^, thats exactly the right way!

The code that draws bullet shots and rocket explosions on walls, is exactly the "trigger" to be used to delete cubes!

I just still wonder if it can be done in some script way, without the need to change and recompile the source code...

reply to this message

#12: Re: ..

by demosthenes_ on 11/24/2008 03:06, refers to #11

Are you reading anything that people are saying about lightmaps and other obstacles to this working properly? This isn't just about removing cubes or deforming their structure. It's about breaking maps, having no lighting, and generally making a complete mess of things.

Also, Tentus is right: any tactical advantage you may gain by making a hole is going to be instantly removed when you get stuck in it because of the messy terrain you've just made.

reply to this message

#13: Re: ..

by gussak on 11/24/2008 03:25, refers to #10

yep, I have an idea of all the problems to the good looking and even the gameplay, this capability may arise.

yep, you are right, this should not be in the main code/release. I think the best way is to it come as a mod, cuz of that I am looking for directions, and now I found a really good tip like the marks shots leaves on the walls (I just dont understand why I havent thought, that is so obvious, b4 ^^)!!

Btw, concerning gameplay:
a) This is a new concept, and everything that is new, must be improved and have its flaws fixed.
b) Yep I know there is other deformable terrain games, but for some reason they arent so popular, I just think devs were not able yet to improve it enough to make it really (complaintless) fun.
c) This is a very cool feature, but it have huge potential problems! I know it!
c.1) Several limitations can be created, like the ammount of destruction accepted in a certain amount of time per each player.
c.1.1) critical map structures that cannot be destroyed.
c.1.2) may be even the slow regrowth/regen of walls/floor (or just of the critical structures)!
c.2) The changes could be delayed: after you do it locally, it would take a time to be uploaded to server, and another time to sync with all machines, only after that the real changes would be shown to you (the changes could be marked as transparent glowing yellow cubes on your local machine; may be red for deleted and green for added).
c.3) For each problem there will have an idea to solve it, thats the best part of new concepts, new challenges!

My point is, it just should stay around to ppl experiment so fix and improvements may be created :)

Now that I have a good clue where to look at, I just must figure out what I need to code, after that I just wonder all the problems that I may face, may be almost alone, and after some years (weekend coder ^^) I may fail shamely... or not xD.

reply to this message

#14: Re: ..

by a~baby~rabbit on 11/24/2008 03:40, refers to #13

"So I put this ideia to anyone willing to implement it. Unfortunately I am not being able to have time to implement it" - you've changed your mind! Good to hear you're willing to take this on yourself - I for one encourage such weekend programmers.

reply to this message

#15: Re: ..

by gussak on 11/24/2008 03:43, refers to #12

hi demosthenes,

My answer #13 covers most of what u said.
I just would like to add that my ideal of a map is a random map, a never boring map, a map were there is always something new to discover.
Not a silly but a well thought random map, with convincing results!

Yep, map makers now will get scared, I know ^^...

Have u ever played a game called Mount&Blade?
The 3D battle zone is randomly generated, the trees and mountains and water.
Ok it is simple, no random houses, no random fortress, no random paths between towns, no towns! I dont even remember of rocks on the floor! no random dungeons... no dungeons at all hehe.
Btw also, check for DungeonKeeper2, at the automatic map digging/created by the AI.

What I mean? if there are well planed rules, if you have a good map generating AI basis, a random map can be convincing and fun!

The only problem about this? this doesnt exist... yet! xD

reply to this message

#16: ..

by Acord on 11/24/2008 03:48

you could probably set something up where the lightmaps were essentially slices, and then averaged together in the engine, but they'd be blurry as hell and almost totally inaccurate. What's the point?

reply to this message

#17: Re: ..

by gussak on 11/24/2008 03:54, refers to #14

I still put those ideas to anyone that may be inspired on them to create their own solutions :)

I mean it, I have too little time, I code all the day at my job, so at home I have little brain cells willing to code a bit more.

I will probably code a bit, and some other time code a bit more, but I dont expect that to go much far away from that... ^^, cuz of that I was looking for a script way (portable thru versions) solution, so I could easy it up.

PS.: mmm... unless if I win lottery! XD

reply to this message

#18: ..

by yoopers on 11/24/2008 04:00

Why not split the difference and add the ability for the map maker to make certain cubes destructible, and in predictable ways?

reply to this message

#19: Re: ..

by demosthenes_ on 11/24/2008 04:39, refers to #18

See #4.

reply to this message

#20: Re: ..

by yoopers on 11/24/2008 05:38, refers to #19

Sorry for the newb mapper question, but "wall" mapmodels and barrels work in MP?

reply to this message

   Board Index    Go to next 20 messagesGo to last 20 messages


Thread closed!

This thread has been closed, which is why you can't post any more messages in it.


content by Aardappel & eihrul © 2001-2024
website by SleepwalkR © 2001-2024
54038609 visitors requested 71819044 pages
page created in 0.025 seconds using 9 queries
hosted by Boost Digital