Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

some scripting questions

Page: 1 of 1
 snife
08-24-2004, 5:01 AM
#1
hi,,, again
i wanna make some scripts but i donno how,

1. how shall i setup the script in the map?
like give the thing i want to be affected a targetname?
if so then what targetname? scripttargetname?

2. i wanna make a script that makes some npcs to follow u,,, and
chance the team_player stuff to team_enemy

3. and i thing that i think every mapper wanna make,,,
a password-door
but i donno if thats possible in JAMP or JASP
but it was done in JO,,,, think

btw i wanna know if its possible of MP or just SP!


any help welcome!
 lassev
08-24-2004, 5:47 AM
#2
1. If you want to affect a brush entity, use script_targetname. If you want to affect an NPC, use NPC_targetname.

2. Team_player normally follows the player. Team_neutral just stands there, doing nothing unless you attack him. Team_enemy of course attacks right away. The set_leader command can be used to set the entity to be followed. I have no idea how these work in MP.

3. What do you mean by password protected door? Elaborate.
 Shadow_stone
08-24-2004, 9:04 AM
#3
lassev did ever play JO? you remember at kejim post? u had to enter a password or a set of passwords to move on, (u had to get the right "picture"

anways i dont know if u remember but i think thats what hes talking about (like a combo lock)
 zag
08-24-2004, 10:51 AM
#4
for that level im guessing they used a func_usable with a shader that changes everytime it is used. i guess if you know what shader it starts at and how many till the right one you could use a target_counter to fire something when its at the correct frame and another target_counter to fire if it goes back past that frame..
do that for each 'coloured picture' use a setup of trigger_multiples that start infront of the door and end up firing the door then you could use target_activate and target_deactivate to turn off each trigger_multiple

that sounds complex, do you need me to draw a diagram?
 lassev
08-24-2004, 11:06 AM
#5
Originally posted by Shadow_stone
lassev did ever play JO? you remember at kejim post? u had to enter a password or a set of passwords to move on, (u had to get the right "picture"

anways i dont know if u remember but i think thats what hes talking about (like a combo lock)

Yeah. I built quite a similar system for my own JO SP level, actually. Although I didn't use target_counters but somewhat advanced scripting. Still, the scripting was way easier than zag's method, although maybe not suitable for MP.
 snife
08-24-2004, 11:36 AM
#6
with password-door i ment like this:
some1 can chance the password
then when u press a button then u must enter that password
and then if its correct u will be possible to enter a room or something

for that level im guessing they used a func_usable with a shader that changes everytime it is used. i guess if you know what shader it starts at and how many till the right one you could use a target_counter to fire something when its at the correct frame and another target_counter to fire if it goes back past that frame..

i allready knowed that,

2. Team_player normally follows the player. Team_neutral just stands there, doing nothing unless you attack him. Team_enemy of course attacks right away. The set_leader command can be used to set the entity to be followed. I have no idea how these work in MP.

that wasnt really what i was recuested,

i wanna make like a "npc's-love-u -button"
like it chances some npcs like a reborn to not kill u,,, and the follow u and kill every1 near u!
like a body guard
and its going to be in MP
 lassev
08-24-2004, 2:36 PM
#7
Originally posted by snife

that wasnt really what i was recuested,

i wanna make like a "npc's-love-u -button"
like it chances some npcs like a reborn to not kill u,,, and the follow u and kill every1 near u!
like a body guard
and its going to be in MP

It indeed was what you requested, because those things can be controlled with ICARUS. But anyway, you are probably out of luck in MP, so it really doesn't matter.
 snife
08-25-2004, 2:21 PM
#8
cant i even make then to follow u?
or to follow a brush or anything?!
i know that it can be done, i saw a forum that some1 made a script making some stormtroopers to follow a stormofficer
but i dont just wanna make that,,, i wanna make spawn npc's to follow u to,

can it be done?
 snife
08-25-2004, 3:47 PM
#9
okey,,, so heres another question!
i wanna make a npc that u cant see,,,
and it should have a small model ,,, cuz i wanna have it like a sooter_blaster but that it has the player/npc's/bots as targets
i wanna make:
1 that can move and 1 that cant move
so im wondering how do i script it or how should i do?


sry for my bad english
 shukrallah
08-25-2004, 10:25 PM
#10
I scripted some stormtroopers following a stcommander in a cutscene...

The thing is, those troopers were not really following him, they were walking to there own nav_goal, which was behind the commander, so it appeared like they were following him.

Just set up nav_goals, and script NPCs walking to them in a -1 loop. Put a commander in front of him so people think they are following the commander ;)

As for your last post... I really.. didn't understand it/the point...
 lassev
08-26-2004, 7:07 AM
#11
Well, the basic problem in MP is that the players are not identifiable, as far as I know (which might be wrong, since I don't map MP). To set a leader, you need an identification of the leader. I'm not sure how the alignments (teams) work in MP. Maybe team_player NPC will follow one group of the players, and team_enemy the other group.

What I really don't understand, however, is why you are only asking questions and not trying out the offered solutions at all. We can speculate here for all eternity and then some, without any progress, if you don't go forward and try something out.

And I agree with lukeskywalker1: I don't understand your last post.
 snife
08-26-2004, 9:03 AM
#12
i wanna make a npc that u cant see,,,
and it should have a small model ,,, cuz i wanna have it like a shooter_blaster but that it has the player/npc's/bots as targets

i meen that i wanna have a shooter_blaster that shots on the player and/or npc's.

or if there is like a small model that looks like a remote_droid
that can move and shot blaster-shots at the player,,,

i donno how i should do it :(
maybe with a stormtrooper that is 1inch but then i need to make a new skin that u cant see,,,

yea whatever ill try self thx for all help :P
 shukrallah
08-26-2004, 5:51 PM
#13
Make the stormtrooper, press N and click non-solid, then.. make a script that affects that NPC (it will need an NPC_targetname)

Give the script these commands:

//(BHVD)

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


Then the stormtrooper will be invisible, and will shoot at people...

If thats not what you want... then.. I am not sure. You could make a turret, they shoot at everyone ;)
 snife
08-27-2004, 1:01 PM
#14
Originally posted by lukeskywalker1
Make the stormtrooper, press N and click non-solid, then.. make a script that affects that NPC (it will need an NPC_targetname)

Give the script these commands:

//(BHVD)

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


Then the stormtrooper will be invisible, and will shoot at people...






thx,,, that was what i wanted!








Originally posted by lukeskywalker1

You could make a turret, they shoot at everyone


what do u meen? can u make a turret nonsolid?

and btw what turrets is it in MP?




Thanx for all the help! :D :lurkblast
 snife
08-27-2004, 1:04 PM
#15
BTW!
how do u make the script to run?'
or is it automatic?
 shukrallah
08-27-2004, 10:21 PM
#16
OK:


Make a target_scriptrunner (in radiant) Check under the menus, its listed under "targets" or something.

Press N, then type in

Usescript
scripts/your_script_folder/script_name


Then, deselect everything. Highlight a player, and connect it to the scriptrunner. You will need to do with each "player" individually. (Highlight the info_player_start 1st, then the scriptrunner, and press ctrl+K) do this with every player entity (info_player_deathmatch, info_player_duel etc...)

The script should run.


As for the turrets, check the siege_hoth map, they are those guns hanging on the ceiling that shoot at the imperials. I guess you don't need them now...
 snife
08-29-2004, 7:37 AM
#17
2 more questions:

1. how can i make a script to fires more than 1 time?
i wanna have a thing so u can set a stormtrooper to be invisible and then back to visible again,,,, and a rancor that doesnt attack the player.
and i wanna make so i can chance the rancor back again!

and can i make a trigger that makes the player/npc to make a animation?
and that allso need to be fired more than 1 time,,,,

all this is for MP

thx for all help btw
 snife
09-11-2004, 1:49 AM
#18
why isnt anyone posting back?
and btw can you make so that a npc chances to another npc,
cuz that would be great for my map,
its like a starship where everything can be possible,
i've made a friendly rancor and allso a mini-rancor
but i still cant get the sentry to work!
i just want a friendly, small sentry that could work like a seeker/remote,
but can u chance so that u can use a seeker/remote in MP in the source?

plz answer!
Page: 1 of 1