Jump to content

Need help with single player map


Go to solution Solved by MagSul,

Recommended Posts

Quote

On Windows Vista and above, you have to right-click Radiant and choose "Run as administrator" or it will be unable to save map files

Got it, thanks it's working now.

Do sound files have a specific way that it needs to be other a wav format?

Also is the surfacepram nonsolid something that you apply in the brush settings?

Link to comment

Sound files must be mono, and I think they have to be sampled at 44.1 KHz.

Surfaceparms are all applied in shaders, outside of Radiant.

Also, if you are trying to make a nonsolid wall, make sure all non-visible sides of it use textures/system/nodraw. This will ensure it is always nonsolid when your map is compiled, and it will prevent the nonsolid sides from culling adjacent planes, making visible holes in the map.

Link to comment
Quote

Sound files must be mono, and I think they have to be sampled at 44.1 KHz.

Got it, thanks.

Quote

Also, if you are trying to make a nonsolid wall, make sure all non-visible sides of it use textures/system/nodraw. This will ensure it is always nonsolid when your map is compiled, and it will prevent the nonsolid sides from culling adjacent planes, making visible holes in the map.

So this forcefield:

Screenshot-2023-04-03-175152.png

With the nodraw on the other side, isn't nonsolid. Is there a specific compile option that will make this nonsolid?

 

Link to comment
9 minutes ago, undeadslayer said:

With the nodraw on the other side, isn't nonsolid. Is there a specific compile option that will make this nonsolid?

There are no compile options, it is simply a matter of using nonsolid shaders.

My understanding of it is that during compile, q3map2 will pick a random face from each brush and use that face's nonsolid property. So if you want to ensure the brush is nonsolid every time, all 6 faces of the brush must use a nonsolid shader. Nodraw fits the bill for the non-visible sides. Make sure your force field has a shader with surfaceparm nonsolid in it.

Link to comment

You may want to look up how to create custom shaders, it will help tremendously.

You'll have to find which shader file contains the parameters for that shader and check it manually. I think if you shift+click it in the texture window, Radiant should open the associated shader in Notepad or whatever. If the shader is not nonsolid (And it probably isn't), copy it into a custom shader of your own and edit it however you need.

Also, if you do create one, don't forget to add it to shaderlist.txt and restart Radiant so you can see it.

Link to comment
  • 5 months later...

I'm having trouble getting the game to fire my script upon starting the level, it seems to ignore it. The  script is supposed to remove the players force powers and give weapons.

Here's what the script reads:

//Generated by BehavEd

rem ( "startscript" );
rem ( "set up force powers and weapons" );

affect ( "player", /*@AFFECT_TYPE*/ FLUSH )
{
    set ( /*@SET_TYPES*/ "SET_FORCE_GRIP_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_HEAL_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_JUMP_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_LIGHTNING_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_MINDTRICK_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_PULL_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_PUSH_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_SPEED_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_PROTECT_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_ABSORB_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_RAGE_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_SIGHT_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_DRAIN_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_SABER_DEFENSE", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_SABER_OFFENSE", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_SABER_THROW", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_NONE" );
    set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_MELEE" );
    set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_BLASTER_PISTOL" );
}

Is there something wrong with script? If not the script then maybe something in the map editor. Here's how I have scriptrunner in the map editor:

image.png.a95b4b7cf32adb10a850c5f00cd37a01.pngimage.png.4f1fb0a3e455df9290df0fd493310608.png

Any help would be appreciated.

Link to comment

I don't work with single player, so this might be wrong, but I believe you can remove the "Affect" block, and check the "runonactivator" flag on the target_scriptrunner. I can verify that it does work that way in multiplayer.

To further troubleshoot, I would add a few print blocks to the script, set /developer 1 in-game, and see if the prints show up in the console. That should help you determine exactly where the failure is.

Link to comment
Quote

I don't work with single player, so this might be wrong, but I believe you can remove the "Affect" block, and check the "runonactivator" flag on the target_scriptrunner. I can verify that it does work that way in multiplayer.

To further troubleshoot, I would add a few print blocks to the script, set /developer 1 in-game, and see if the prints show up in the console. That should help you determine exactly where the failure is.

I just did what you suggested no affect what so ever. Also the script has now changed:

//Generated by BehavEd

//$"rem"@24
set ( /*@SET_TYPES*/ "SET_FORCE_GRIP_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_HEAL_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_JUMP_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_LIGHTNING_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_MINDTRICK_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_PULL_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_PUSH_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_SPEED_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_PROTECT_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_ABSORB_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_RAGE_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_SIGHT_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_FORCE_DRAIN_LEVEL", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_SABER_DEFENSE", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_SABER_OFFENSE", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_SABER_THROW", /*@FORCE_LEVELS*/ "0" );
set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_NONE" );
set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_MELEE" );
set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_BLASTER_PISTOL" );
set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_BLASTER" );
set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_THERMAL" );
set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_REPEATER" );
set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_DEMP2" );
print ( "/developer1" );
Would it help you to see what script the original DF Mod  did?

Link to comment

/developer 1 is a CVar that needs manually typed into the in-game console, not added to the script. It will show the execution of the script as it goes, making troubleshooting much easier.

 

7 minutes ago, undeadslayer said:

Would it help you to see what script the original DF Mod  did?

It likely won't help me very much, but it could help someone more experienced with single player scripts to determine the problem. If you're using something as a template, I would suggest reverting to that method, since ultimately I'm just shooting from the hip.

The suggestion for /developer 1 and the print blocks remains a good idea, though.

Link to comment
Quote

/developer 1 is a CVar that needs manually typed into the in-game console, not added to the script. It will show the execution of the script as it goes, making troubleshooting much easier.

So I typed /developer1 into the console, then reloaded the level again. The script is still not firing, also I noticed something about the in-game console that I don't believe is there usually in single-player.  It said: server: executor                                                                                                                                                                                                                                                                                                                                                                                      ----- Game Initialized ----------

exactly what the in game console would say if you joined a multiplayer server. Something else I noticed that is not supposed to be happening yet but is, the DF Kyle model is the player model and not Female Jaden.

Here is the script from the first level of the mod:

//Generated by BehavEd

rem ( "startscript" );
rem ( "set up force powers and weapons" );
affect ( "player", /*@AFFECT_TYPE*/ FLUSH )
{
    set ( /*@SET_TYPES*/ "SET_FORCE_GRIP_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_HEAL_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_JUMP_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_LIGHTNING_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_MINDTRICK_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_PULL_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_PUSH_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_SPEED_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_PROTECT_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_ABSORB_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_RAGE_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_SIGHT_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_FORCE_DRAIN_LEVEL", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_SABER_DEFENSE", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_SABER_OFFENSE", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_SABER_THROW", /*@FORCE_LEVELS*/ "0" );
    set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_NONE" );
    set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_MELEE" );
    set ( /*@SET_TYPES*/ "SET_WEAPON", /*@WEAPON_NAMES*/ "WP_BLASTER_PISTOL" );
    set ( /*@SET_TYPES*/ "SET_OBJECTIVE_SHOW", /*@OBJECTIVES*/ "SECBASE_OBJ1" );
    set ( /*@SET_TYPES*/ "SET_OBJECTIVE_SHOW", /*@OBJECTIVES*/ "SECBASE_OBJ2" );
    set ( /*@SET_TYPES*/ "SET_OBJECTIVE_SHOW", /*@OBJECTIVES*/ "KOR1_OBJ1" );
    set ( /*@SET_TYPES*/ "SET_OBJECTIVE_SHOW", /*@OBJECTIVES*/ "KOR1_OBJ2" );

    if ( $get( FLOAT, "SET_SKILL") = 0$ )
    {
        set ( /*@SET_TYPES*/ "SET_ARMOR", 200 );
    }

    else (  )
    {
        if ( $get( FLOAT, "SET_SKILL") = 1$ )
        {
            set ( /*@SET_TYPES*/ "SET_ARMOR", 100 );
        }
    }
}
affect ( "st_guard1", /*@AFFECT_TYPE*/ FLUSH )
{
    set ( /*@SET_TYPES*/ "SET_IGNOREALERTS", /*@BOOL_TYPES*/ "true" );
    set ( /*@SET_TYPES*/ "SET_VISRANGE", 512.000 );
    set ( /*@SET_TYPES*/ "SET_EARSHOT", 256.000 );
    set ( /*@SET_TYPES*/ "SET_NO_COMBAT_TALK", /*@BOOL_TYPES*/ "true" );
}

affect ( "st_guard2", /*@AFFECT_TYPE*/ FLUSH )
{
    set ( /*@SET_TYPES*/ "SET_IGNOREALERTS", /*@BOOL_TYPES*/ "true" );
    set ( /*@SET_TYPES*/ "SET_VISRANGE", 512.000 );
    set ( /*@SET_TYPES*/ "SET_EARSHOT", 256.000 );
    set ( /*@SET_TYPES*/ "SET_NO_COMBAT_TALK", /*@BOOL_TYPES*/ "true" );
}

declare ( /*@DECLARE_TYPE*/ FLOAT, "elev3" );
set ( "elev3", "0" );
declare ( /*@DECLARE_TYPE*/ FLOAT, "elev4" );
set ( "elev4", "0" );
declare ( /*@DECLARE_TYPE*/ FLOAT, "elev5" );
set ( "elev5", "0" );
declare ( /*@DECLARE_TYPE*/ FLOAT, "elev2_upon" );
set ( "elev2_upon", "0" );
declare ( /*@DECLARE_TYPE*/ FLOAT, "elev2_r" );
set ( "elev2_r", "0" );
declare ( /*@DECLARE_TYPE*/ FLOAT, "rotatesecrethalf" );
set ( "rotatesecrethalf", "0" );

affect ( "gen_pipe", /*@AFFECT_TYPE*/ FLUSH )
{
    set ( /*@SET_TYPES*/ "SET_SHADER_ANIM", /*@BOOL_TYPES*/ "true" );
    set ( /*@SET_TYPES*/ "SET_ANIMFRAME", 0 );
}

affect ( "fly", /*@AFFECT_TYPE*/ FLUSH )
{
    set ( /*@SET_TYPES*/ "SET_INVISIBLE", /*@BOOL_TYPES*/ "true" );
}

affect ( "fly_hull", /*@AFFECT_TYPE*/ FLUSH )
    {
    move (<0 0 0>, <0 0 1000>, 0 )
    }
 

Link to comment
  • 4 weeks later...
  • 1 month later...

I'm having a problem with the game not not transitioning to briefing menu. I'm getting this error in the game:

image.jpeg.b7ff6e36c3e292fa14c1c11d258461c8.jpeg

same thing happens trying to transition to the robotics level. Both of the briefings are listed in the menu.txt and ingame.txt documents in the pk3, and so are the files for the levels. Why is this not working? any help would be appreciated.

Link to comment
  • 3 weeks later...
Guest
This topic is now closed to further replies.
×
×
  • Create New...