Banner

Repeat

End

Forums

HavenForts: Construct JetFists - The Chronicles of Wargasm (Episode 2, NeoForts)
  #1  
Old 05-15-2005
KmartSquirrel
Guest
 
Posts: n/a
Default Freezing objects

I've tried a whole bunch of different ways to freeze objects the way you guys freeze them in soucreforts but I can't for the life of me get it to work, you wouldn't mind explaining how to do it would you?
Reply With Quote
  #2  
Old 05-17-2005
jlf's Avatar
jlf jlf is offline

Fort Warrior
 
Join Date: Apr 2005
Location: BNG-TQ2402076524
Posts: 1,182
Send a message via ICQ to jlf Send a message via AIM to jlf Send a message via MSN to jlf
Default

I use the IPhysicsObject's EnableMotion() function, called from a function I added to CBaseEntity called ToggleFreeze(). Of course, not all classes should be freezable, so you want to add a boolean that defaults to false, but can be set to true in a class's Spawn() function.
__________________

"If they rape and kill me, I hope they kill me first. That way, I sort of win."
Reply With Quote
  #3  
Old 05-19-2005
KmartSquirrel
Guest
 
Posts: n/a
Default thanks

I'll try that... thanks, after i get a chance to try it I'll come back and tell you if it worked, love your mod by the way lol
Reply With Quote
  #4  
Old 05-19-2005
Master Craftsman
 
Join Date: May 2005
Posts: 555
Send a message via AIM to WillyDavidK Send a message via MSN to WillyDavidK
Default

I havn'et coded for hl2 before, but I do know that you can use ent_fire [physobjname] enablemotion/disablemotion. Just wondering how that all works in.

Welding is also done with ent_fire [physobjname] setparent [physobj to weld to] or ent_fire [physobjname] clearparent. But it's extremely buggy.

Just another note, I have no idea how it works into coding the weapons, but it's a nice tip when you are playing with your friends and want to freak them out ^_^.
Reply With Quote
  #5  
Old 05-19-2005
jlf's Avatar
jlf jlf is offline

Fort Warrior
 
Join Date: Apr 2005
Location: BNG-TQ2402076524
Posts: 1,182
Send a message via ICQ to jlf Send a message via AIM to jlf Send a message via MSN to jlf
Default

That's not coding, WillyDavidK .
__________________

"If they rape and kill me, I hope they kill me first. That way, I sort of win."
Reply With Quote
  #6  
Old 05-19-2005
Fort Warrior
 
Join Date: Apr 2005
Posts: 1,072
Default

He's right coding uses varients timer and object, etc... Coding sounds really hard, I only coded a little in flash but I think it uses the same sort of way to code.( Well I mean it has some commands that is the same.)
Reply With Quote
  #7  
Old 05-20-2005
colt527
Guest
 
Posts: n/a
Default

Flash coding compared to HL2 mod coding is very far apart in theory. The only part that is sort of similar is the syntax. Most of the flash code along with many other new languages (PHP, JAVA) are all based on C++. That is what is used for HL2 Mods. I'm sure jlf could give you a more in depth response because my knowledge is limited to C++ and general 3d game programming. Ive only briefly delt with HL2 modding.

An hl2 mod is made up of a lot of .cpp and .h files. Each have their own purpose that they serve in the mod. For example there might be a file to handle the weapon values, to hand player movement, ect. You have to modify these files to create what you call your mod. I think the biggest difference from flash, is that there is no Graphical end to it. You can not see what you are doing other then what you are imagining the code that you are righting is going to do when you run it. You are not simply adding code to give an object action, you need to code every step of handling the object.
Reply With Quote
  #8  
Old 05-20-2005
Experienced Builder
 
Join Date: Apr 2005
Posts: 381
Send a message via ICQ to [ICR] Send a message via AIM to [ICR] Send a message via MSN to [ICR] Send a message via Yahoo to [ICR]
Default

I think it's more generaly termed that they are derrived from C, not C++. It seems to me the similarities to C are all much the same, but the differences (including C++) are all based on the purpose as to why the language was designed. But I may be wrong there.
I think also you would term Flash more a scripting language ( http://en.wikipedia.org/wiki/Scripting ) And yes, the source for HL are comprised of class and header files (to help organisation. You could probably theoretically put them all in one file. But that would make navigation rediculous) which are compiled into the dll.
The skills necessary to program mods for HL can be split into two broad catagories, syntax knowladge and structure knowladge. If you are familiar with a C derrived language (or the general concepts of similar programming languages) then you will be able to understand alot of what the code is doing through understanding the syntax, and easily be able to write valid code. However, the SDK's, as mentioned, are of a particular style and structure. You need to be able to grasp how the different componants fit together, and then plug into the engine to work as a whole. You need to understand how they have structured the componants accordingly etc. Alot of it is similar to how any SDK or API is written, some of it is unique and will be picked up through examination.
So while you may be familiar with the syntax, you may not be so familiar with the structure. Saying that, certainly the SDK for the first Half-Life (I don't know about the second) is fairly easy to pick up if you have a vague ideas as to what you are doing.
__________________
Reply With Quote
  #9  
Old 05-20-2005
jlf's Avatar
jlf jlf is offline

Fort Warrior
 
Join Date: Apr 2005
Location: BNG-TQ2402076524
Posts: 1,182
Send a message via ICQ to jlf Send a message via AIM to jlf Send a message via MSN to jlf
Default

I learnt C++ from the HL SDK. It's not similar to Flash, Java or really many other C++ SDKs - except for other games. However, it's the perfect introduction to object-oriented programming: Because every object has a visual representation in the world, it's easy to get your head around. Start by changing the small things - weapon behaviours, etc., and see the effects in the world.
__________________

"If they rape and kill me, I hope they kill me first. That way, I sort of win."
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 01:38 AM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.6.0

Tab