Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / Random Hud Positions

Author
Message
Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 25th Mar 2009 20:24
Looking through my FPI editpad, I noticed that there aren't any random hud placement actions.

Does anyone know how to make one? Thanks in advance
Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 26th Mar 2009 00:03 Edited at: 28th Mar 2009 20:08
I'm really having some trouble, can someone help?

Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 26th Mar 2009 09:41
"random" is not an action, it is a condition so put it before the second colon. Also, if only one of those is supposed to display, then put the ",state=1" part at the end of all of those lines.


The one and only,


Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 26th Mar 2009 17:23 Edited at: 26th Mar 2009 21:06
Okay, I did what you advised ply, and this is what came up with:



Is this how it should look? I want my script to randomly choose one of those HUD co-ordinates.
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 27th Mar 2009 01:18
Well, when the game starts off, as soon as it hits state 1, if you're not within 100 units of it, it's going to go to state 4 and destroy itself, meaning it'll never happen once you get there.

I suggest taking out the "distfurther" line and the state 4 line. That would do the trick.


The one and only,


Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 27th Mar 2009 03:13 Edited at: 27th Mar 2009 04:19
I don't really want to take it out completely. I changed the script a bit more so please tell me If it's incorrect.

I havn't been posting my whole script so I think it would help you understand a bit more if I did.



The purpose of this script, is to leave the corpse of the enemy after displaying the blood on the screen at a random co-ordinate but only if the player is within a certain distance from the enemy.

If it's possible to keep the plrdisfurther part, please tell me how.
Keo C
17
Years of Service
User Offline
Joined: 3rd Aug 2007
Location: Somewhere between here and there.
Posted: 27th Mar 2009 04:33


The second line is pretty much redundant and really serves no purpose other than to go right to state=6 and destroy..

plrdistwithin=100 is false when plrdistfurther=100 is true anyway, this should keep it at state=2 until both conditions are true if you edit out the line.




The above code should work fine. I'm not sure what state=3 and state=4 are for, but this should produce the desired effect.


Image made by the overworked Biggadd.
Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 27th Mar 2009 04:39 Edited at: 27th Mar 2009 04:44
Thanks. State 3 and 4 are supposed to make the Hud fadeout after a certain amount of time.

I just tested the script you provided, and nothing happens except for leaving the entity's body on the floor.
Keo C
17
Years of Service
User Offline
Joined: 3rd Aug 2007
Location: Somewhere between here and there.
Posted: 27th Mar 2009 05:56
Then you need to trigger state=3 and state=4 before you go to state=6

I could provide some code tomorrow, it's pretty late tonight.


Image made by the overworked Biggadd.
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 27th Mar 2009 08:22
You're almost there, buddy. I see where you're going with this now. Great idea

In this case, you'll want to keep it there, BUT have it lead to state 6 instead of state 5. Now have your "plrdistwithin" line lead to state 3, and on your state 4 line change "destroy" to "state=6". That will make the script lead to a suspension, which will leave the corpse on the ground.


The one and only,


Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 27th Mar 2009 21:22 Edited at: 27th Mar 2009 21:24
Thanks, I changed my plrdistanceiwthin part as you suggested.

Quote: "In this case, you'll want to keep it there, BUT have it lead to state 6 instead of state 5"


What am I keeping and what am I changing? I have no "case=5" in my script Only 2,3,4 and 6
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 27th Mar 2009 22:07
Ah, then you must have used the script Keo C put up. In that case, just change "destroy" to "state=6".


The one and only,


Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 27th Mar 2009 22:32 Edited at: 28th Mar 2009 20:05
Thanks. I'll post if I have any problems.

EDIT: Still not working. I'll try it without the random positions and see if it works.
Slim Fly
16
Years of Service
User Offline
Joined: 17th Mar 2008
Location:
Posted: 29th Mar 2009 05:51 Edited at: 29th Mar 2009 06:06
hmm, when I copied keo's script, I forgot that the forums remove the slashes in the file path.. So i never had them in there after I replaced my script XD

Login to post a reply

Server time is: 2024-11-24 23:12:35
Your offset time is: 2024-11-24 23:12:35