Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds
Watch MODSonair

Members Online

»
0 Active | 46 Guests
Online:

LATEST FORUM THREADS

»
Gaming
Q4 General
eXtreme+ v2.9
CoDBO Map + Mod Releases
map loading error
CoD2 MP Mapping
Good Servers on PC
CoDBO General

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Valve's Source
Category: HL2 Mapping
Half-Life 2 Single Player, Deathmath, Orange Box, etc. mapping and level design.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked subscribe
Author Topic: Box invisible from outside
explorer7
General Member
Since: Apr 24, 2008
Posts: 41
Last: Feb 7, 2010
[view latest posts]
Level 2
Category: HL2 Mapping
Posted: Thursday, Jun. 25, 2009 01:15 am
I want to make a box out of brushes that holds a crowbar inside it. But I want to make it so the box is invisible from the outside so it looks like nothing is there. The point is for the player to have to find the box and open it up to find the crowbar.
Share |
playername
Preferred Member
Since: Aug 24, 2006
Posts: 821
Last: Apr 15, 2011
[view latest posts]
Level 7
Im a fan of MODSonair
Category: HL2 Mapping
Posted: Thursday, Jun. 25, 2009 06:43 am
Lol opps... I should pay more attention to the fourm section... Thought that said CoD2...

edited on Jun. 25, 2009 09:44 am by playername
nullFew tips for coding.
1. Keep the script as short as possible.
2. Don't comment every line. Only comment portions where they may be needed to point something out.
3. Don't over complicate the script, keep it organized and easy to read.

These help you find simple errors and makes it easy to make changes.
Share |
Welshy
Preferred Member
Since: Feb 16, 2007
Posts: 1807
Last: Apr 15, 2018
[view latest posts]
Level 8
Admin
Forum Moderator
Im a fan of MODSonair
Im a HOST of MODSonair
Category: HL2 Mapping
Posted: Thursday, Jun. 25, 2009 08:02 am
Hhhmm interesting idea.

Making an invisible box and then have it appear once opened is fairly easy to do. The problem arises when trying to get the crowbar to do the same.

To make the invisible box just create your box out of brushes without a lid and tie it to a func_brush entity and give it a name (something like box or whatever).

Texture it in whatever texture you want the player to see when the box becomes visible. Now go into the properties of your box and change "start disabled" to yes.

Next create another brush (this will be your lid) and tie it to a func_door or func_door rotating entity. This time texture all the sides of the lid that will be visible from the outside as nodraw.

Now open the properties for the lid of the box and go to the outputs tab. Add a new output as follows

My output - OnOpen
Target entities - box (or whatever you named the box)
Via this output - Enable

The delay and fire only once are up to you if you want to change them. Finally go to the flags tab and make sure that nothing is ticked except for "Use Opens" and click apply.

Thats it for the box. I am still trying to figure out to get the crowbar to do the same thing, So I'll let you know when/if i get there.

Also if we press the "activate foylebot button" foyleman should appear at some point and hopefully he will have an idea of the best way to do this.
Go ahead... You Play I Mod : MODSonline.com
Support Modsonline by becoming a PREFERRED MEMBER today
Have you heard the MODSonair Podcast?: www.modsonair.com
MODSonair is a weekly podcast bringing you the news from a modders perspective. Tune in every Sunday at 5pm GMT to listen LIVE.
Share |
foyleman
Preferred PLUS Member
Since: Nov 6, 2001
Posts: 95759
Last: Oct 31, 2018
[view latest posts]
Level 10
Admin
Forum Moderator
Im a fan of MODSonair
Im a HOST of MODSonair
Category: HL2 Mapping
Posted: Thursday, Jun. 25, 2009 12:51 pm
foylebot button [rolleyes]
Then again, here I am.

My method would first to make a destructable crate that spawns the crowbar on death. That takes care of your box that when broken provides the player with a crowbar.

Perhaps I remember wrong, but you should be able to not give the crowbar to the player. It's been a few months on a new game engine so I could be wrong. I'd check the wiki on this.
*Update: I see the wiki indicates you can allow the player to pick it up which means you can spawn the player without the crowbar.
http://developer.valvesoftware.com/wiki/Weapon_crowbar

If you can's spawn the player without the crowbar, then the next easiest option is to create a new weapon using the sdk programming. duplicate the crowbar weapon. This way you can have more control over this weapon compared to the crowbar.
Go ahead... You Play I Mod : Support Modsonline by becoming a PREFERRED MEMBER today!
Have you heard the MODSonair Podcast?:
MODSonair is a weekly podcast bringing you the news from a modders perspective.
Tune in every Sunday at 12pm EST to listen LIVE.
Quake 4 Mods for Dummies - Half-Life 2 Mods for Dummies
Share |
Restricted Access Topic is Locked subscribe
MODSonline.com Forums : Valve's Source : HL2 Mapping

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»