Jump to content

[Request] Toggleable campfires


Guest deleted2027229

Recommended Posts

Actually, the setangle doesn't work right. The fire gets rotated differently in the game than the CS. So, in the game it is at an odd angle. I tried console commands on it and can't get the fire to be upright in the game.

 

Maybe the solution is also the solution to PlaceAtMe. If you were to put several of those fires in a cell somewhere (like TestingHall), you could orient them correctly, and in the game you would round robin between them, doing a moveto player on them instead of a PlaceAtMe.

 

I just slapped that together in a script I already use for other hotkeys, just to see if the PlaceAtMe and setangle and setpos commands (using the static logpile ref as a reference) would work. It would need more work to be really usable. Like, you could also script the ability of the player to turn it ON/OFF with a fire/frost spell and maybe a torch. So, now you're taking about having the fire be an activator you can attach a script to.

Edited by GamerRick
Link to comment
Share on other sites

Does the fire still show up at an odd angle if you use the AddFlames command? It only adds the static FlameNode so you'd still need to add a light source.

You mean like:

rItem,AddFlames    ; add flames to this FileLogPile

I don't think you can do that do a static, can you? Never heard of this. Unfortunately the Wiki on it is broken and provides no info on its use.

Link to comment
Share on other sites

Actually, the setangle doesn't work right. The fire gets rotated differently in the game than the CS. So, in the game it is at an odd angle. I tried console commands on it and can't get the fire to be upright in the game.

 

Maybe the solution is also the solution to PlaceAtMe. If you were to put several of those fires in a cell somewhere (like TestingHall), you could orient them correctly, and in the game you would round robin between them, doing a moveto player on them instead of a PlaceAtMe.

 

I just slapped that together in a script I already use for other hotkeys, just to see if the PlaceAtMe and setangle and setpos commands (using the static logpile ref as a reference) would work. It would need more work to be really usable. Like, you could also script the ability of the player to turn it ON/OFF with a fire/frost spell and maybe a torch. So, now you're taking about having the fire be an activator you can attach a script to.

 

just use

setangle x -90

setangle y -90

That will stand the fire up.

Link to comment
Share on other sites

The problem turned out to be that the fire's z angle was not zero.

 

This works. I placed one fire in a test cell, and move it around.

set rItem to GetCrosshairRef
  if rItem
   set rItemBase to rItem.GetBaseObject
   if rItemBase == FireLogPile01
    RFCampFireLIGHTRef.MoveTo Player
   
    RFCampFireLIGHTRef.setangle x -90
    RFCampFireLIGHTRef.setangle y 0
    RFCampFireLIGHTRef.setangle Z 0
    set fTemp to rItem.GetPos x
    set fTemp to fTemp - 2.03   
    RFCampFireLIGHTRef.setPos x fTemp
   
    set fTemp to rItem.GetPos y
    set fTemp to fTemp - 10.755   
    RFCampFireLIGHTRef.setPos y fTemp
   
    set fTemp to rItem.GetPos z
    set fTemp to fTemp + 0.719   
    RFCampFireLIGHTRef.setPos z fTemp
    return
   endif
  endif
Link to comment
Share on other sites

  • 3 weeks later...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...