Mimic?
Quote from SmashManiac on May 30, 2009, 3:19 amI had an idea for a Portal map, but I wasn't sure if it the engine allowed it. So I installed the Source SDK and followed a couple of basic tutorials, and right now I don't even think I can achieve my idea without creating some crazy mod.
Here is the basic idea that I wanted to implement. At first glance it would look as if a mirror is present in the room, but the reflexion is slightly different, and switches activated in the reflexion of the mirror would open up doors on the other side. The trick would be to have a glass instead of a mirror with a 2nd Chell that would mimic everything the player does.
This idea sounded simple, but I stumbled on a lot of hurdles:
- I cannot find a Chell NPC entity. I could use a different NPC, but it would look awkward.
- Interaction between entities appear to be impossible beyond target recognition and preprogrammed events. What I need is to copy-paste some entities attributes values, and sometimes multiply them by -1.
- Even if I abandon the mirror idea and only use a mimic in an isolated room, I'm still unable to set the player as a parent. Even if I am allowed to do so, NPC entities do not seem to be able to go through portals.
- I have no idea how to make my 2nd set of portals appear where I want given the restrictions. I don't even think a 2nd portal gun can fire portals not linked to the player's generated portals.Since I'm still not familiar with the development tools, can somebody confirm that it indeed impossible to overcome these hurdles without installing Visual Studio and having to create a relatively complex mod?
I had an idea for a Portal map, but I wasn't sure if it the engine allowed it. So I installed the Source SDK and followed a couple of basic tutorials, and right now I don't even think I can achieve my idea without creating some crazy mod.
Here is the basic idea that I wanted to implement. At first glance it would look as if a mirror is present in the room, but the reflexion is slightly different, and switches activated in the reflexion of the mirror would open up doors on the other side. The trick would be to have a glass instead of a mirror with a 2nd Chell that would mimic everything the player does.
This idea sounded simple, but I stumbled on a lot of hurdles:
- I cannot find a Chell NPC entity. I could use a different NPC, but it would look awkward.
- Interaction between entities appear to be impossible beyond target recognition and preprogrammed events. What I need is to copy-paste some entities attributes values, and sometimes multiply them by -1.
- Even if I abandon the mirror idea and only use a mimic in an isolated room, I'm still unable to set the player as a parent. Even if I am allowed to do so, NPC entities do not seem to be able to go through portals.
- I have no idea how to make my 2nd set of portals appear where I want given the restrictions. I don't even think a 2nd portal gun can fire portals not linked to the player's generated portals.
Since I'm still not familiar with the development tools, can somebody confirm that it indeed impossible to overcome these hurdles without installing Visual Studio and having to create a relatively complex mod?
Quote from HMW on May 30, 2009, 11:00 amThat sounds pretty impossible. It would require extensive custom coding and unfortunately, the source code for the Portal client DLLs is not publicly available, like it is for other Source games. So even if you were familiar with Source engine coding, you can't make the necessary changes to Portal.
That sounds pretty impossible. It would require extensive custom coding and unfortunately, the source code for the Portal client DLLs is not publicly available, like it is for other Source games. So even if you were familiar with Source engine coding, you can't make the necessary changes to Portal.
Other Portal 2 maps: Medusa Glare
Portal 1 maps: Try Anything Twice | Manic Mechanic
Quote from SmashManiac on May 30, 2009, 2:05 pmSo even a mod wouldn't work? That's kinda disappointing for something that would normally be so simple to program.
I guess that I have to completely remove the actor that would mimic the moves as a visual indicator, and forget about controlling a 2nd set of portals based on the position of the player's portals.
Mmmm...
Actually, I could still do it, but the feeling would be completely different. For example, if in my 1st room I put a door and a box, and behind the glass a button and a door, I think people would understand the concept.
So even a mod wouldn't work? That's kinda disappointing for something that would normally be so simple to program.
I guess that I have to completely remove the actor that would mimic the moves as a visual indicator, and forget about controlling a 2nd set of portals based on the position of the player's portals.
Mmmm...
Actually, I could still do it, but the feeling would be completely different. For example, if in my 1st room I put a door and a box, and behind the glass a button and a door, I think people would understand the concept.
Quote from Stormrain on May 30, 2009, 11:57 pmI think there is a way to make NPC's go through portals, remember seeing a tutorial to make Gman walk though one, don't know how well it works though, never tried it.
http://www.youtube.com/watch?v=k6JUUOH9O78 shows that it is possible, and the uploader of the video credits this site for the info about it, I just can't figure out where. Hope that helps a bit.
I think there is a way to make NPC's go through portals, remember seeing a tutorial to make Gman walk though one, don't know how well it works though, never tried it.
http://www.youtube.com/watch?v=k6JUUOH9O78 shows that it is possible, and the uploader of the video credits this site for the info about it, I just can't figure out where. Hope that helps a bit.
Planned:15(+/-)
Drawn up: 9/15
Maps Done: 2/15
Quote from hanging_rope on May 31, 2009, 1:02 amStormrain wrote:I think there is a way to make NPC's go through portals, remember seeing a tutorial to make Gman walk though oneIt can only do prescripted things, so it will be the same every time.
There is no chell npc because she wasn't originally intended as an NPC.
I've also wanted to figure out if you can parent things to the player, so If anyone knows, can they answer please.
It can only do prescripted things, so it will be the same every time.
There is no chell npc because she wasn't originally intended as an NPC.
I've also wanted to figure out if you can parent things to the player, so If anyone knows, can they answer please.
Quote from HMW on May 31, 2009, 6:35 amhanging_rope wrote:I've also wanted to figure out if you can parent things to the player, so If anyone knows, can they answer please.You can, but when the player looks up or down, the parented object doesn't go with it. (Perhaps you have to do SetParentAttachment as well, but I haven't tried that.)
Because you can't set a targetname on the player, you have to use a trigger that sends the objects to be attached a SetParent signal with !activator as the target. (!Activator being the player who just walked through the trigger.)
You can, but when the player looks up or down, the parented object doesn't go with it. (Perhaps you have to do SetParentAttachment as well, but I haven't tried that.)
Because you can't set a targetname on the player, you have to use a trigger that sends the objects to be attached a SetParent signal with !activator as the target. (!Activator being the player who just walked through the trigger.)
Other Portal 2 maps: Medusa Glare
Portal 1 maps: Try Anything Twice | Manic Mechanic
Quote from SmashManiac on May 31, 2009, 7:35 pmHMW wrote:Because you can't set a targetname on the player, you have to use a trigger that sends the objects to be attached a SetParent signal with !activator as the target. (!Activator being the player who just walked through the trigger.)This could give interesting results! Thanks for the tip HMW!
This could give interesting results! Thanks for the tip HMW!
Quote from msleeper on June 2, 2009, 3:40 amSmashManiac wrote:This idea sounded simple, but I stumbled on a lot of hurdles:
- I cannot find a Chell NPC entity. I could use a different NPC, but it would look awkward.
- Interaction between entities appear to be impossible beyond target recognition and preprogrammed events. What I need is to copy-paste some entities attributes values, and sometimes multiply them by -1.
- Even if I abandon the mirror idea and only use a mimic in an isolated room, I'm still unable to set the player as a parent. Even if I am allowed to do so, NPC entities do not seem to be able to go through portals.
- I have no idea how to make my 2nd set of portals appear where I want given the restrictions. I don't even think a 2nd portal gun can fire portals not linked to the player's generated portals.There is no NPC for Chell. She exists only as a third person model for the player, that's it.
Explain more about what you mean/what you're trying to do. Maths are indeed possible but the more complicated you get the more entities are involved.
You can use !player as the targetname for various I/O to specify the player. There's a few more of these special targets but I won't go into them and confuse you. Also, NPCs don't go through portals. Check the wiki, there's a mega hack to make them do it but they kinda suck at it and freak out a little.
You can create pre-placed portals with multiple pairs, using the Pair ID in the prop_portal I believe. I don't think you can make the Portalgun create different paired portals.
- I cannot find a Chell NPC entity. I could use a different NPC, but it would look awkward.
- Interaction between entities appear to be impossible beyond target recognition and preprogrammed events. What I need is to copy-paste some entities attributes values, and sometimes multiply them by -1.
- Even if I abandon the mirror idea and only use a mimic in an isolated room, I'm still unable to set the player as a parent. Even if I am allowed to do so, NPC entities do not seem to be able to go through portals.
- I have no idea how to make my 2nd set of portals appear where I want given the restrictions. I don't even think a 2nd portal gun can fire portals not linked to the player's generated portals.
There is no NPC for Chell. She exists only as a third person model for the player, that's it.
Explain more about what you mean/what you're trying to do. Maths are indeed possible but the more complicated you get the more entities are involved.
You can use !player as the targetname for various I/O to specify the player. There's a few more of these special targets but I won't go into them and confuse you. Also, NPCs don't go through portals. Check the wiki, there's a mega hack to make them do it but they kinda suck at it and freak out a little.
You can create pre-placed portals with multiple pairs, using the Pair ID in the prop_portal I believe. I don't think you can make the Portalgun create different paired portals.
Please do not Private Message me for assistance. Post a thread if you have questions or concerns.
If you need to contact the staff privately, contact the Global Moderators via Discord.
Quote from HMW on June 2, 2009, 1:59 pmmsleeper wrote:You can use !player as the targetname for various I/O to specify the player.D'OH!! I totally forgot about that! Sorry
Here's the full list of special names, in case anyone is interested.msleeper wrote:You can create pre-placed portals with multiple pairs, using the Pair ID in the prop_portal I believe. I don't think you can make the Portalgun create different paired portals.That's right. The portal gun always produces portals with ID 0.
Also, watch out for putting to many portals close together and/or able to see each other. This is a very effective frame rate killer.
D'OH!! I totally forgot about that! Sorry
Here's the full list of special names, in case anyone is interested.
That's right. The portal gun always produces portals with ID 0.
Also, watch out for putting to many portals close together and/or able to see each other. This is a very effective frame rate killer.
Other Portal 2 maps: Medusa Glare
Portal 1 maps: Try Anything Twice | Manic Mechanic