home home

downloads files

forum forum

docs docs

wiki wiki

faq faq

Cube & Cube 2 FORUM


Portal in Sauerbraten?

by Meigus on 08/02/2010 21:58, 17 messages, last message: 08/07/2010 18:34, 3103 views, last view: 04/29/2024 13:43

I noticed the Justice edition introduced "teleports now preserve velocity if third attribute of teledest is set to 1"

In the game, you can already make teleporters on the fly, so could it be possible to start off with a weapon that can create teleporters out of edit mode, and then work on that actual portal part?

The way I've heard the Source engine does Portals is it recreates the world (literally) multiple times depending on how "deep" you set the portals to look.

Surely with the powerful geometrical aspects of cube2 and it's ability to dynamically reproduce/reallocate content it wouldn't unfeasible, or possibly even that complicated?

   Board Index   

#1: no worky

by Blarget2 on 08/02/2010 23:07

there is no set volosity so you would speed up too fast and either loose speed form speeding up too much or fly through the level...


and the way the gmae calclights.... just forget the idea man....

reply to this message

#2: Re: no worky

by Meigus on 08/02/2010 23:58, refers to #1

The Source Engine doesn't use dynamic lights in Portal, and they don't in Team Fortress 2 either. Velocity could just be maxed at some high-but-not-gamebreaking value, like 2-5x the current max falling speed (if there is one)

You obviously don't know how this stuff works :P

reply to this message

#3: .

by Blarget2 on 08/03/2010 00:30

i obviously do. i tested this vigorously. there is no speed cap for volosity, it just keeps getting faster until you touch a wall, and at a certon speed you just fly past a teleport. if you shot a portal and it copied the geometry to show the room your in, it would destroy the calight also. please don't assume people don't know what they are talking about. it makes people here get mad.

reply to this message

#4: Re: .

by Meigus on 08/03/2010 00:44, refers to #3

"I tested this vigorously"

Did you try putting a cap on the velocity, even if it involved adding new values to the source code?

And explain why the lights won't work, if all they did was copy that data that's already in place (it wouldn't be map editing, though new vertices would be created/destroyed).

You can't just say "lol no" and expect me (and anyone else who cares about this) to believe you.

reply to this message

#5: ..

by Q009 on 08/03/2010 01:11

Well... It could just render world again instead of "recreating" it

reply to this message

#6: Made this two years ago...

by tentus_ on 08/03/2010 01:44

http://quadropolis.us/node/1066

reply to this message

#7: Re: Made this two years ago...

by Blarget2 on 08/03/2010 02:14, refers to #6

it wasent what he wanted tho. i have actually make a map where i pre made the portals and made the whole and showed the area you will tele to.

http://i26.tinypic.com/2dka1zp.png

reply to this message

#8: ..

by Razgriz on 08/03/2010 02:16

i don't think the "portal imaging" is the problem here. after all, its just a camera view. the hard part is actually transisting the model from one portal to another. its quite complicated

reply to this message

#9: Re: ..

by tentus_ on 08/03/2010 06:39, refers to #8

Actually, the recursive world rendering can be a real problem, while transitioning from one location to another while preserving velocity is pretty easy. It's a bit of a pain to redirect velocity according to the orientation of the portal, but again, that's not the hard part. It's not letting you system run itself into the ground trying to render a world that is behind 2^1000 portals.

reply to this message

#10: ..

by degrave on 08/03/2010 11:54

Valve's Portal actualy render only in depth of 9 portals :)

reply to this message

#11: ..

by Meigus on 08/04/2010 00:07

degrave, by default, Portal only renders two portals deep.

And yeah, that guys portal gun doesn't create portals, but does create the teleporters.

Here's a starting point, are their mirrored surfaces in Sauerbraten? I know water can be reflective. You could make reflective surfaces that could display what a camera at some position would see, if it were the player's distance from a wall looking outwards, and vice-versa.

reply to this message

#12: Re: ..

by Q009 on 08/04/2010 02:35, refers to #11

It would be posibble, we could use current minimap technology because minimaps are automatically generated by engine.

reply to this message

#13: ..

by SheeEttin on 08/04/2010 21:26

Re recursive rendering:
Cameras/projections?

Reusing envmap system is reasonable, but I don't know if it'd be anywhere near fast enough (especially not if you wanted anything more than a "screenshot" for every new portal).

Another problem would be physics, if anyone's thinking of going beyond the current simple physics (i.e. adding tumbling).

(IIRC, for Portal, they created "physics bubbles" around portals so they could correctly manupulate objects around/through portals.)

reply to this message

#14: Teleport bind

by Whales ( Dthdealer ) on 08/06/2010 09:47

====
In the game, you can already make teleporters on the fly, so could it be possible to start off with a weapon that can create teleporters out of edit mode, and then work on that actual portal part?
====

I'm no proper cubescripter, but something like this should work

tportmode = 1
tportnum = 1
bind o [ edittoggle; sleep 10 [ if ( = $tportmode 1 ) [ tportmode = 0; newent teleport $tportnum ] [ tportmode = 1; newent teledest $tportnum; tportnum = ( + $tportnum 1 ); newent mapmodel 6 ] ] ; sleep 10 [ edittoggle ] ] ]

Now just make sure these rules are applied:
1 ) The game mode allows edit mode / it's a local game
2 ) The cube size is set to minimum ( g + scroll in editmode )
3 ) No other teleports exist on the map. If the map already has teleporters, try by starting with "tportnum = 50" which should be beyond most map's usage.

reply to this message

#15: Re: Teleport bind

by Meigus on 08/07/2010 09:18, refers to #14

When I said "out of", I meant while not in edit mode, not the sense of using edit mode. Pretty sure you misinterpreted my question.

reply to this message

#16: Re: Teleport bind

by Whales ( Dthdealer ) on 08/07/2010 11:45, refers to #15

The bind is dirty hack that manages to do it without source modification.

When you press the bound button ( eg 'o') you need to be in normal mode to start with. You are then put into edit mode for a split second, and should then return to normal mode within a few frames.

Try the bind, it is not a desirable option but it works.

reply to this message

#17: Re: Teleport bind

by tentus_ on 08/07/2010 18:34, refers to #16

I used something similar in my Portal level. Whales is right, it works.

reply to this message

   Board Index   


Unvalidated accounts can only reply to the 'Permanent Threads' section!


content by Aardappel & eihrul © 2001-2024
website by SleepwalkR © 2001-2024
53868441 visitors requested 71643612 pages
page created in 0.009 seconds using 10 queries
hosted by Boost Digital