Scripts / Resident Evil Style Text

Author
Message
Carlitooox
8
Years of Service
User Offline
Joined: 21st Sep 2016
Location:
Posted: 14th Oct 2016 22:10
i want to make a script, so i can have a background history in my game
i found this one on line but it doesn´t work
any help or suggestion would be apreciated
note_sonic=0
--START OF FRAME
function sparck_note_init(e)
note=0
stop=0
end

--ALWAYS--
function

PrompTextSize(3)

PlayerDist=GetPlayerDistance(e)
if(Player<100) and glayerHealth>0 then
GetEntityPlayerVisibility(e)
if 1 then


Prompt ("Press E to Read Note")
--ON PRESS E SHOW Note
if g_KeyPressE == 1 and note == 0 then

note = note + 1
PlaySound(e,0)
FreezePlayer(e)
--LookAtPlayer(e)--

end
if note > 0 then
note = note + 1

Text(28,40,1, "nota")



end

--end get dist
end
end
PM
TazMan
GameGuru TGC Backer
13
Years of Service
User Offline
Joined: 20th Jan 2011
Location: Worldwide Web
Posted: 16th Oct 2016 14:03
Well this does what I think you want. I have made a couple of minor changes to it but it is essentially the same. You need to think what to do after the note is showing otherwise this script shows the note and freezes the character and then you cannot do anything else.

I would think about have a timer for the note so that it gives time for the player to read it and then when read the player gets unfrozen and the note gets put away.



Hope this helps.
HP Pavilion Laptop - AMD A8-4555M APU with Radeon(tm) HD Graphics - 1.6GHz, 8GB Memory, Windows 10 Home, 64-bit Operating System.

I've got something to say - It's better to burn out than fade away.
TazMan
GameGuru TGC Backer
13
Years of Service
User Offline
Joined: 20th Jan 2011
Location: Worldwide Web
Posted: 16th Oct 2016 16:52
Here is another version where it gives a time limit to read the message and if you go back to it, it will tell you that it has been read before as well as show the message.

HP Pavilion Laptop - AMD A8-4555M APU with Radeon(tm) HD Graphics - 1.6GHz, 8GB Memory, Windows 10 Home, 64-bit Operating System.

I've got something to say - It's better to burn out than fade away.

Login to post a reply

Server time is: 2024-12-22 22:07:38
Your offset time is: 2024-12-22 22:07:38