[WIP][Trailer] Sphere cannon
I was a little bit bored yesterday and I decided to create an 'sphere cannon' for Portal 2.
You can use it in SP and COOP and it does not use any scripts.
Features:
- movement synchron to portalgun
- sounds and reload animations
- left mouse button to fire
- right mouse button for a transparent red crosshair
- you can pick it up and drop it whenever you want to
Trailer:
http://youtu.be/ygFEfYPHGQo
COOP testing and fun:
http://youtu.be/0mMtnTpVGrc
how does the crosshair work?
||Hey guys, I figured I should explain the crosshair a little bit,
since nobody seemed to understand it on their own...
The yellow markers on the left and on the right are the markers for the distance.
You can estimate the distance when you use a tile of the wall-texture.
The yellow dot in the middle is the spot where the sphere will hit the wall.
First line (on top) is for everything that is right in front of you.
As long as the target wall-tile is bigger than the distance between the lines, you will hit it.
A few more steps away from the wall, and you have to use one of the next lines.
... and this time we are really far away and have to use the last line:
And this is how it looks for a wall-mounted button:
As you can see, it works pretty well and there are no glitches or bugs that I would know of.
I already tested it with 3 different people in my coop test map, and it works just fine.
I am not pretty sure if I will use it for any puzzle related maps in the future, but it is
good fun to play with it... so I guess it doesn't matter if it will be usefull or not,
because its already great fun...
Edit: 4 singleplayer showcase maps with medium difficulty puzzles ready.
Information for Mappers:
- the gun modell itself are just some textured brushes tied to 'func_brush' (non-solid)
- around that modell there is one invisible rectangle 'func_physbox' to pick it up
- there is a 'trigger_push' inside of the modell to fire the sphere
- the indicator lights for the reload timeout are 'func_brush' and toggled with 'env_texturetoggle'
- sounds and lights are controlled by 2 'logic_relay' via 'game_ui' (mouse input)
- the sphere itself is a template, which is spawned on mouse-click
Feel free to post comments, feedback, suggestions or questions. ![]()
FelixGriffin wrote:
Looks impressive. Is this instantiatable?
Thanks. 
I guess I could edit it some more and could make it to an instance with
different fire rate, sounds, lights, fire distance... whatever.
So you could set up the settings for it yourself, as you like it.
FelixGriffin wrote:
Also, I don't think you need the trigger_push. You can use an env_entity_maker with Inherit Angles set to True, Move Direction set to 0 0 0, and Move Speed set sufficiently high.
Thanks for the info... I will look into that and see how it works. =)
Edit:
Tested the env_entity_maker, but it does not seem to use the up/down angles.
So I parented it to my cannon (like the trigger_push before) but it only rotates on one axis...
It seems to ignore the up/down movement of my cannon...
(Inherit angles is set to 'true' already!)
Any ideas? (Its a good idea, and works much easier than my way, but with one problem... 
Direction variance was set to 0 15 by default and I already changed it to 0.
I really tried that all, but it does not seem to work that way.
But I can still use the env_entity_maker with speed set to 0 and use the trigger_push.
Thats way easier than my first method and just works fine.
Thanks for your help and info. ![]()
yishbarr wrote:
That could be maybe an option for shooting cubes off buttons and stuff like that.
Well, we will see what people might come up with for this cannon.
I guess it's pretty usefull against turrets and ofcourse for long distance
moving of any dynamic objects, too. I will release this one as soon as I
finished working on it and then we will see. 
. Anyway, I see how this could be useful in a kind of turret bowling thing, or a coop challenge chamber.
FelixGriffin wrote:
To avoid crashes and exploits you might want to fizzle the old sphere when you shoot a new one. Otherwise it would be easy to press several buttons at once, or fill up an area with them.
I already fizzle the old sphere and if you try to pick it up it dossolves.
But nice to see you also think about the pro and cons of the cannon.
Turret Bowling or even some kind of Billard would be possible, too. 
I tested my sphere cannon in PTI SP and COOP maps, and it works just fine.
I added it to my PTI Editor Palette and now I can place it like an normal Editor Item.
I also tried to use two of them in COOP and it works just great, you dont have to change anything. 
Would anyone please create the .3ds modell and a texture for my modell? (for PTI Editor)
I cant do it myself, cause I dont have the skills needed to do it...
Contact me if you can do it, and I will send you all files you could need to do so.
FelixGriffin wrote:
I can, although it will literally look just like the cannon--it will have the "brushwork" feel to it. Someone else might be able to make it look better.
sickelbrick told me about blender, and so i just learned to work with blender today.
I exported it as .3ds, but when i use it in portal its just the big blue ERROR message.
So i guess something is missing in the model...
What steps do I need to get my model work in portal 2?
- At the Moment I have 6 different objects in blender, which are not conected, they are just 'touching'
- no Textures
- no materials
- I imported the cubesphere.3ds to scale it to the right size already
FelixGriffin wrote:
Portal 2 doesn't use 3DS files, it uses MDLs. You should be able to export an SMD with Blender, which you can then compile with StudioMDL (in portal2/bin).
I just want to use the model for the ingame view of the PTI Editor.
And there are several .3ds in "Portal 2\portal2_dlc2\models\puzzlemaker\"
Are they not used for the ingame preview of the model?
since nobody seemed to understand it on their own...
The yellow markers on the left and on the right are the markers for the distance.
You can estimate the distance when you use a tile of the wall-texture.
The yellow dot in the middle is the spot where the sphere will hit the wall.
First line (on top) is for everything that is right in front of you.
As long as the target wall-tile is bigger than the distance between the lines, you will hit it.
A few more steps away from the wall, and you have to use one of the next lines.
... and this time we are really far away and have to use the last line:
And this is how it looks for a wall-mounted button:
The map where I created these screenshots is visible for all of my steam-friends right now.
I will publish it for everyone as soon as I have fixed the most common problems and bugs.
Some of my steam-friends are testing the map right now and see if everything works out,
and then send me comments and .dem files to watch.
PortalCombat wrote:
FelixGriffin wrote:Portal 2 doesn't use 3DS files, it uses MDLs. You should be able to export an SMD with Blender, which you can then compile with StudioMDL (in portal2/bin).
I just want to use the model for the ingame view of the PTI Editor.
And there are several .3ds in "Portal 2\portal2_dlc2\models\puzzlemaker\"Are they not used for the ingame preview of the model?
No they are not. They're used for selection meshes, but you don't really need them. Only the MDL model is necessary.





