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 / Simple Texture Change - If Used -

Author
Message
Wiseberry12851
15
Years of Service
User Offline
Joined: 2nd Jun 2009
Location: Some Parallel Universe
Posted: 15th Jun 2009 09:47
The script below changes the texture to alternate texture if activated by anything such as a switch and then back to first texture upon deactivation

It is a main script that will have no function but to initiate a texture change, also useful for non functional devices such as computer monitor and signs changing upon trigger or switch

Whenever your using triggers such as spawning, switches, remote doors, use the script on the item you want only to change textures and set the texture and alt texture naming same name as If Used name or Trigger name

You can optionally just have a switch, button, etc... only to control texture change, it's your game...

========================================
;Artificial Intelligence Script

;Header

desc = Simple Texture switch based on activation in If Used

;Triggers

:state=0,activated=1:state=1,alttexture=1
:state=0,activated=0:state=1,alttexture=0
:state=1:state=0
;End of Script

=====================================

File is attatched

---------------------------------------
Advanced Licensed Computer Programmer and Custom Programming Language Interfacing. Graphics / Video Designer.

Attachments

Login to view attachments
Leon Kennedy
16
Years of Service
User Offline
Joined: 7th Sep 2008
Location: Neither here nor there
Posted: 15th Jun 2009 18:31
you don't necessarily need to move to state 1. your script would be cleaner like...



Doing it this way makes the code easier to read and cleans it up a bit. Still pulls off the same effect.

Priest of the Church of Joe Wood

In memory of Nanee. 9/1/1993 - 5/16/2009. Rest in Peace, little girl.
Wiseberry12851
15
Years of Service
User Offline
Joined: 2nd Jun 2009
Location: Some Parallel Universe
Posted: 29th Jun 2009 08:07
After brushin up on my scripting you really can just remove states as this script purpose has no other purpose but to alternate textures



---------------------------------------
Advanced Licensed Computer Programmer and Custom Programming Language Interfacing. Graphics / Video Designer.

Login to post a reply

Server time is: 2024-11-25 02:24:14
Your offset time is: 2024-11-25 02:24:14