Page 2 of 4

Re: [u1]firetrucks.u

Posted: 05 Aug 2013, 12:43
by diamond
Once I made a very useful Trigger.
It can change ANY (well, maybe any editor-visible) property of actor, including Collision and Location. I used it for changing location, mostly: actors could move from hidden location to desired location easily, without messing with attaching to dummy movers. Works over the network, IIRC. You may want to modify the code to have arrays of properties/values to change at once.

[spoiler]

Code: Select all

//=============================================================================
// PropertyChanger.
//=============================================================================
class PropertyChanger expands Triggers;

var() Object AnObject;
var() string PropertyName;
var() string PropertyValue;
var() bool bSetLocation;
var() bool bSetRotation;
var() bool bFindByTag;
var() vector NewLocation;
var() rotator NewRotation;
var() bool bSetSelfLocation;
var() bool bSetCollision;
var() bool bNewColActors;
var() bool bNewBlockActors;
var() bool bNewBlockPlayers;

function Trigger( actor Other, pawn EventInstigator )
{
   Instigator = EventInstigator;
   gotostate('ChangeProp');
}

function ChangeProperties(Object target)
{
   if(PropertyName!="")
   {
      target.SetPropertyText(PropertyName, PropertyValue);
   }

   if(bSetLocation && !bSetSelfLocation)
   {
      Actor(target).SetLocation(NewLocation);
   }

   if(bSetSelfLocation)
   {
      Actor(target).SetLocation(Location);
   }

   if(bSetRotation)
   {
      Actor(target).SetRotation(NewRotation);
   }
   if(bSetCollision)
   {
      Actor(target).SetCOllision(bNewColActors, bNewBlockActors, bNewBlockPlayers);
   }
}

state ChangeProp
{
Begin:
   disable('Trigger');

   if(bFindByTag)
   {
      foreach AllActors( class 'Actor', Target, Event )
         ChangeProperties(Target);
   }
   else
   {
      ChangeProperties(AnObject);
   }

   enable('Trigger');
}
[/spoiler]

Re: [u1]firetrucks.u

Posted: 05 Aug 2013, 13:59
by Buff Skeleton
Nice, Diamond :tup: That is a really useful class; may take some pointers for EXU editor tools.

Re: [u1]firetrucks.u

Posted: 05 Aug 2013, 14:35
by diamond
I think it works only with editor-editable properties. Dunno if you can toggle warp zones with it. In case you can't you can use the following code.
That's all with useful bits from me :P. On the video, you can see that warp-zone in the door portal can be switched to different locations. It is possible to spice it up with any kind of effects, all is done via usual events.
[spoiler]

Code: Select all

//=============================================================================
// WarpChanger.
//=============================================================================
class WarpChanger expands Triggers;

var() string NewURL;
var WarpZoneInfo Target;
var WarpZoneInfo OtherSideActor;

function Trigger( actor Other, pawn EventInstigator )
{
   Instigator = EventInstigator;
   gotostate('ChangeProp');
}

state ChangeProp
{
Begin:
   disable('Trigger');

   foreach AllActors( class 'WarpZoneInfo', Target, Event )
   {
      Target.OtherSideURL = NewURL;
      //Target.Generate();
      foreach AllActors( class 'WarpZoneInfo', OtherSideActor )
      {
         if( string(OtherSideActor.ThisTag)~=NewURL && OtherSideActor!=Target )
         {
            Target.OtherSideActor = OtherSideActor;
            break;
         }
      }
   }

   enable('Trigger');
}

defaultproperties
{
}
[/spoiler]https://www.youtube.com/watch?v=gstW_92-mVM

Re: [u1]firetrucks.u

Posted: 05 Aug 2013, 22:04
by ebd
An extension to firetrucks is currently in development which will add the things which some argue should have been in the original package, like a TranslatorJournal and classic HUD. I will also add some new things.

Image

The scrolls came about because after making the closed scroll, someone said in IRC that an open one would be cool too. Then there was some discussion about how using the various actors in firetrucks it would be possible to implement an RPG-styled shop, but you'd have to use Tankards for currency because neither stock unreal or firetrucks had any money in them. And so it was decided that the official currency of firetrucks is the Tankard and coins were produced to allow people to now have to carry all those tankards around.

Originally when the gold coins were minted they were backed by "the pewter standard" which ensured the coins could be exchanged for pewter tankards on a 1-for-1 basis. In time though many more gold coins were produced than actual tankards, so the Tankard is now a fiat currency.

Re: [u1]firetrucks.u

Posted: 06 Aug 2013, 06:40
by TheIronKnuckle
just realised how handy this all would have been with my speedmap. devestated that I have no time for mapping these days when there are such cool tools around.

Nice naming of the new .u file btw :P

Re: [u1]firetrucks.u

Posted: 07 Aug 2013, 08:49
by []KAOS[]Casey
Just wanted to leave a note here that property changer won't work on non-227 versions with properties not defined on the class that is going to have changed properties.

For example, Health is defined in Pawn, so you can't use SetPropertyText on any subclass of Pawn. Yes, it's a bug. Yes, it's fixed in 227. No I don't know if it works in UT, I doubt it though. Easy to test.

This also applies to GetPropertyText.

It's almost as if... they didn't even test it.

Re: [u1]firetrucks.u

Posted: 07 Aug 2013, 11:44
by ebd
mini-update for today to try to get things back on topic

Image

current feature list of trashbag.u (note: not guaranteed to have everything on this this or be limited only to things on this list)
  • TranslatorJournal
  • TranslatorJournalUI
  • ClassicHUD A HUD for firetrucks that looks more like the stock unreal HUD.
  • TrashbagHUD Minor fixes to FiretrucksHUD to allow better use in combat and maybe fixing some netplay issues. Maybe.
  • Something to change HUD with triggers.
  • Probably some classes to make certain editor-related tasks more convenient.
  • Tankards Model and icon change automatically based on the amount of gold coins in the pile or in the player's inventory.
  • Corndog becuase they are delicious.
  • Hamburger prepared by the talented ividyon.
  • Various decorations and FiretrucksPickup equivalents.
  • TrashbagWeapon abstract weapon class that adds some neat features. Whether or not I'll actually get around to implementing any weapons is not known at this time.

The feature list is open to suggestions within reason.

Re: [u1]firetrucks.u

Posted: 07 Aug 2013, 13:55
by Buff Skeleton
Fat stacks yo

Re: [u1]firetrucks.u

Posted: 07 Aug 2013, 18:50
by []KAOS[]Casey
Corndogs are not delicious. You were not forced to eat them daily during summer when you were a kid. Fuck these particularly: http://c.shld.net/rpx/i/s/i/spin/image/ ... .9,0.5,0,0

Re: [u1]firetrucks.u

Posted: 09 Aug 2013, 11:07
by TheIronKnuckle
Interested in trashbagweapon. what enhancements do you have in mind?

Re: [u1]firetrucks.u

Posted: 10 Aug 2013, 02:50
by ebd
TheIronKnuckle wrote:Interested in trashbagweapon. what enhancements do you have in mind?
Right now I've implemented 1st person weapon swaying (based on Bleeder91's code, but heavily modified to be framrate independent and use a different algorithm.) It is hardly a mindblowing change but it is still a nice enhancement. I'm also thinking about doing some integration with the point and click stuff (so it would be possible to have combat during point and click sequences, kind of) but that might get involved. If you have other ideas or suggestions I'm open to them.

Re: [u1]firetrucks.u

Posted: 10 Aug 2013, 06:32
by Shivaxi
Just a note...the firetrucks.u that is available for download on the first post in this thread is horribly broken with 227j. Maybe it's fine with 227i, not sure. But a lot of the actors and functions in firetrucks causes 227j to hard freeze. (example, picking up the journal in the beginning of the firetrucks_example.unr map causes this hard freeze, along with some other things I tried.) I'll try to test on 227i and see if I get the same issues.

Re: [u1]firetrucks.u

Posted: 10 Aug 2013, 07:17
by ebd
Shivaxi wrote:horribly broken with 227j
I can't and won't support versions of 227 I don't have access to.

Re: [u1]firetrucks.u

Posted: 10 Aug 2013, 07:49
by Shivaxi
ebd wrote:
Shivaxi wrote:horribly broken with 227j
I can't and won't support versions of 227 I don't have access to.


roger that

Re: [u1]firetrucks.u

Posted: 10 Aug 2013, 13:47
by GTD-Carthage
What I'm about to suggest is kind of complex but I believe fits the bill of an RPG system. As usual though, its reception is debatable but I think it's worth a mention at least: :o

[spoiler]Weapon/monster variants with Diablo-like stat progression. (possibly done through some sort of external mutator that randomly modifies various inherent properties of spawned actors?)[/spoiler]