CS2D Map Editing
I’ve recently come across a game that I’m becoming quite a fan of. CS2D is an overhead shooter that is modeled after the popular Counter Strike mod of Half Life. Back in the day, I used to play the 3D mod of Half Life, but I have not played it recently.
I’m a big fan of this game because of its simple and fun game play. If you have some non-hardcore gamers, they will probably get a kick out of the quick and addictive gameplay. It is also seamlessly cross platform with all of my Windows and Mac friends playing along too. And it also has a simple to use map editor that allows the creative juices to flow. This will be a brief tutorial on how to use triggers to create doors that open, and breakable glass.
Using the in game editor to make a map is a piece of cake. Some of the more advanced stuff can be a bit tricky though. I’m working on a map where the Counter Terriorists must escort a VIP from a brick residence to a boat anchored just off shore. However, a group of Terrorists have found the location first, and are able to begin some fortifications of the ship with the goal of preventing the VIPs escape. I wanted to make the building a little more realistic by adding a window, and a door or two.
- Create the map
- Place your floor terrain where you want the door to be
- Go to the Entity menu, (the bulb with the points coming out of it) and select ‘Func_DynWall’
- Place it, and edit the entry by right clicking or double clicking.
- Change the Tile/Frame # to the number of the tile that you want to appear when the door is closed.
- Give the DynWall a unique name
- Elsewhere on your map, you want to create the button to open the door. From the entity menu, place a ‘Trigger_Use’ entity and edit it.
- Select the button type, and where you want it to appear, and who should be allowed to use it.
- Then, for the Trigger box, type in the name of your door (if you have multiple doors opened by a single trigger, separate them with commas)
Once you test this map out, you should now have open-able and close-able doors.
To create breakable glass, do the following:
- Place some terrain that looks like a window
- Add an entity that is ‘Env_Breakable’
- Edit this entity, and give the wall/glass some health, and determine which material you want to make it of.
You can test the map, and you should now be able to break the glass and walk through it once it is broken.
I may post some other map tricks in the future.
NOTE: Bots don’t handle glass/doors well. If the is no clear path between their start and their objective, they will not realize that doors/glass is a viable alternative and will NOT actually move. Keep this in mind if designing offline maps.
Attachment: Bridge Test map for Fiid who commented below.
You can also use trig_delay to make a wall that closes after a while. You make it so that the trigger that opens the door sets off both the door and trig_delay by putting this in the trigger box of the trigger.
trig_use (wall, delay)
Set the timer for 4 seconds or something and make it’s trigger:
trig_delay (wall)
This will make a button that opens a door that closes after 4 seconds.
How do you make a spawn point ?
Hello Brian,
When editing the map you need to click on the ‘Edit Entities’ button, which appears as a lightblub with rays coming from it, and then you will get a list of entities.
Info_T and Info_CT are your spawn points for Terrorists and Counter Terrorists respectively.
Info_VIP would be your spawn points for your Counter Terrorist VIP in ‘Escort the VIP’ levels.
Also, when laying down spawn spots, remember to place enough (and probably a few extra) for the number of players your map is going to be designed for. 8 – 10 per team should be good.
could someone please help me figure out the VIP entity and how it works? how do i change the team its on, for example i want a terrorist VIP. also how do i set conditions where ANY unit of a team has to make it to a point? for EX i want to make a map where the CT must make it to an extraction helicopter to win, and the T must delay them for the time limit. also how do i change how much money you have to start with for construction games, and how much money Dispensers give out? and my last question how do you edit the buyzone and time limit to buy stuff? an answer to any or all of these questions would be greatly appreciated.
I haven’t messed with map editing in a while, but I’ll try to answer your questions:
1) VIP – The VIP is only available to the CT team, and I don’t think you can have a T VIP. This person must be escorted to an Escape Point.
2) If you want anyone to be able to trigger the end of round, you should take a look at the Func_GameAction entity. If you place this, and right click to properties, you can set the action to end the round, with one victory or another. I haven’t played with this much, but it should do the trick. You may also need to put an Info_TeamGate field around it to block out the opposing team. Wouldn’t want the T triggering a CT win.
3) Construction Games – Only played with that type once so I don’t have much experience with it. I don’t think you can alter starting cash from the map editor, but you can customize it when you start the map. You can also create gold piles that will replenish themselves using triggers. This may also produce the desired effect.
4) The buy zone is automatically created based on the starting points for the T and CT teams. Timelimit is configured when you start the game.
Hopefully that well help a bit.
Thanks for that Luke I was looking for one like this for a lon time. No one ever wrote about it because most cs2d mappers arent too advanced and people don’t write about delay. It was well writen. I once had a try with a delay when I wanted to make something, that yon cannot use again only after a time, but somehow it didn~t work can you please tell me?
hey how do i use the tigger_start what do i type in
what the heck is botnode which available in cs2d editor?
Hey CornMaster…this is all great you wrote…and you helped me much…but I need to know how to make bridges…can you help me out???
tman545:
I played around with it, and couldn’t make trigger_start work. I assume it is something that will autostart something, but there are no options for delay and when walking over it, nothing happened.
A general example of how to use the trigger system to start weather would be:
1) Place an entity for weather. Gen_Weather
2) Right click and edit properties.
3) Give it a name, and set up the weather. Ex: Name: ‘trigsnow’
4) Create a Trigger entity.
5) Set the Trigger to ‘trigsnow’
Then in game, when the trigger is triggered, the snow will start. Setting up a trigger_start should be the same process, I’m just not sure what trigger_start operates on.
Sorry I couldn’t be more help. If you figure it out, come back and share.
Onslaught-V:
Not sure exactly what that is. I played around with it on a map for a few minutes but didn’t really see any effect. I would have thought it could be used for pathfinding or something, but that doesn’t seem to be the case. I assigned it to a trigger, and activated it. The bot seemed to hang around that general area, but that could have simply been because of the map design, and not the node/trigger combination.
Something to think about anyway. If you figure it out, come back and let us know.
Fiid:
What kind of bridge are you trying to make?
A simple bridge would just be different terrain over a water background. This will allow people to walk on and off the bridge through the sides though.
If you want a bridge that people can walk across, but can’t go in the water, then you need to modify the water tile.
1) Select the water from the left, and click Tile Properties.
2) Select Obstacle – w/o Shadow
3) Place your water.
4) Then place any other terrain as your bridge.
People will be able to shoot over the water, but not walk on it.
If you want people to die when they approach the water, you can change it to Deadly instead of obstacle, although I wouldn’t recommend it since it is instant death.
If you want to create a bridge that people can walk across, and under, well, I’m not sure if that is possible. But if you want to fake it, you can use teleporters.
1) Create your map with your terrain under and over the bridge.
2) Make the bridge a different terrain, so that it will be easy to tell it apart from the surroundings.
3) If you want people on the bridge to shoot those below and vice versa, create an obstacle where the ‘hand rail’ would be. Otherwise, create a wall.
4) Create teleporters on each side of the obstacle that will teleport to the other side.
I’ve attached an example map of this to the original post.
If I missed the type of bridge you want, let me know, and I’ll see if I can figure that out too.