Jump to content
The Dark Mod Forums

Drumple's Potions


Springheel

Recommended Posts

I've added drumple's potions to CVS. He sent me some def files but I have no idea what to do with them. Thought I'd post them here for now.

 

i changed a def file and added a new one to make them selectable from the darkmod/item area in the doom3 editor, here

are the defs

 

entityDef darkmod_item_healthpotion

{

"inherit" "darkmod_item_default"

"editor_color" ".3 .3 1"

"editor_mins" "-16 -16 0"

"editor_maxs" "16 16 32"

 

"editor_usage" "Healthpotion"

 

"spawnclass" "idItem"

"model" "models/darkmod/player_equipment/healthpotion.lwo"

"size" "32 32 32"

"inv_name" "Healthpotion"

"inv_health" "25"

"inv_item" "2"

"snd_acquire" "sound/sfx/tools/tool_pickup02.ogg"

"nopulse" "0"

}

 

entityDef darkmod_item_holywater

{

"inherit" "darkmod_item_default"

"editor_color" ".3 .3 1"

"editor_mins" "-16 -16 0"

"editor_maxs" "16 16 32"

 

"editor_usage" "Healthpotion"

 

"spawnclass" "idItem"

"model" "models/darkmod/player_equipment/holywater.lwo"

"size" "32 32 32"

"inv_name" "Holywater"

"inv_health" "25"

"inv_item" "2"

"snd_acquire" "sound/sfx/tools/tool_pickup02.ogg"

"nopulse" "0"

}

 

thats if you want to see them as frobable items, however there is no scripting at the moment to make

them work obviously, but they will hilight when you look at them.

Link to comment
Share on other sites

Even so, whether someone later has to make a separate def file for their new potion, or add it at the bottom of an existing 'potions' def file is hardly much of a concern.

Civillisation will not attain perfection until the last stone, from the last church, falls on the last priest.

- Emil Zola

 

character models site

Link to comment
Share on other sites

Hell a FM maker can just make a new def file containing his own potions. Realistically speaking all of the def files could be just one file (unless there's specific script calls or whatever for a particular file), they're mainly split for organization.

Link to comment
Share on other sites

just read this topic, the def file is to make the potions frobable, but the way the frob entity is setup seems

to me, that it can only be used by individual map scripts.

 

if activating a frob entity ingame could then use a scriptobject ( as an option ) then that type of frob entity

would be not dependent on any script map, and would be part of the darkmod system to automaticly add

to inventory or get used right away.. depending on the script.

 

actually.. that would be best for most types of frob items, such as gold.. ect.. so no map script is needed.

i was going to try to make a scriptobject to automaticly add up any gold/valuable items up but the way it works

now, it has to be scripted for a map, which means any map would have to have the same script added, when

doing such things should be a single scriptobject that covers it all, and all an fm mapper would have to do is

drop the item where they want in the map and not worry about the scripting part for it.

 

if you see what i mean...

 

like the darkmod doors.

 

but basicly.. if you add those def's to the darkmod item def file, you can select the potions from the menu in

the editor and place them where you want, and they can be frobable... but of course.. not added to inventory

yet, which has to be worked on still. you could make a script for your map to add them to inventory, but like

i mentioned, it would be better if you did not have to and had a scriptobject to cover that.

 

EDIT: screen showing the 2 potions selectable after adding the def files, and a potion normal then

frobbed.

 

potfrob19zn.jpg

Link to comment
Share on other sites

just read this topic, the def file is to make the potions frobable, but the way the frob entity is setup seems

to me, that it can only be used by individual map scripts.

 

That's going to be changed in the next alpha release AFAIK, frobbing things should check for local scripts first and then only check global scripts if it can't find the local one.

Link to comment
Share on other sites

Actually, you don't need to wait for that to be implemented to add frobable items, though you may want to change the scripts once local function calls are added.

 

Just make a global function for your object... For example:

object DarkMod_Item_Potion
{
void init();
void frob();

float myFunc( float blah );

float myVal;
};

etc

void DarkMod_Item_Potion_Frob( entity e )
{
DarkMod_Item_Potion p = e;
if (p)
	p.frob();
else
	sys.warning("Unable to cast entity to DarkMod_Item_Potion.");
}

Then you set the frobaction to "DarkMod_Item_Potion_Frob".

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • datiswous

      I tried to upscale the TDM logo video. First try:

      briefing_video.mp4 You can test it ingame by making a copy of the core tdm_gui.mtr and place it in your-tdm-root/materials/ , then edit line 249 of that file into the location where you placed the new briefing.mp4 file.
      What I did was I extracted all the image files, then used Upscayl to upscale the images using General photo (Real-Esrgan) upscale setting and then turn it back into a video.
      I might have to crop it a bit, the logo looks smaller on screen (or maybe it's actually better this way?). My video editor turned it into a 16:9 video, which I think overal looks better than 1:1 video of original.
      · 1 reply
    • nbohr1more

      Trying to be productive on my down-time before Capcom releases Akuma and my son is constantly on my PC playing Street Fighter...
      · 1 reply
    • OrbWeaver

      Finally got round to publishing a tutorial on baking normal maps in Blender, since most of the ones we have are inaccessible or years out of date.
      · 2 replies
    • nbohr1more

      The FAQ wiki is almost a proper FAQ now. Probably need to spin-off a bunch of the "remedies" for playing older TDM versions into their own article.
      · 1 reply
    • nbohr1more

      Was checking out old translation packs and decided to fire up TDM 1.07. Rightful Property with sub-20 FPS areas yay! ( same areas run at 180FPS with cranked eye candy on 2.12 )
      · 4 replies
×
×
  • Create New...